arminarj:

What is the best way to apply k-fold cross validation in CNN?


Thanks for the link @arminarj, I tried to make it work in my project…
But I still have some doubts… I am using the NeuralNetClassifier from skorch

net = NeuralNetClassifier(
model,
criterion= nn.CrossEntropyLoss,
max_epochs=200,
lr=0.001,
optimizer=optim.Adam,
train_split=0.2,
iterator_train__shuffle=True
)
net.fit(images,labels)

images and labels are tensors… I am confused as to what should be in net.fit()? And also how can I use cvsplit for Cross Validation??
I am getting this error:

TypeError: ‘float’ object is not callable