Replies: 2 comments
-
Hi @VijayV28, That's an excellent question I don't have the answer to. I'd like to know too. Perhaps asking in the PyTorch forums could help? |
Beta Was this translation helpful? Give feedback.
0 replies
-
Thanks a lot for your response. Will try your suggestion 👍 |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Hey,
I was trying to implement the torch.rand_like() on an array generated by torch.arange() and got an error:
Array:
Random function:
This threw an error as shown below:
RuntimeError: "check_uniform_bounds" not implemented for 'Long'
However, I later discovered that the
dtype
of the tensor generated by the torch.arange function isint64
.The rand_like() works well once I change the
dtype
back tofloat32
:I'd really like to know why doesn't rand_like() support
int64
datatype while the othertensor_like()
functions do.Beta Was this translation helpful? Give feedback.
All reactions