mirror of
https://github.com/explosion/spaCy.git
synced 2024-11-10 19:57:17 +03:00
add message when cli train script throws exception (#5009)
* add message when cli train script throws exception * fix formatting
This commit is contained in:
parent
ff8e71f46d
commit
a27c77ce62
|
@ -508,6 +508,8 @@ def train(
|
|||
"score = {}".format(best_score, current_score)
|
||||
)
|
||||
break
|
||||
except Exception as e:
|
||||
msg.warn("Aborting and saving the final best model. Encountered exception: {}".format(e))
|
||||
finally:
|
||||
best_pipes = nlp.pipe_names
|
||||
if disabled_pipes:
|
||||
|
|
Loading…
Reference in New Issue
Block a user