Skip to content

Commit c13ed64

Browse files
committed
Update utils2.py
1 parent ac5c57b commit c13ed64

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

CIFAR10_code/utils2.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -130,8 +130,8 @@ def evaluation(epoch, epochs, model, dataloader, criterion):
130130
test_accuracy += acc
131131
test_loss += loss.item()
132132

133-
pbar.set_postfix(**{'Eval Acc' : test_accuracy.item()/(step+1),
134-
'Eval Loss' :test_loss.item()/(step+1)})
133+
pbar.set_postfix(**{'Eval Acc' : test_accuracy.items()/(step+1),
134+
'Eval Loss' :test_loss/(step+1)})
135135
pbar.update(1)
136136

137137
test_loss, test_accuracy = test_loss/eval_step, test_accuracy/eval_step

0 commit comments

Comments
 (0)