Issue
When doing custom model training with Yolov5, the modeling framework seems to feel that I should be using Weights and Biases (wandb
), ClearML, TensorBoard, and other external MLOps applications that I don't need and don't want to see excess messages about. Is there any way to make it ignore these and work?
Previously I could successfully do training and this was just an annoyance. Now for some reason it's actually preventing training from running:
wandb: (1) Create a W&B account
wandb: (2) Use an existing W&B account
wandb: (3) Don't visualize my results
wandb: Enter your choice: (30 second timeout)
wandb: W&B disabled due to login timeout.
train: weights=yolov5s.pt, cfg=, data=../export-2022-09-19T17_46_47.492Z/export-2022-09-19T17_46_47.492Z.yaml, hyp=data/hyps/hyp.scratch-low.yaml, epochs=5, batch_size=16, imgsz=640, rect=False, resume=False, nosave=False, noval=False, noautoanchor=False, noplots=False, evolve=None, bucket=, cache=None, image_weights=False, device=, multi_scale=False, single_cls=False, optimizer=SGD, sync_bn=False, workers=8, project=runs/train, name=exp, exist_ok=False, quad=False, cos_lr=False, label_smoothing=0.0, patience=100, freeze=[0], save_period=-1, seed=0, local_rank=-1, entity=None, upload_dataset=False, bbox_interval=-1, artifact_alias=latest
remote: Enumerating objects: 78, done.
remote: Counting objects: 100% (78/78), done.
remote: Compressing objects: 100% (44/44), done.
remote: Total 78 (delta 50), reused 49 (delta 34), pack-reused 0
Unpacking objects: 100% (78/78), done.
From https://github.com/ultralytics/yolov5
0b724c5..e233c03 master -> origin/master
3cb5c9d..0706315 exp/scaleFill -> origin/exp/scaleFill
* [new branch] exp8/shortcut_gain -> origin/exp8/shortcut_gain
* [new branch] fix/tf -> origin/fix/tf
68a201a..b815294 update/cls-album -> origin/update/cls-album
github: ⚠️ YOLOv5 is out of date by 5 commits. Use `git pull` or `git clone https://github.com/ultralytics/yolov5` to update.
YOLOv5 🚀 v6.2-141-g0b724c5 Python-3.10.6 torch-1.12.1 CPU
hyperparameters: lr0=0.01, lrf=0.01, momentum=0.937, weight_decay=0.0005, warmup_epochs=3.0, warmup_momentum=0.8, warmup_bias_lr=0.1, box=0.05, cls=0.5, cls_pw=1.0, obj=1.0, obj_pw=1.0, iou_t=0.2, anchor_t=4.0, fl_gamma=0.0, hsv_h=0.015, hsv_s=0.7, hsv_v=0.4, degrees=0.0, translate=0.1, scale=0.5, shear=0.0, perspective=0.0, flipud=0.0, fliplr=0.5, mosaic=1.0, mixup=0.0, copy_paste=0.0
Weights & Biases: run 'pip install wandb' to automatically track and visualize YOLOv5 🚀 runs in Weights & Biases
Comet: run 'pip install comet_ml' to automatically track and visualize YOLOv5 🚀 runs in Comet
TensorBoard: Start with 'tensorboard --logdir runs/train', view at http://localhost:6006/
Traceback (most recent call last):
File "/Users/some.person/Documents/mypath/yolov5/train.py", line 630, in <module>
main(opt)
File "/Users/some.person/Documents/mypath/yolov5/train.py", line 526, in main
train(opt.hyp, opt, device, callbacks)
File "/Users/some.person/Documents/mypath/yolov5/train.py", line 94, in train
loggers = Loggers(save_dir, weights, opt, hyp, LOGGER) # loggers instance
File "/Users/some.person/Documents/mypath/yolov5/utils/loggers/__init__.py", line 121, in __init__
self.clearml = ClearmlLogger(self.opt, self.hyp)
File "/Users/some.person/Documents/mypath/yolov5/utils/loggers/clearml/clearml_utils.py", line 87, in __init__
self.task = Task.init(
File "/usr/local/lib/python3.10/site-packages/clearml/task.py", line 583, in init
task = cls._create_dev_task(
File "/usr/local/lib/python3.10/site-packages/clearml/task.py", line 3035, in _create_dev_task
task = cls(
File "/usr/local/lib/python3.10/site-packages/clearml/task.py", line 183, in __init__
super(Task, self).__init__(**kwargs)
File "/usr/local/lib/python3.10/site-packages/clearml/backend_interface/task/task.py", line 155, in __init__
super(Task, self).__init__(id=task_id, session=session, log=log)
File "/usr/local/lib/python3.10/site-packages/clearml/backend_interface/base.py", line 145, in __init__
super(IdObjectBase, self).__init__(session, log, **kwargs)
File "/usr/local/lib/python3.10/site-packages/clearml/backend_interface/base.py", line 39, in __init__
self._session = session or self._get_default_session()
File "/usr/local/lib/python3.10/site-packages/clearml/backend_interface/base.py", line 115, in _get_default_session
InterfaceBase._default_session = Session(
File "/usr/local/lib/python3.10/site-packages/clearml/backend_api/session/session.py", line 178, in __init__
raise ValueError(
ValueError: ClearML configuration could not be found (missing `~/clearml.conf` or Environment CLEARML_API_HOST)
To get started with ClearML: setup your own `clearml-server`, or create a free account at https://app.clear.ml
Jupyter Lab notebook cell value that invoked these errors:
!python3 train.py --img 640 --batch 16 --epochs 5 --data '../myfolder/export-2022-09.yaml' --weights yolov5s.pt
Solution
By uninstalling their pip packages:
pip3 uninstall clearml
pip3 uninstall wandb
Otherwise it will try to log into ClearML, Weights and Biases, etc. Do not uninstall tensorboard
.
Answered By - Mikel B
0 comments:
Post a Comment
Note: Only a member of this blog may post a comment.