Update rl.py
This commit is contained in:
parent
7f93c31789
commit
5a1d84fc24
1 changed files with 1 additions and 1 deletions
|
|
@ -371,7 +371,7 @@ def _patch_trl_rl_trainers(trainer_file = "grpo_trainer"):
|
|||
# Import all functions
|
||||
imports = list(set(imports))
|
||||
imports = f"from trl.trainer.{trainer_file} import (\n" + ',\n'.join(imports) + ")"
|
||||
exec(imports)
|
||||
exec(imports, locals(), globals())
|
||||
|
||||
# Patch all functions
|
||||
for function in changed:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue