Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

optimize DPTabulate._build_lower method #1323

Merged
merged 1 commit into from
Dec 2, 2021

Conversation

njzjz
Copy link
Member

@njzjz njzjz commented Nov 30, 2021

This commit optimizes the execution time of DPTabulate._build_lower from 1s to 0.1s.

I confirm that the returned value (self.data[net]) does not change.

@njzjz njzjz requested a review from denghuilu November 30, 2021 22:31
This commit optimizes the execution time of `_build_lower` from 1s to 0.1s.
@njzjz njzjz changed the title optimize DPTabulate.build_lower method optimize DPTabulate._build_lower method Nov 30, 2021
@codecov-commenter
Copy link

Codecov Report

Merging #1323 (22b8d06) into devel (29e59d3) will decrease coverage by 11.33%.
The diff coverage is n/a.

❗ Current head 22b8d06 differs from pull request most recent head 42f8330. Consider uploading reports for the commit 42f8330 to get more accurate results
Impacted file tree graph

@@             Coverage Diff             @@
##            devel    #1323       +/-   ##
===========================================
- Coverage   75.62%   64.28%   -11.34%     
===========================================
  Files          91        5       -86     
  Lines        7498       14     -7484     
===========================================
- Hits         5670        9     -5661     
+ Misses       1828        5     -1823     
Impacted Files Coverage Δ
deepmd/utils/tabulate.py
deepmd/descriptor/se_a_ebd.py
deepmd/calculator.py
deepmd/infer/deep_pot.py
source/op/_prod_force_grad.py
deepmd/descriptor/descriptor.py
deepmd/env.py
deepmd/entrypoints/doc.py
source/op/_gelu.py
deepmd/fit/__init__.py
... and 76 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 29e59d3...42f8330. Read the comment docs.

@denghuilu
Copy link
Member

Why these changes matter to numpy's execution performance?

@njzjz
Copy link
Member Author

njzjz commented Dec 1, 2021

Why these changes matter to numpy's execution performance?

https://numpy.org/devdocs/user/whatisnumpy.html

@wanghan-iapcm wanghan-iapcm merged commit 0393766 into deepmodeling:devel Dec 2, 2021
@njzjz njzjz deleted the optimize_build_lower branch December 21, 2021 23:39
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.

None yet

4 participants