rrmina / fast-neural-style-pytorch

Fast Neural Style Transfer implementation in PyTorch :art: :art: :art:
315 stars 77 forks source link

Trying TransformerNetworkTanh and error when running train.py #20

Closed eformx closed 2 years ago

eformx commented 2 years ago

Getting following error when trying. Hope you can help resolve this?

Device: cuda Traceback (most recent call last): File "C:\Temp\fast-neural-style-pytorch-master\train.py", line 172, in <module> train() File "C:\Temp\fast-neural-style-pytorch-master\train.py", line 52, in train TransformerNetwork = transformer.TransformerNetworkTanh.to(device) File "C:\Users\eform\anaconda3\lib\site-packages\torch\nn\modules\module.py", line 673, in to return self._apply(convert) AttributeError: 'str' object has no attribute '_apply'

eformx commented 2 years ago

solved. installed lasted version of pip transformers and issue resolved.