-
Notifications
You must be signed in to change notification settings - Fork 7
Description
I have been trying to use YOEO on a custom dataset, but the config file for custom datasets you mentionned in the README doesnt exist :
"To train on the custom dataset run:
poetry run yoeo-train --model config/yoeo-custom.cfg --data config/custom.data"
Heres the environment information as printed when running the script :
Environment information:
System: Windows 10
Current Version: YOEO 1.6.0
Current Commit Hash: d0393c1
Command line arguments: Namespace(model='config/yoeo-custom.cfg', data='config/custom.data', epochs=300, verbose=False, n_cpu=8, pretrained_weights=None, checkpoint_interval=1, checkpoint_dir='checkpoints', evaluation_interval=1, multiscale_training=False, iou_thres=0.5, conf_thres=0.1, nms_thres=0.5, logdir='logs', seed=-1, class_config='class_config/default.yaml')
I also tried using --model config/yoeo.cfg but I am getting an Index Error (I do not know if it is related to the configuration I am using or not) :
Traceback (most recent call last):
File "", line 1, in
File "C:\Users\Alexandre Bonin\Documents\Stage\YOEO\yoeo\train.py", line 176, in run
loss, loss_components = compute_loss(outputs, (bb_targets, mask_targets), model)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Alexandre Bonin\Documents\Stage\YOEO\yoeo\utils\loss.py", line 66, in compute_loss
seg_loss = nn.CrossEntropyLoss()(seg_predictions[0], seg_targets).unsqueeze(0)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Alexandre Bonin\AppData\Local\pypoetry\Cache\virtualenvs\yoeo-ZupAADRy-py3.12\Lib\site-packages\torch\nn\modules\module.py", line 1736, in _wrapped_call_impl
return self._call_impl(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Alexandre Bonin\AppData\Local\pypoetry\Cache\virtualenvs\yoeo-ZupAADRy-py3.12\Lib\site-packages\torch\nn\modules\module.py", line 1747, in _call_impl
return forward_call(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Alexandre Bonin\AppData\Local\pypoetry\Cache\virtualenvs\yoeo-ZupAADRy-py3.12\Lib\site-packages\torch\nn\modules\loss.py", line 1293, in forward
return F.cross_entropy(
^^^^^^^^^^^^^^^^
File "C:\Users\Alexandre Bonin\AppData\Local\pypoetry\Cache\virtualenvs\yoeo-ZupAADRy-py3.12\Lib\site-packages\torch\nn\functional.py", line 3479, in cross_entropy
return torch._C._nn.cross_entropy_loss(
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
IndexError: Target 4 is out of bounds.
I also haven't updated the class_config file, as it wasn't mentionned in the documentation, but was careful of following the expected data format for custom datasets.
Thank you for your help