auto-pwa
AI-driven partial wave analysis for DeepSeek Harness: physics-gated config editing, ctpwa fit execution, numeric evaluation, and goal-driven iterative convergence. Physics knowledge (PDG-2026) as pure functions; DSH integration as a thin pwa_* tool plugin.
安装
$
npx -p @deepseek-ai/dsh dsh plugin --profile web add github:BHXiang/auto-pwa说明文档
阅读完整 README ↗环境配置(可选,开箱即用)
所有机器相关路径都通过环境变量覆盖;默认值可移植——拟合驱动默认用插件自带的 scripts/aifit.py,python 走 PATH:
| 环境变量 | 默认 | 说明 |
|---|---|---|
PWA_CTPWA_PYTHON | python(PATH 解析) | ctpwa 环境 python;非激活环境请显式指定绝对路径 |
PWA_LD_LIBRARY_PATH | 空(不注入,继承环境) | 导入 ctpwa 所需的 ROOT/CUDA/torch 库路径(仅非激活环境需要) |
PWA_FIT_SCRIPT | 插件自带 scripts/aifit.py | 拟合驱动来源(AI 适配:写 results/fit.json + weight_best.root) |
PWA_PLOT_SCRIPT | 空(不软链 plot.py) | 你的求解器 plot.py(需要出图时设置) |
PWA_EVAL_OUT_DIR | 空(用 /_auto-pwa-eval) | auto_pwa_evaluate 输出目录 |
PWA_FIT_TRANSPORT | auto | auto/local/slurm:拟合在哪跑。auto = 本机 torch 看得到 CUDA → 本地;无 CUDA 但有 slurm 客户端 → 交作业("无 GPU 但能 SLURM"规则)。 |
PWA_SLURM_TEMPLATE | a100 | a100/v100:集群模板,决定 partition/qos/account/gres 默认 |
PWA_SLURM_PARTITION / PWA_SLURM_QOS / PWA_SLURM_ACCOUNT / PWA_SLURM_GRES | 模板默认 | 逐集群覆盖(如 --partition=gpupwa --qos=pwadedicate --gres=gpu:a100:2) |
PWA_SLURM_NTASKS / PWA_SLURM_MEM_PER_CPU / PWA_SLURM_TIME | 1 / 50000 / 无 | sbatch 资源覆盖 |
PWA_SLURM_BATCH | auto | auto/one/script/off:候选试探批处理。auto = 按基座拟合实测 fit.json.timeSec 判(<120s → script 多合一脚本;否则 → one 每候选一作业,全部完成才唤醒) |