summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGustaf Rydholm <gustaf.rydholm@gmail.com>2022-09-13 18:13:30 +0200
committerGustaf Rydholm <gustaf.rydholm@gmail.com>2022-09-13 18:13:30 +0200
commit61b6934f914b1615483a255419ac8471853901e9 (patch)
treed1dfe019ee392e67e671da6ace1f1ea047d093fa
parent0901bb8172fe56caa3eba9e4bf96ae0b164f9292 (diff)
Fix acc metric
-rw-r--r--text_recognizer/models/base.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/text_recognizer/models/base.py b/text_recognizer/models/base.py
index 64d3d71..90752e9 100644
--- a/text_recognizer/models/base.py
+++ b/text_recognizer/models/base.py
@@ -33,9 +33,9 @@ class LitBase(LightningModule):
self.mapping = mapping
# Placeholders
- self.train_acc = Accuracy()
- self.val_acc = Accuracy()
- self.test_acc = Accuracy()
+ self.train_acc = Accuracy(mdmc_reduce="samplewise")
+ self.val_acc = Accuracy(mdmc_reduce="samplewise")
+ self.test_acc = Accuracy(mdmc_reduce="samplewise")
def optimizer_zero_grad(
self,