Thanks so much for you kind help! I add that information:
from sklearn.metrics import accuracy_score as acc

from sklearn.metrics import confusion_matrix

from sklearn.metrics import matthews_corrcoef as mcor

from sklearn.metrics import precision_score as precision

from sklearn.metrics import recall_score as recall

from torch.utils.data import DataLoader

from torch.utils.tensorboard import SummaryWriter

from torchvision import transforms

I’m sorry I don’t explain well… my problem are refereed to this lines where I start to check the test :
if j % int(len(loader_train) / 2) == 0 and j != 0:
                model.eval()
                with torch.no_grad():

Here are performed in this way in some script I found after 10  accumulation… what is the right way to do if I have batch of 4 image at time?