Skip to content

Commit bdcdc29

Browse files
authored
reset accuracy statistics each epoch (tensorflow#633)
1 parent 22bae94 commit bdcdc29

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

TrainingLoop/TrainingStatistics.swift

+2
Original file line numberDiff line numberDiff line change
@@ -66,6 +66,8 @@ public class TrainingStatistics {
6666
case .trainingStart, .validationStart:
6767
totalBatchLoss = nil
6868
totalBatches = nil
69+
totalCorrect = nil
70+
totalExamples = nil
6971
case .batchEnd:
7072
if metrics.contains(.accuracy) {
7173
measureAccuracy(loop)

0 commit comments

Comments
 (0)