pytorch-lightning-vae icon indicating copy to clipboard operation
pytorch-lightning-vae copied to clipboard

TypeError: on_train_epoch_end() missing 1 required positional argument: 'outputs'

Open m-ali-awan opened this issue 3 years ago • 5 comments

As soon as the first epoch completes training, I am getting this error. I think it is due to some changes in the updated library, as I am getting the same error with one more implementation on vae.

Kindly help me on this.

Thanks, Regards, M.Ali

m-ali-awan avatar Nov 30 '21 10:11 m-ali-awan

@m-ali-awan You have to use on_train_epoch_end(self, *arg, **kwargs):

mathemusician avatar Dec 11 '21 20:12 mathemusician

just delete the outputs from the required variables.

Abolfazl-Alipour avatar Jun 09 '22 02:06 Abolfazl-Alipour

hi,Have you solved this problem, can you tell me the specific operation, thank you very much

RachelWang122 avatar Jun 10 '22 03:06 RachelWang122

so I got this error when calling "on_train_epoch_end(self, trainer, pl_module, outputs):"

you need to delete the 'outputs' as an input and just call the function this way: on_train_epoch_end(self, trainer, pl_module): seems like an update issue with newer versions on pytorch lightining.

Abolfazl-Alipour avatar Jun 10 '22 11:06 Abolfazl-Alipour

this is funny... just fail after a long time

CiaoHe avatar Oct 22 '22 21:10 CiaoHe