Browse Source

Add `callbacks` to train function in W&B sweep (#4742)

* add callbacks to train function in wandb sweep

Fix following https://github.com/ultralytics/yolov5/pull/4688 which modified the function signature to `train`

* Cleanup

Co-authored-by: Glenn Jocher <glenn.jocher@ultralytics.com>
modifyDataloader
Josh Veitch-Michaelis GitHub 3 years ago
parent
commit
19e28e3bfe
No known key found for this signature in database GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 1 deletions
  1. +2
    -1
      utils/loggers/wandb/sweep.py

+ 2
- 1
utils/loggers/wandb/sweep.py View File

@@ -9,6 +9,7 @@ sys.path.append(FILE.parents[3].as_posix()) # add utils/ to path
from train import train, parse_opt
from utils.general import increment_path
from utils.torch_utils import select_device
from utils.callbacks import Callbacks


def sweep():
@@ -26,7 +27,7 @@ def sweep():
device = select_device(opt.device, batch_size=opt.batch_size)

# train
train(hyp_dict, opt, device)
train(hyp_dict, opt, device, callbacks=Callbacks())


if __name__ == "__main__":

Loading…
Cancel
Save