Skip to content

Commit

Permalink
Merge branch 'main' into main
Browse files Browse the repository at this point in the history
  • Loading branch information
anhuong authored May 16, 2024
2 parents 62bb076 + eba20f3 commit 756faf1
Showing 1 changed file with 10 additions and 6 deletions.
16 changes: 10 additions & 6 deletions build/launch_training.py
Original file line number Diff line number Diff line change
Expand Up @@ -143,12 +143,16 @@ def main():
export_path,
)

create_merged_model(
checkpoint_models=full_checkpoint_dir,
export_path=export_path,
base_model=model_args.model_name_or_path,
save_tokenizer=True,
)
# ensure checkpoint dir has correct files, important with multi-gpu tuning
if os.path.exists(
os.path.join(full_checkpoint_dir, "adapter_config.json")
):
create_merged_model(
checkpoint_models=full_checkpoint_dir,
export_path=export_path,
base_model=model_args.model_name_or_path,
save_tokenizer=True,
)
except Exception as e: # pylint: disable=broad-except
logging.error(traceback.format_exc())
write_termination_log(
Expand Down

0 comments on commit 756faf1

Please sign in to comment.