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
Running python -u -m vibcreg.examples.learn_representations throws the following error:
Traceback (most recent call last):
File "/opt/conda/lib/python3.6/runpy.py", line 193, in _run_module_as_main
"__main__", mod_spec)
File "/opt/conda/lib/python3.6/runpy.py", line 85, in _run_code
exec(code, run_globals)
File "/mnt/azure/vibcreg/vibcreg/examples/learn_representations.py", line 53, in <module>
rl_util, optimizer)
File "/mnt/azure/vibcreg/vibcreg/wrapper/run_wrapper.py", line 25, in run_ssl_for_rl
rl_util.get_batch_of_representations(test_data_loader, dataset_name) # stored internally
File "/opt/conda/lib/python3.6/site-packages/torch/autograd/grad_mode.py", line 49, in decorate_no_grad
return func(*args, **kwargs)
File "/mnt/azure/vibcreg/vibcreg/frameworks/framework_util_skeleton.py", line 284, in get_batch_of_representations
labels = torch.cat((labels, label.cpu()), dim=0)
RuntimeError: Expected object of scalar type Float but got scalar type Long for sequence element 1 in sequence argument at position #1 'tensors'
I fixed it by replacing labels = torch.cat((labels, label.cpu()), dim=0) for labels = torch.cat((labels, label.float().cpu()) dim=0) in line 284 in file framework_util_skeleton.py
The text was updated successfully, but these errors were encountered:
Running
python -u -m vibcreg.examples.learn_representations
throws the following error:I fixed it by replacing
labels = torch.cat((labels, label.cpu()), dim=0)
forlabels = torch.cat((labels, label.float().cpu()) dim=0)
in line 284 in fileframework_util_skeleton.py
The text was updated successfully, but these errors were encountered: