'How to solve 'Tensor' object has no attribute 'items' in Pytorch
I am running a python code in Pycharm and i used Pytorch for training. but i get this error
AttributeError: 'Tensor' object has no attribute 'items'
also my code is like this:
import pytorch_lightning as pl
trainer = pl.Trainer(max_epochs=5, gpus=0, reload_dataloaders_every_epoch=True,
progress_bar_refresh_rate=50, logger=False,
checkpoint_callback=False)
trainer.fit(model)
also this is the link of the full code that I'm trying to run Movie Recommender Systems Using Neural Network
Do you have any idea to solve this issue?
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
Solution | Source |
---|