CANN PID整定全链路端到端验证

发布时间:2026/7/4 21:34:07
CANN PID整定全链路端到端验证 PID FOPDT full-chain E2E harness【免费下载链接】mat-chem-sim-pred面向工业领域聚焦计算仿真、预测两大核心场景构建面向流程工业机理数据双轮驱动的领域计算层推动AI for Science在材料化学领域的深度应用。项目地址: https://gitcode.com/cann/mat-chem-sim-predEnd-to-end validation of the FOPDT PID-tuning pipeline, chaining the real operatorsfit → tuning_rule → fopdt_rollout → performance_metricsand comparing against a CPU reference.Two tools are provided:ToolPurposeCompares againste2e_orchestrator.pyAccuracy: drives the 4 operators stage-by-stage (e2e_runner) and checks each stage against its Python reference.per-stage CPU reference (common/*_reference.py)e2e_perfPerformance: single-process, device-resident chaintuning_rule → fopdt_rollout → performance_metrics, timed vs a CPU 64-thread chain; also re-checks final best-PID / score / metrics alignment.CPU multi-thread chain (in-process)The rollout stage dominates the chain cost (tuning/metrics are ~0.05 ms each), so the chain speedup tracks the rollout speedup.BuildThe operators must be built first (eachop/build/libop_host.soandop/build/lib/libop_kernel_lib.sopresent). Then, from this directory:bash build_e2e.sh # produces ./e2e_perf and ./e2e_runnerOverride the toolkit location withASCEND_HOME/ASCEND_TOOLKIT_ENVif it is not at the default/usr/local/Ascend/ascend-toolkit/latest.Run — performance (e2e_perf)# args: device [batch128] [candidates1024] [sim_steps1024] \ # [candidate_tile0:auto] [iters5] [warmup2] [threads64] ./e2e_perf 0 128 16384 1024 0 5 2 64candidate_tile0lets the rollout operator auto-select the optimal tile (min(candidates, kLane768)); pass an explicit value only to sweep the knob. Example representative-scale result (Ascend910B3, B128, sim_steps1024, auto tile): C1024 ≈ 4.0x, C4096 ≈ 6.2x, C16384 ≈ 4.5x vs CPU 64T.Run — accuracy (e2e_orchestrator.py)export E2E_RUNNER$PWD/e2e_runner # required: path to the built runner export E2E_WORK/tmp/e2e_work # optional: scratch dir for .bin I/O # export PID_COMMON/path/to/PIDModelFit/common # optional override; defaults to ../common python3 e2e_orchestrator.pyIt writes a per-stage comparison report to$E2E_WORK/e2e_report.jsonand prints the max error of each stage (NPU vs reference). All four stages align to within float32 tolerance.【免费下载链接】mat-chem-sim-pred面向工业领域聚焦计算仿真、预测两大核心场景构建面向流程工业机理数据双轮驱动的领域计算层推动AI for Science在材料化学领域的深度应用。项目地址: https://gitcode.com/cann/mat-chem-sim-pred创作声明:本文部分内容由AI辅助生成(AIGC),仅供参考