-
Notifications
You must be signed in to change notification settings - Fork 622
Small fixes for slice edge cases #476
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
|
Please add previously-failing tests which now pass to demonstrate the new functionality :) |
|
Unfortunately this case goes from xfail to xfail, as it results in 0 size tensors which still crash the refbackend #448 Do we want to create tests for xfail on Optional type coverage? |
|
is there a way to hack around that temporarily? for example, to cat the zero size tensor with a tensor of size 1 so the final tensor is of size 1? |
e20f920 to
093a996
Compare
|
Have they tried cloning you yet |
silvasean
left a comment
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.
Go ahead and merge after addressing nit :)
| ]) | ||
| def forward(self, x): | ||
| return x[5:5, 3:3, -1:] | ||
| #TODO: remove hacky cat tensor once refbackend supports 0 size dim |
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.
nit: space before TODO
093a996 to
7ae06ea
Compare
* Add krnl.load and knrl.store Signed-off-by: Tung D. Le <tung@jp.ibm.com> * Lower krnl load/store to affine load/store or std load/store Signed-off-by: Tung D. Le <tung@jp.ibm.com> * Edit optimize-memory-pools pass to adapt with the new changes Signed-off-by: Tung D. Le <tung@jp.ibm.com> * Use krnl load/store in onnx-to-krnl pass Signed-off-by: Tung D. Le <tung@jp.ibm.com> * Edit lit tests Signed-off-by: Tung D. Le <tung@jp.ibm.com> * Revise createKrnlLoad/Store Signed-off-by: Tung D. Le <tung@jp.ibm.com> * Add lit tests for krnl.load/store lowering Signed-off-by: Tung D. Le <tung@jp.ibm.com> * Edit lit tests for loop op Signed-off-by: Tung D. Le <tung@jp.ibm.com> * Remaining affine.load in IndexExpr Signed-off-by: Tung D. Le <tung@jp.ibm.com> * Mark std.load/store and affine.load/store illegal at the krnl level Signed-off-by: Tung D. Le <tung@jp.ibm.com> * Use krnl.load/store in the LRN lowering Signed-off-by: Tung D. Le <tung@jp.ibm.com> Co-authored-by: Gheorghe-Teodor Bercea <gt.bercea@gmail.com>
Adds a check for optional type, and covers the case where end < start. Thanks to @cathyzhyi for pointing these out.