-
Notifications
You must be signed in to change notification settings - Fork 5.9k
[Slice]Stride Mechanism Support and Index_put optimization #73053
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
[Slice]Stride Mechanism Support and Index_put optimization #73053
Conversation
|
你的PR提交成功,感谢你对开源项目的贡献! |
|
|
||
| PADDLE_ENFORCE_LE(index.size(), | ||
| DDim::kMaxRank, | ||
| "The number of index tensors exceeds the maximum rank."); |
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.
补充error 类型
| auto offset_calc = | ||
| funcs::make_offset_calculator_put<3>(desired_shape, strides_array); | ||
| const int64_t N = numel; | ||
| PADDLE_ENFORCE(N >= 0 && N <= std::numeric_limits<int32_t>::max(), |
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.
这里改成int64_t
|
|
||
| const int64_t N = numel; | ||
| PADDLE_ENFORCE(N >= 0 && N <= std::numeric_limits<int32_t>::max(), | ||
| "N >= 0 && N <= std::numeric_limits<int32_t>::max()"); |
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.
同时
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.
LGTM
PR Category
Execute Infrastructure
PR Types
New features
Description
pcard-67164
Based on #73022
新增支持stride机制的index_elementwise_put_kernel。
TODO: