Skip to content

in model_devi, assumes nopbc if box is set to None#1704

Merged
wanghan-iapcm merged 5 commits intodeepmodeling:develfrom
amcadmus:fix-md-box
May 25, 2022
Merged

in model_devi, assumes nopbc if box is set to None#1704
wanghan-iapcm merged 5 commits intodeepmodeling:develfrom
amcadmus:fix-md-box

Conversation

@wanghan-iapcm
Copy link
Collaborator

The doc string says

Box to specify periodic boundary condition. If None, no pbc will be used

but it is not implemented as that.

Fix the issue makes the behavior of model_devi the same as DeepPot.eval

@wanghan-iapcm wanghan-iapcm requested review from Ericwang6 and njzjz May 13, 2022 02:40
@codecov-commenter
Copy link

codecov-commenter commented May 13, 2022

Codecov Report

Merging #1704 (d7b510d) into devel (de7ba72) will decrease coverage by 11.86%.
The diff coverage is n/a.

❗ Current head d7b510d differs from pull request most recent head b9371ce. Consider uploading reports for the commit b9371ce to get more accurate results

@@             Coverage Diff             @@
##            devel    #1704       +/-   ##
===========================================
- Coverage   76.15%   64.28%   -11.87%     
===========================================
  Files          94        5       -89     
  Lines        7850       14     -7836     
===========================================
- Hits         5978        9     -5969     
+ Misses       1872        5     -1867     
Impacted Files Coverage Δ
deepmd/calculator.py
deepmd/entrypoints/compress.py
deepmd/entrypoints/convert.py
deepmd/entrypoints/main.py
deepmd/entrypoints/train.py
deepmd/fit/ener.py
deepmd/infer/model_devi.py
deepmd/train/trainer.py
deepmd/utils/convert.py
deepmd/utils/tabulate.py
... and 79 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update de7ba72...b9371ce. Read the comment docs.

Co-authored-by: Jinzhe Zeng <jinzhe.zeng@rutgers.edu>
@wanghan-iapcm wanghan-iapcm requested a review from njzjz May 14, 2022 07:24
Copy link
Member

@njzjz njzjz left a comment

Choose a reason for hiding this comment

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

This line still uses old parameter:

devi = calc_model_devi(coord, box, atype, dp_models, nopbc=nopbc)

@wanghan-iapcm wanghan-iapcm requested a review from njzjz May 14, 2022 09:16
@wanghan-iapcm wanghan-iapcm merged commit c4ad552 into deepmodeling:devel May 25, 2022
mingzhong15 pushed a commit to mingzhong15/deepmd-kit that referenced this pull request Jan 15, 2023
* in model_devi, assumes nopbc if box is set to None

* fix UT

* Update deepmd/infer/model_devi.py

Co-authored-by: Jinzhe Zeng <jinzhe.zeng@rutgers.edu>

* fix make_model_devi

Co-authored-by: Han Wang <wang_han@iapcm.ac.cn>
Co-authored-by: Han Wang <amcadmus@gmail.com>
Co-authored-by: Jinzhe Zeng <jinzhe.zeng@rutgers.edu>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants