From 5a75f39a29537f5e124871f7ddcf27c3260f34aa Mon Sep 17 00:00:00 2001 From: Michael Date: Wed, 3 Jul 2024 21:41:19 +0200 Subject: [PATCH] Remove extra print in reward_trainer.py `print_rich_table` is called twice and the first call doesn't restrict to `num_print_samples`. Remove the first, extra call --- trl/trainer/reward_trainer.py | 1 - 1 file changed, 1 deletion(-) diff --git a/trl/trainer/reward_trainer.py b/trl/trainer/reward_trainer.py index 3b98d68d90..c3fc904fa6 100644 --- a/trl/trainer/reward_trainer.py +++ b/trl/trainer/reward_trainer.py @@ -310,7 +310,6 @@ def visualize_samples(self, num_print_samples: int): if num_print_samples >= 0 and len(table["chosen_text"]) >= num_print_samples: break df = pd.DataFrame(table) - print_rich_table(pd.DataFrame(table)) if self.accelerator.process_index == 0: print_rich_table(df[:num_print_samples]) if "wandb" in self.args.report_to: