Skip to content

fix(dpmodel): support parameter shorthand in DeepEval#5853

Open
njzjz-bot wants to merge 2 commits into
deepmodeling:masterfrom
njzjz-bot:fix/dpmodel-deepeval-param-shorthand-5662
Open

fix(dpmodel): support parameter shorthand in DeepEval#5853
njzjz-bot wants to merge 2 commits into
deepmodeling:masterfrom
njzjz-bot:fix/dpmodel-deepeval-param-shorthand-5662

Conversation

@njzjz-bot

Copy link
Copy Markdown
Contributor

Closes #5662.

Summary

  • normalize documented fparam and aparam shorthand into canonical frame-major arrays before automatic batching
  • preserve full per-frame inputs while tiling shared frame, per-atom, and all-atom parameter forms
  • reject invalid sizes with explicit parameter-shape errors before NumPy reshape failures
  • add direct dpmodel backend regressions with two-dimensional parameters, split/unsplit execution, and list input

Why existing tests missed this

Normal public DeepEval/DeepPot calls pass through _standard_input, which already tiles shorthand before invoking a backend and therefore masks the dpmodel adapter defect. Existing .dp consistency coverage uses one frame with full parameter shapes. No regression called the low-level dpmodel backend directly with multiple frames, nor forced automatic batching while passing (natoms, dim_aparam), which the batcher otherwise mistakes for a frame-major array and slices along the atom axis.

Validation

  • pytest source/tests/infer/test_dpmodel_deep_eval_params.py -q (8 passed)
  • public multi-frame DeepEval compatibility smoke test with forced one-frame batches (passed)
  • ruff format . (1 new test file reformatted; 1663 files unchanged)
  • ruff check . (passed)
  • git diff --check (passed)

Coding agent: Codex
Codex version: codex-cli 0.144.4
Model: gpt-5.6-sol
Reasoning effort: xhigh

njzjz-bot and others added 2 commits July 17, 2026 07:15
Normalize documented frame and atomic parameter shorthand before automatic
batching. Add direct-backend coverage for shared inputs, forced batch splits,
and invalid parameter sizes.

Coding-Agent: Codex
Codex-Version: codex-cli 0.144.4
Model: gpt-5.6-sol
Reasoning-Effort: xhigh
@codecov

codecov Bot commented Jul 17, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 78.33%. Comparing base (6c3b985) to head (1eb3feb).

Additional details and impacted files
@@            Coverage Diff             @@
##           master    #5853      +/-   ##
==========================================
- Coverage   78.58%   78.33%   -0.25%     
==========================================
  Files        1050     1050              
  Lines      120637   120654      +17     
  Branches     4356     4356              
==========================================
- Hits        94801    94515     -286     
- Misses      24278    24579     +301     
- Partials     1558     1560       +2     

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@njzjz

njzjz commented Jul 18, 2026

Copy link
Copy Markdown
Member

Possible reviewers based on changed lines, exact file history, and exact-file review history:

  • @wanghan-iapcm — 5 commits on changed files; 26 reviews on exact changed files (deepmd/dpmodel/infer/deep_eval.py).
  • @iProzd — 3 commits on changed files (deepmd/dpmodel/infer/deep_eval.py).

No review request was made automatically.

Coding agent: Codex
Codex version: codex-cli 0.144.4
Model: gpt-5.6-sol
Reasoning effort: xhigh

@njzjz
njzjz requested review from iProzd and wanghan-iapcm July 18, 2026 07:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Code scan] Honor documented fparam/aparam shorthand in dpmodel DeepEval

2 participants