mirror of
https://github.com/explosion/spaCy.git
synced 2025-07-14 10:12:22 +03:00
Fix divide by zero
This commit is contained in:
parent
377108998a
commit
357d4e6293
|
@ -587,7 +587,7 @@ def setup_printer(training, pipe_names):
|
||||||
+ losses
|
+ losses
|
||||||
+ scores
|
+ scores
|
||||||
+ ["{0:.2f}".format(float(info["score"]))]
|
+ ["{0:.2f}".format(float(info["score"]))]
|
||||||
+ ["%d" % (info["words"] / info["seconds"])]
|
+ ["%d" % (info["words"] / (info["seconds"] + 1e-6))]
|
||||||
)
|
)
|
||||||
msg.row(data, widths=table_widths, aligns=table_aligns)
|
msg.row(data, widths=table_widths, aligns=table_aligns)
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user