-
Notifications
You must be signed in to change notification settings - Fork 584
fix: merge get_np_precision to get_xp_precision
#4867
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
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR consolidates precision handling by replacing the get_np_precision function's implementation with a call to the more general get_xp_precision function, which supports additional precision types.
- Removes direct import of
GLOBAL_NP_FLOAT_PRECISIONconstant - Replaces manual precision mapping logic with delegation to
get_xp_precision
get_np_precision to get_xp_precisionget_np_precision to get_xp_precision
|
Note Other AI code review bot(s) detectedCodeRabbit has detected other AI code review bot(s) in this pull request and will avoid duplicating their findings in the review comments. This may lead to a less comprehensive review. 📝 WalkthroughWalkthroughThe Changes
Estimated code review effort🎯 1 (Trivial) | ⏱️ ~3 minutes Note ⚡️ Unit Test Generation is now available in beta!Learn more here, or try it out under "Finishing Touches" below. 📜 Recent review detailsConfiguration used: CodeRabbit UI 📒 Files selected for processing (1)
🚧 Files skipped from review as they are similar to previous changes (1)
✨ Finishing Touches
🧪 Generate unit tests
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
SupportNeed help? Create a ticket on our support page for assistance with any issues or questions. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
Signed-off-by: Jinzhe Zeng <jinzhe.zeng@ustc.edu.cn>
for more information, see https://pre-commit.ci
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## devel #4867 +/- ##
=======================================
Coverage 84.71% 84.71%
=======================================
Files 699 699
Lines 68135 68126 -9
Branches 3542 3541 -1
=======================================
- Hits 57721 57716 -5
+ Misses 9279 9275 -4
Partials 1135 1135 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
`get_xp_precision` is more general and has more precisions (including bfloat16). <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * **Refactor** * Improved internal handling of precision settings for numerical operations, streamlining how precision is determined. No changes to user-facing functionality. <!-- end of auto-generated comment: release notes by coderabbit.ai --> --------- Signed-off-by: Jinzhe Zeng <jinzhe.zeng@ustc.edu.cn> Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
get_xp_precisionis more general and has more precisions (including bfloat16).Summary by CodeRabbit