We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents ee74be3 + 4784631 commit aa6b2bdCopy full SHA for aa6b2bd
python/paddle/fluid/metrics.py
@@ -478,7 +478,7 @@ def eval(self):
478
"There is no data in EditDistance Metric. Please check layers.edit_distance output has been added to EditDistance."
479
)
480
avg_distance = self.total_distance / self.seq_num
481
- avg_instance_error = self.instance_error / self.seq_num
+ avg_instance_error = self.instance_error / float(self.seq_num)
482
return avg_distance, avg_instance_error
483
484
0 commit comments