-
Notifications
You must be signed in to change notification settings - Fork 113
Add contiguous op #511
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
Add contiguous op #511
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.
please update these statements and we could merge this pr.
tests/test_special_ops.py
Outdated
low=-10000, high=10000, size=shape, dtype=dtype, device=flag_gems.device | ||
) | ||
inp = inp[::2] | ||
np.testing.assert_equal(inp.is_contiguous(), False) |
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.
assert inp.is_contiguous() == False
is more simple.
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.
Done
tests/test_special_ops.py
Outdated
|
||
np.testing.assert_equal(ref_out.is_contiguous(), True) | ||
np.testing.assert_equal(res_out.is_contiguous(), True) | ||
np.testing.assert_equal(res_out.stride(), ref_out.stride()) |
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.
ditto
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.
Done
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.
lg
PR Category
Operator
Type of Change
New Feature
Description
Add contiguous op
Issue
Progress
Performance
A100