Skip to content

Commit

Permalink
W&B: Allow changed in config variable ultralytics#3588
Browse files Browse the repository at this point in the history
(cherry picked from commit 53d4fc2)
  • Loading branch information
AyushExel authored and Lechtr committed Jun 14, 2021
1 parent 85bb03c commit e64826f
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions utils/wandb_logging/wandb_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,11 @@ def __init__(self, opt, name, run_id, data_dict, job_type='Training'):
model_artifact_name = WANDB_ARTIFACT_PREFIX + model_artifact_name
assert wandb, 'install wandb to resume wandb runs'
# Resume wandb-artifact:// runs here| workaround for not overwriting wandb.config
self.wandb_run = wandb.init(id=run_id, project=project, entity=entity, resume='allow')
self.wandb_run = wandb.init(id=run_id,
project=project,
entity=entity,
resume='allow',
allow_val_change=True)
opt.resume = model_artifact_name
elif self.wandb:
self.wandb_run = wandb.init(config=opt,
Expand All @@ -113,7 +117,8 @@ def __init__(self, opt, name, run_id, data_dict, job_type='Training'):
name=name,
job_type=job_type,
group=opt.wandb_group,
id=run_id) if not wandb.run else wandb.run
id=run_id,
allow_val_change=True) if not wandb.run else wandb.run
if self.wandb_run:
if self.job_type == 'Training':
if not opt.resume:
Expand Down

0 comments on commit e64826f

Please sign in to comment.