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

pt: improve nlist performance #3425

Merged
merged 3 commits into from
Mar 7, 2024
Merged

Conversation

njzjz
Copy link
Member

@njzjz njzjz commented Mar 6, 2024

  1. use inv_ex instead of inv. inv_ex does not check errors. We can assume the input is correct.
  2. pass CPU box for torch.arange;
  3. avoid torch.tensor.

1. use inv_ex instead of inv. `inv_ex` does not check errors. We can assume the input is correct.
2. copy nbuff from device to host once other than 6 times (although copying once is still slow);
3. avoid torch.tensor.

Signed-off-by: Jinzhe Zeng <[email protected]>
@njzjz njzjz requested a review from wanghan-iapcm March 6, 2024 08:04
@github-actions github-actions bot added the Python label Mar 6, 2024
Copy link

codecov bot commented Mar 6, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 76.98%. Comparing base (278e6b8) to head (376185b).
Report is 2 commits behind head on devel.

Additional details and impacted files
@@            Coverage Diff             @@
##            devel    #3425      +/-   ##
==========================================
+ Coverage   76.95%   76.98%   +0.03%     
==========================================
  Files         423      423              
  Lines       35883    35956      +73     
  Branches     1620     1621       +1     
==========================================
+ Hits        27612    27679      +67     
- Misses       7403     7409       +6     
  Partials      868      868              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Signed-off-by: Jinzhe Zeng <[email protected]>
(cherry picked from commit a560f549b340c90af88b8831113445b17a0863c0)
Signed-off-by: Jinzhe Zeng <[email protected]>
@wanghan-iapcm wanghan-iapcm added this pull request to the merge queue Mar 7, 2024
Merged via the queue into deepmodeling:devel with commit 2d48d1f Mar 7, 2024
48 checks passed
@njzjz njzjz mentioned this pull request Apr 2, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants