-
Notifications
You must be signed in to change notification settings - Fork 618
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
Fix Slice pad support when last dimension is padded #2056
Fix Slice pad support when last dimension is padded #2056
Conversation
Signed-off-by: Joaquin Anton <janton@nvidia.com>
/** | ||
* @brief Fills output with nchannel values repeatedly | ||
*/ | ||
template <typename T> |
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.
moved those to common utilities because they'll be reused (in a follow up PR)
const OutputType *__restrict__ fill_values, int channel_dim, | ||
uint64_t offset, uint64_t block_end) { | ||
if (Dims > 1 && out_strides[Dims - 1] == in_strides[Dims - 1] && anchor[Dims - 1] == 0 && | ||
if (Dims > 1 && anchor[Dims - 1] == 0 && in_shape[Dims - 1] == out_shape[Dims - 1] && |
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.
This is the core of the bug fix
!build |
CI MESSAGE: [1420323]: BUILD STARTED |
CI MESSAGE: [1420323]: BUILD PASSED |
Why we need this PR?
Pick one, remove the rest
What happened in this PR?
Fill relevant points, put NA otherwise. Replace anything inside []
strides were used to fuse dimensions before. However, for the last dimension strides are the same so we ended up fusing a dimension that needed to be padded. To solve that, we switch to checking shapes instead of strides (out_shape had to be added)
Slice GPU kernel
Changes in the kernel
Unit tests added
N/A
JIRA TASK: [Use DALI-XXXX or NA]