From 088632e765bd6ef71581eb817dae7455c6b155c7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andreas=20S=C3=B8gaard?= Date: Wed, 31 Aug 2022 13:32:22 +0200 Subject: [PATCH] Reorder --- examples/train_model.py | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/examples/train_model.py b/examples/train_model.py index 49439f8ba..f2a0f417e 100644 --- a/examples/train_model.py +++ b/examples/train_model.py @@ -33,17 +33,18 @@ features = FEATURES.DEEPCORE truth = TRUTH.DEEPCORE[:-1] +# Make sure W&B output directory exists +WANDB_DIR = "./wandb/" +os.makedirs(WANDB_DIR, exist_ok=True) + # Initialise Weights & Biases (W&B) run wandb_logger = WandbLogger( project="example-script", entity="graphnet-team", - save_dir="./wandb/", + save_dir=WANDB_DIR, log_model=True, ) -# -- Ensure that custom output directory exists -os.makedirs(wandb_logger.save_dir, exists_ok=True) - # Main function definition def main():