Skip to content

Add support for 'deepmd/mixed' format with dpdata.MultiSystems#422

Merged
wanghan-iapcm merged 8 commits intodeepmodeling:develfrom
iProzd:devel
Feb 23, 2023
Merged

Add support for 'deepmd/mixed' format with dpdata.MultiSystems#422
wanghan-iapcm merged 8 commits intodeepmodeling:develfrom
iProzd:devel

Conversation

@iProzd
Copy link
Collaborator

@iProzd iProzd commented Feb 19, 2023

Add support for 'deepmd/mixed' format with dpdata.MultiSystems

  1. Support dump from dpdata.MultiSystems to mixed type format:
    dpdata.MultiSystems.to_deepmd_mixed('dir_name_mixed')
  2. Support load from mixed type format to dpdata.MultiSystems:
    dpdata.MultiSystems.load_systems_from_file('dir_name_mixed', fmt='deepmd/mixed')

@iProzd
Copy link
Collaborator Author

iProzd commented Feb 19, 2023

I've added unittest for this, but I'm wondering where to add the docs.

@codecov-commenter
Copy link

codecov-commenter commented Feb 19, 2023

Codecov Report

Base: 82.39% // Head: 82.35% // Decreases project coverage by -0.04% ⚠️

Coverage data is based on head (a0951a0) compared to base (18508af).
Patch coverage: 81.57% of modified lines in pull request are covered.

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

📣 This organization is not using Codecov’s GitHub App Integration. We recommend you install it so Codecov can continue to function properly for your repositories. Learn more

Additional details and impacted files
@@            Coverage Diff             @@
##            devel     #422      +/-   ##
==========================================
- Coverage   82.39%   82.35%   -0.04%     
==========================================
  Files          67       68       +1     
  Lines        5963     6182     +219     
==========================================
+ Hits         4913     5091     +178     
- Misses       1050     1091      +41     
Impacted Files Coverage Δ
dpdata/format.py 88.33% <50.00%> (-1.33%) ⬇️
dpdata/deepmd/mixed.py 80.11% <80.11%> (ø)
dpdata/system.py 85.40% <83.78%> (-0.14%) ⬇️
dpdata/plugins/deepmd.py 67.21% <94.44%> (+4.71%) ⬆️

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

☔ View full report at Codecov.
📢 Do you have feedback about the report comment? Let us know in this issue.

@iProzd
Copy link
Collaborator Author

iProzd commented Feb 19, 2023

@wanghan-iapcm @njzjz

@njzjz
Copy link
Member

njzjz commented Feb 19, 2023

The docs can be automatically generated in https://deepmodeling--422.org.readthedocs.build/projects/dpdata/en/422/formats.html

@njzjz njzjz requested review from njzjz and wanghan-iapcm February 19, 2023 16:34
Copy link
Contributor

@wanghan-iapcm wanghan-iapcm left a comment

Choose a reason for hiding this comment

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

I find the UT is trivial: All systems has the same types and numbers of atoms. Please provide tests for the cases

  • systems has the same total number of atoms but different atom types,
  • systems has different total numbers of atoms,

and see if your code is working as it was designed.

The doc for the mix type is also missing. Please provide the doc.

@iProzd iProzd requested review from njzjz and wanghan-iapcm and removed request for njzjz and wanghan-iapcm February 21, 2023 07:29
@wanghan-iapcm wanghan-iapcm enabled auto-merge (squash) February 23, 2023 02:37
@wanghan-iapcm wanghan-iapcm merged commit d622c95 into deepmodeling:devel Feb 23, 2023
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