May be You’ve defined not train_loader  in model arugment. I think   you shouldn’t put train_loader directly in argument,before train_loader was defined , so only data_loader would be fine.



 heitorvc:

        ....         features_d = 16, dataloader, transforms = None):