Fix logger

This commit is contained in:
Matthew Honnibal 2020-10-04 14:16:53 +02:00
parent bcd52e5486
commit 84ae197dd6
1 changed files with 1 additions and 1 deletions

View File

@ -77,7 +77,7 @@ def train(
log_step, finalize_logger = train_logger(nlp, stdout, stderr) log_step, finalize_logger = train_logger(nlp, stdout, stderr)
try: try:
for batch, info, is_best_checkpoint in training_step_iterator: for batch, info, is_best_checkpoint in training_step_iterator:
log_step(info if is_best_checkpoint else None) log_step(info if is_best_checkpoint is not None else None)
if is_best_checkpoint is not None and output_path is not None: if is_best_checkpoint is not None and output_path is not None:
with nlp.select_pipes(disable=frozen_components): with nlp.select_pipes(disable=frozen_components):
update_meta(T, nlp, info) update_meta(T, nlp, info)