add sweep support

This commit is contained in:
hobogalaxy committed 2020-11-11 00:56:23 +01:00
1 parent f53794cf89
commit d013e22742
4 files changed
+32 -17

No files matched your search

+18
View File
@@ -0,0 +1,18 @@
import wandb
import main
# Load project config
config = main.load_config()
# Initialize wandb
wandb.init()
# Replace project config hyperparameters with the ones loaded from wandb sweep server
sweep_hparams = wandb.Config._as_dict(wandb.config)
for key, value in sweep_hparams.items():
if key != "_wandb":
config["hparams"][key] = value
# Execute run
main.main(config)