'collections.OrderedDict' object has no attribute 'seek'. You can only torch.load from a file that i

 

File "C:\Python\Python37\lib\site-packages\torch\serialization.py", line 187, in raise_err_msg
   raise type(e)(msg)


AttributeError: 'collections.OrderedDict' object has no attribute 'seek'. You can only torch.load from a file that is seekable. Please pre-load the data into a buffer like io.BytesIO and try to load from it instead.
 

Done

pretrained_net = torch.load(model_zoo.load_url(model_urls))   #Error

pretrained_net = model_zoo.load_url(model_urls)                #OK

 


 

你可能感兴趣的:(PyTorch)