Skip to content

【Hackathon 10th Spring No.9】NewtonNet模型复现#272

Open
r-cloudforge wants to merge 6 commits intoPaddlePaddle:developfrom
CloudForge-Solutions:task/009-newtonnet-reproduction
Open

【Hackathon 10th Spring No.9】NewtonNet模型复现#272
r-cloudforge wants to merge 6 commits intoPaddlePaddle:developfrom
CloudForge-Solutions:task/009-newtonnet-reproduction

Conversation

@r-cloudforge
Copy link
Copy Markdown

通过迁移 https://github.com/THGLab/NewtonNet 项目实现 NewtonNet 的PaddlePaddle版本复现。

主要改动

  1. 新增 ppmat/models/newtonnet/ 模型目录 — 完整的NewtonNet等变力场模型实现
  2. 新增 interatomic_potentials/configs/newtonnet/ 训练配置
  3. 新增 test/newtonnet/ 测试代码 — 8个单元测试,覆盖能量预测、力计算、等变性验证

模型特性

  • 等变神经网络力场,基于牛顿运动方程
  • Bessel基径向嵌入 + 多项式截断函数
  • 能量守恒力预测(通过自动微分)
  • 支持PBC周期性边界条件
  • 基于PaddleMaterials标准API:forward(data){"loss_dict", "pred_dict"}
  • 已注册到 ppmat/models/__init__.py

测试

cd test && python -m pytest newtonnet/ -v
# 8 passed

与现有PR #262的区别

本PR完全集成到PaddleMaterials框架中:

  • 遵循 ppmat/models/ 标准目录结构
  • 使用 build_model(cfg) 工厂函数构建
  • 包含完整的单元测试套件
  • 包含标准训练配置YAML

参考链接

cloudforge1 and others added 5 commits March 28, 2026 10:00
Implement Newtonian message passing network for molecular energy/force
prediction. Includes RadialBessel, InteractionNet, EnergyOutput, and
8 unit tests using water molecule fixture.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
@CLAassistant
Copy link
Copy Markdown

CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.


cloudforge1 seems not to be a GitHub user. You need a GitHub account to be able to sign the CLA. If you have already a GitHub account, please add the email address used for this commit to your account.
You have signed the CLA already but the status is still pending? Let us recheck it.

@paddle-bot
Copy link
Copy Markdown

paddle-bot bot commented Apr 11, 2026

Thanks for your contribution!

@paddle-bot paddle-bot bot added the contributor External developers label Apr 11, 2026
- Add force computation as negative energy gradient in _forward()
- Add force loss with configurable weight (default 100.0)
- Add force prediction in predict() method
- Fix PBC backward crash by detaching scaled coords before round()
- Add 3 force-related tests (shape, consistency, loss)
- Update config with force_loss_weight parameter

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

contributor External developers

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants