Skip to content

Commit

Permalink
Merge pull request huggingface#19 from microsoft/sajandhy/ort_t5
Browse files Browse the repository at this point in the history
Fix the loss values collected under Metrics in AzureML experiments
  • Loading branch information
raviskolli committed Jul 17, 2021
2 parents 0b21a14 + 2ee3d8b commit 2faedf4
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/transformers/integrations.py
Original file line number Diff line number Diff line change
Expand Up @@ -828,7 +828,7 @@ def on_init_end(self, args, state, control, **kwargs):
self.azureml_run = Run.get_context()

def on_log(self, args, state, control, logs=None, **kwargs):
if self.azureml_run:
if self.azureml_run and state.is_world_process_zero:
for k, v in logs.items():
if isinstance(v, (int, float)):
self.azureml_run.log(k, v, description=k)
Expand Down

0 comments on commit 2faedf4

Please sign in to comment.