Skip to content

docs(pt): sync DPA4 compile compatibility docs - #6046

Merged
wanghan-iapcm merged 1 commit into
deepmodeling:masterfrom
jasperdingg:docs/dpa4-compile-compatibility
Nov 7, 2026
Merged

wanghan-iapcm merged 1 commit into
deepmodeling:masterfrom
jasperdingg:docs/dpa4-compile-compatibility

Conversation

@jasperdingg

@jasperdingg jasperdingg commented Oct 5, 2026 •

Copy link
Copy Markdown
Contributor

Update the DPA4/SeZM documentation to match the supported PyTorch versions: 2.11.x, 2.12.x, and 2.13.x. Keep the CUDA 12.6 requirement and existing dependency pins unchanged.

Fixes #5981.

Validation

  • 9 targeted tests passed
  • Ruff checks passed
  • Markdown formatting passed

Summary by CodeRabbit

  • Documentation
    • Updated compile-support requirements for SeZM and DPA4 to reflect support for listed PyTorch versions rather than only PyTorch 2.11.
    • Clarified that NVIDIA GPU compilation requires CUDA 12.6 or later.

@coderabbitai

coderabbitai Bot commented Oct 5, 2026 •

Copy link
Copy Markdown
Contributor

Review in Change Stack →

Navigate logical layers of code changes, visualize relationships, and explore their blast radius.

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration
  • Configuration used: Repository UI
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 6c424802-fa38-4b65-a91b-51758119ef49
📥 Commits

Reviewing files that changed from the base of the PR and between 5b9fe07 and a7e9c3a.

📒 Files selected for processing (3)
  • deepmd/pt/model/model/sezm_model.py
  • deepmd/utils/argcheck.py
  • doc/model/dpa4.md

Included review availability: This review used your included allowance. Your plan provides up to 8 included reviews per hour; 7 remain after this review.


📝 Walkthrough

Walkthrough

The use_compile, SeZM, and DP_COMPILE_INFER documentation now describes compilation as supporting listed PyTorch releases and requiring CUDA 12.6 or later on NVIDIA GPUs.

Changes

Compile support documentation

Layer / File(s) Summary
Compile support requirements
deepmd/utils/argcheck.py, deepmd/pt/model/model/sezm_model.py, doc/model/dpa4.md
The documentation replaces the fixed torch==2.11 requirement with the supported PyTorch release information. It states the CUDA 12.6 minimum for NVIDIA GPUs.

Priority: ⬇️ Low

Estimated code review effort: 1 (Trivial) | ~5 minutes

Change: Other

Suggested reviewers: outisli

Merge Risk: ⚪ Minimal · up to a7e9c

The updated documentation reflects the supported PyTorch releases and CUDA requirement; no merge-blocking issue is identified.

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 1 functions across 2 files. (1 skipped: 1 … Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (4 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly describes the main change: updating the DPA4 compile-compatibility documentation. It does not mention SeZM, but the title need not cover every detail.
Linked Issues check ✅ Passed Issue #5981 requires the DPA4/SeZM documentation and docstrings to match the supported PyTorch versions and retain CUDA 12.6. deepmd/pt/model/model/sezm_model.py and deepmd/utils/argcheck.py now r…
Out of Scope Changes check ✅ Passed All changes update the three stale DPA4/SeZM compile-support descriptions identified by issue #5981. The changes do not alter runtime behavior or unrelated dependency pins.
Full details: Docstring Coverage

Explanation

Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 1 functions across 2 files. (1 skipped: 1 unsupported.)

  • Fix all pre-merge checks with AI
✨ Finishing Touches 💡 1
🧪 Generate unit tests (beta)
  • Create a new PR
🛠️ Fix failing CI checks 💡
  • Commit to this branch
  • Create a new PR
  • Autopilot · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@njzjz-bot njzjz-bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reviewed the complete three-file documentation-only change against the runtime compile policy. SUPPORTED_COMPILE_TORCH is ((2, 11), (2, 12), (2, 13)), and check_compile_torch_version enforces that allowlist, so the updated wording correctly removes the obsolete 2.11-only restriction. The model docstring and argument documentation agree, and the inference table now links to the same use_compile option instead of maintaining another version list. No new actionable issue found.

This is source/documentation review only; no compiler or documentation build was run locally. Exact-head pre-commit succeeds, but all seven build/test/security workflows are action_required and Read the Docs failed (https://app.readthedocs.org/projects/deepmd/builds/34940370/). Rendered cross-reference validation is therefore still unverified.

Agent: dot
Reviewed head: a7e9c3a

@wanghan-iapcm wanghan-iapcm left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The synced text matches the code at this head: SUPPORTED_COMPILE_TORCH is ((2, 11), (2, 12), (2, 13)), check_compile_torch_version() is what gates both model.use_compile and DP_COMPILE_INFER, and the {ref} target model[dpa4]/use_compile is generated by dargs from the dpa4 model plugin, so the cross-reference resolves. The class docstring, the argument help and the DPA4 table now agree with each other and with the runtime allowlist, and the CUDA and dependency pins are left as intended.

Two non-blocking observations, recorded for a later cleanup rather than as changes requested:

  • The use_compile help text points at SUPPORTED_COMPILE_TORCH and then re-states its contents as "(currently 2.11.x, 2.12.x, and 2.13.x)", which is a second hand-maintained copy that will drift on the next allowlist change. Issue #5981 explicitly asked to avoid another hard-coded list where practical; the sibling docstring in sezm_model.py already names only the constant.
  • :data: is consumed verbatim as the JSON-schema description (dargs copies Argument.doc unchanged), so dp doc-train-input --out-type json_schema, DP-GUI and editor tooltips show the role markup literally. There is precedent for this in the file (:py:meth: in doc_rcond), so it is a formatting wart rather than a new failure mode.

auto-merge was automatically disabled November 7, 2026 16:29

Pull request was closed

@wanghan-iapcm wanghan-iapcm reopened this Nov 7, 2026
@codecov

codecov Bot commented Nov 7, 2026 •

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 77.91%. Comparing base (5b9fe07) to head (a7e9c3a).
⚠️ Report is 41 commits behind head on master.

Additional details and impacted files
@@            Coverage Diff             @@
##           master    #6046      +/-   ##
==========================================
+ Coverage   77.74%   77.91%   +0.17%     
==========================================
  Files        1155     1207      +52     
  Lines      139649   146598    +6949     
  Branches     5056     5209     +153     
==========================================
+ Hits       108573   114226    +5653     
- Misses      29191    30408    +1217     
- Partials     1885     1964      +79     

☔ 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.

@wanghan-iapcm
wanghan-iapcm added this pull request to the merge queue Nov 7, 2026
Merged via the queue into deepmodeling:master with commit f4c0073 Nov 7, 2026
58 of 59 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

docs(pt): sync DPA4 torch.compile version text with supported allowlist

3 participants