Skip to content

Commit

Permalink
move details script and fix wandb logging (#314)
Browse files Browse the repository at this point in the history
  • Loading branch information
edbeeching authored Feb 13, 2025
1 parent f987b3c commit 80e7e7b
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 10 deletions.
File renamed without changes.
2 changes: 1 addition & 1 deletion slurm/evaluate.slurm
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ echo "Uploading details to Hugging Face Hub..."
DETAILS_FILEPATHS=$(find $OUTPUT_DIR/details/ -type f \( -name "*.parquet" \))
echo "DETAILS_FILEPATHS: $DETAILS_FILEPATHS"
TIMESTAMP=$(date +"%Y-%m-%dT%H-%M-%S")
python src/open_r1/utils/upload_details.py --data_files $DETAILS_FILEPATHS --hub_repo_id $DETAILS_REPO_ID --config_name $MODEL_REVISION.$TASK_NAME.$TIMESTAMP
python scripts/upload_details.py --data_files $DETAILS_FILEPATHS --hub_repo_id $DETAILS_REPO_ID --config_name $MODEL_REVISION.$TASK_NAME.$TIMESTAMP

echo "Cleaning up ..."
rm -rf $OUTPUT_DIR
Expand Down
9 changes: 0 additions & 9 deletions src/open_r1/utils/logging.py

This file was deleted.

11 changes: 11 additions & 0 deletions src/open_r1/utils/wandb_logging.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
import os


def init_wandb_training(training_args):
"""
Helper function for setting up Weights & Biases logging tools.
"""
if training_args.wandb_entity is not None:
os.environ["WANDB_ENTITY"] = training_args.wandb_entity
if training_args.wandb_project is not None:
os.environ["WANDB_PROJECT"] = training_args.wandb_project

0 comments on commit 80e7e7b

Please sign in to comment.