Skip to content

Commit

Permalink
Fix detect.py --update list bug (ultralytics#8783)
Browse files Browse the repository at this point in the history
Fix detect.py --update

Resolves ultralytics#8776
  • Loading branch information
glenn-jocher authored Jul 29, 2022
1 parent e309a85 commit 52d3a9a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion detect.py
Original file line number Diff line number Diff line change
Expand Up @@ -210,7 +210,7 @@ def run(
s = f"\n{len(list(save_dir.glob('labels/*.txt')))} labels saved to {save_dir / 'labels'}" if save_txt else ''
LOGGER.info(f"Results saved to {colorstr('bold', save_dir)}{s}")
if update:
strip_optimizer(weights) # update model (to fix SourceChangeWarning)
strip_optimizer(weights[0]) # update model (to fix SourceChangeWarning)


def parse_opt():
Expand Down

0 comments on commit 52d3a9a

Please sign in to comment.