Cross Validation

Hii,
I would like to do cross validation on my dataset.
Currently I have a binary classification network for medical images and having a 90% accuracy on my validation set. My validation image dataset is small, so i would like to do cross validation.
I am using a custom dataset class to load the dataset and the Folders are arranged in this way:
Train/1stclass
Train/2ndclass
Valid/1stClass
Valid/2ndclass

Should I mix them in one Folder for the Cross Validation?
I am new to pytorch, Please if anyone can help me with this… I would really appreciate it … Thank You

Hi Dear @DJ_1992,
There is a similar answer to your inquiry, Hope it helps. :wink:
https://discuss.pytorch.org/t/what-is-the-best-way-to-apply-k-fold-cross-validation-in-cnn/15035/2?u=arminarj

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