src/transformers/trainer_callback.py/ProgressCallback/on_log
class ProgressCallback:    def on_log(self, args, state, control, logs=None, **kwargs):
        if state.is_local_process_zero and self.training_bar is not None:
            _ = logs.pop("total_flos", None)
            self.training_bar.write(str(logs))