-
Notifications
You must be signed in to change notification settings - Fork 26.3k
Move THCTensor_(geometric) to ATen #20625
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
Move THCTensor_(geometric) to ATen gh-metadata: pytorch pytorch 20625 gh/syed-ahmed/6/head
Move THCTensor_(geometric) to ATen gh-metadata: pytorch pytorch 20625 gh/syed-ahmed/6/head
Move THCTensor_(geometric) to ATen gh-metadata: pytorch pytorch 20625 gh/syed-ahmed/6/head
Move THCTensor_(geometric) to ATen gh-metadata: pytorch pytorch 20625 gh/syed-ahmed/6/head
Move THCTensor_(geometric) to ATen gh-metadata: pytorch pytorch 20625 gh/syed-ahmed/6/head
Move THCTensor_(geometric) to ATen gh-metadata: pytorch pytorch 20625 gh/syed-ahmed/6/head
Move THCTensor_(geometric) to ATen gh-metadata: pytorch pytorch 20625 gh/syed-ahmed/6/head
Move THCTensor_(geometric) to ATen gh-metadata: pytorch pytorch 20625 gh/syed-ahmed/6/head
Move THCTensor_(geometric) to ATen gh-metadata: pytorch pytorch 20625 gh/syed-ahmed/6/head
Move THCTensor_(geometric) to ATen gh-metadata: pytorch pytorch 20625 gh/syed-ahmed/6/head
Move THCTensor_(geometric) to ATen gh-metadata: pytorch pytorch 20625 gh/syed-ahmed/6/head
| auto p = static_cast<float>(p_); | ||
| auto geometric_func = [p] __device__ (float rand) { | ||
| // use __logf fast approximation for peak bandwidth | ||
| return static_cast<scalar_t>(::ceil(__logf(rand) / __logf(static_cast<float>(1.0)-p))); |
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.
used to be ceilf, I guess it doesn't make a difference?
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.
Yeah. ceil with float input will launch ceilf. These overloads are in /usr/local/cuda-10.0/include/crt/math_functions.hpp fyi
Move THCTensor_(geometric) to ATen gh-metadata: pytorch pytorch 20625 gh/syed-ahmed/6/head
Move THCTensor_(geometric) to ATen gh-metadata: pytorch pytorch 20625 gh/syed-ahmed/6/head
Move THCTensor_(geometric) to ATen gh-metadata: pytorch pytorch 20625 gh/syed-ahmed/6/head
Move THCTensor_(geometric) to ATen gh-metadata: pytorch pytorch 20625 gh/syed-ahmed/6/head
Move THCTensor_(geometric) to ATen gh-metadata: pytorch pytorch 20625 gh/syed-ahmed/6/head
Move THCTensor_(geometric) to ATen gh-metadata: pytorch pytorch 20625 gh/syed-ahmed/6/head
Stack from ghstack:
Differential Revision: D15454049
Effective Bandwidth Benchmark
Float Type
Before:
After:
Double Type
Before:
After: