Skip to content
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

dpnp.ndarray.transpose does not support axes as list #1769

Closed
vtavana opened this issue Apr 2, 2024 · 0 comments · Fixed by #1770
Closed

dpnp.ndarray.transpose does not support axes as list #1769

vtavana opened this issue Apr 2, 2024 · 0 comments · Fixed by #1770
Assignees

Comments

@vtavana
Copy link
Collaborator

vtavana commented Apr 2, 2024

dpnp.ndarray.transpose does not support axes as list while dpnp.transport does.

import dpnp, numpy
a = numpy.ones((1, 2, 3))
b = dpnp.ones((1, 2, 3))
axes = [1, 0, 2]

numpy.transpose(a, axes).shape
# (2, 1, 3)
dpnp.transpose(b, axes).shape
# (2, 1, 3) 

a.transpose(axes).shape
# (2, 1, 3)
b.transpose(axes).shape
# TypeError: 'list' object cannot be interpreted as an integer
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant