Switch net to eval mode in eval.py

Former-commit-id: 3ab827241455818c7b81172a426d805f9ace0f8f
This commit is contained in:
milesial 2018-09-26 08:57:10 +02:00 committed by GitHub
parent 3fefc25199
commit b1ac7151b4

View file

@ -6,6 +6,7 @@ from dice_loss import dice_coeff
def eval_net(net, dataset, gpu=False):
"""Evaluation without the densecrf with the dice coefficient"""
net.eval()
tot = 0
for i, b in enumerate(dataset):
img = b[0]