You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
what is the version of the python and torch ?
I have some bugs when I run the tester.py.
for exmple,
Traceback (most recent call last):
File "tester.py", line 502, in
sampler.generate()
File "tester.py", line 144, in generate
sampled_ids = self.word_model.sample(topic, start_tokens)
File "/home/cheng/perl5/Medical-Report-Generation-master/utils/models.py", line 386, in sample
sampled_ids[:, 0] = start_tokens.view(-1, )
File "/usr/local/lib/python3.6/site-packages/torch/tensor.py", line 452, in array
return self.numpy().astype(dtype, copy=False)
TypeError: can't convert CUDA tensor to numpy. Use Tensor.cpu() to copy the tensor to host memory first.
The text was updated successfully, but these errors were encountered:
what is the version of the python and torch ?
I have some bugs when I run the tester.py.
for exmple,
Traceback (most recent call last):
File "tester.py", line 502, in
sampler.generate()
File "tester.py", line 144, in generate
sampled_ids = self.word_model.sample(topic, start_tokens)
File "/home/cheng/perl5/Medical-Report-Generation-master/utils/models.py", line 386, in sample
sampled_ids[:, 0] = start_tokens.view(-1, )
File "/usr/local/lib/python3.6/site-packages/torch/tensor.py", line 452, in array
return self.numpy().astype(dtype, copy=False)
TypeError: can't convert CUDA tensor to numpy. Use Tensor.cpu() to copy the tensor to host memory first.
The text was updated successfully, but these errors were encountered: