Forward() missing 2 required positional arguments: 'input' and 'target'

Hello everyone,
I am quite new with Skorch, and I am in the process of applying K-fold cross-validation using data Loaders from a directory of images.
After creating the train and validation loaders, I user the fit(X,y) method from NeuralNet class, with X = current_train_loader, and y = current_train_target. As soon as the fit(X,y) executes, the following error occurs:

Whereas, I fill in the input and target exactly as mentioned. Is there anything wrong with my procedure? Following is what my training phase looks like:

thanks

This also happened to me when I initialized the criterion. For example,

criterion = torch.nn.BCELoss()

I solve this problem by:

criterion = torch.nn.BCELoss

2 Likes