deepmodeling / deepmd-kit

A deep learning package for many-body potential energy representation and molecular dynamics
https://docs.deepmodeling.com/projects/deepmd/
GNU Lesser General Public License v3.0
1.41k stars 486 forks source link

[pre-commit.ci] pre-commit autoupdate #3938

Closed pre-commit-ci[bot] closed 2 days ago

pre-commit-ci[bot] commented 2 days ago

updates:

codecov[bot] commented 2 days ago

Codecov Report

All modified and coverable lines are covered by tests :white_check_mark:

Project coverage is 83.09%. Comparing base (20aeaf8) to head (807fb1d). Report is 4 commits behind head on devel.

Additional details and impacted files ```diff @@ Coverage Diff @@ ## devel #3938 +/- ## ========================================== + Coverage 82.88% 83.09% +0.21% ========================================== Files 520 520 Lines 50679 51724 +1045 Branches 3015 3026 +11 ========================================== + Hits 42003 42978 +975 - Misses 7740 7809 +69 - Partials 936 937 +1 ```

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

njzjz commented 2 days ago
deepmd/utils/data.py:445:17: E721 Use `is` and `is not` for type comparisons, or `isinstance()` for isinstance checks
    |
443 |         for kk in data:
444 |             if (
445 |                 type(data[kk]) == np.ndarray
    |                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ E721
446 |                 and len(data[kk].shape) == 2
447 |                 and data[kk].shape[0] == nframes
    |

source/tests/common/test_argument_parser.py:177:20: E721 Use `is` and `is not` for type comparisons, or `isinstance()` for isinstance checks
    |
175 |                 else:
176 |                     t = data["type"]
177 |                 if t == str:
    |                    ^^^^^^^^ E721
178 |                     required.append("STRING")
179 |                 elif t in (int, float):
    |

Found 2 errors.