facebookresearch / suncet

Code to reproduce the results in the FAIR research papers "Semi-Supervised Learning of Visual Features by Non-Parametrically Predicting View Assignments with Support Samples" https://arxiv.org/abs/2104.13963 and "Supervision Accelerates Pre-training in Contrastive Semi-Supervised Learning of Visual Representations" https://arxiv.org/abs/2006.10803
MIT License
488 stars 67 forks source link

Error with udata loader #34

Closed uthillaivasan closed 2 years ago

uthillaivasan commented 2 years ago

https://github.com/facebookresearch/suncet/blob/731547d727b8c94d06c08a7848b4955de3a70cea/src/paws_train.py#L269

Error message below:

File "/content/drive/MyDrive/cs231n/project/suncet-main/src/paws_train.py", line 271, in <listcomp>
    uimgs = [u.to(device, non_blocking=True) for u in udata[:-1]]
AttributeError: 'list' object has no attribute 'to'
uthillaivasan commented 2 years ago

issue is resolved if using Python==3.8 (instead of what I started with, Python=3.7)