Open MuhabHariri opened 1 month ago
Note: I followed the instructions as provided in the repository documentation
conda create -n yolov10 python=3.9
conda activate yolov10
pip install -r requirements.txt
pip install -e .
However, when I attempted to train the model with the following command:
yolo detect train data=coco8.yaml model=yolov10n.yaml epochs=1 batch=32 imgsz=640 device=0,1
I encountered this issue.:
(yolov10) C:\Users\muh\yolov10>yolo detect train data=coco.yaml model=yolov10n.yaml epochs=50 batch=32 imgsz=640 device=0,1
New https://pypi.org/project/ultralytics/8.2.28 available π Update with 'pip install -U ultralytics'
Ultralytics YOLOv8.1.34 π Python-3.10.9 torch-2.0.1+cpu
Traceback (most recent call last):
File "C:\Users\muh\anaconda3\lib\runpy.py", line 196, in _run_module_as_main
return _run_code(code, main_globals, None,
File "C:\Users\muh\anaconda3\lib\runpy.py", line 86, in _run_code
exec(code, run_globals)
File "C:\Users\muh\Anaconda3\Scripts\yolo.exe\__main__.py", line 7, in <module>
File "C:\Users\muh\yolov10\ultralytics\cfg\__init__.py", line 594, in entrypoint
getattr(model, mode)(**overrides) # default args from model
File "C:\Users\muh\yolov10\ultralytics\engine\model.py", line 638, in train
self.trainer = (trainer or self._smart_load("trainer"))(overrides=args, _callbacks=self.callbacks)
File "C:\Users\muh\yolov10\ultralytics\engine\trainer.py", line 100, in __init__
self.device = select_device(self.args.device, self.args.batch)
File "C:\Users\muh\yolov10\ultralytics\utils\torch_utils.py", line 128, in select_device
raise ValueError(
ValueError: Invalid CUDA 'device=0,1' requested. Use 'device=cpu' or pass valid CUDA device(s) if available, i.e. 'device=0' or 'device=0,1,2,3' for Multi-GPU.
torch.cuda.is_available(): False
torch.cuda.device_count(): 0
os.environ['CUDA_VISIBLE_DEVICES']: None
See https://pytorch.org/get-started/locally/ for up-to-date torch install instructions if no CUDA devices are seen by torch.
The training does not work when using "device=0,1". It only proceeds when I omit it, resulting in the use of the CPU instead of the GPUs. Therefore, I installed CUDA 11.8, compatible with PyTorch 2.0.1, using the following command: "pip install torch==2.0.1+cu118 -f https://download.pytorch.org/whl/torch_stable.html". After this installation, I encountered the error mentioned at the beginning of this thread.
I have some errors like youοΌmy GPU_mem is 0οΌworkers is 0οΌdo you solve itοΌ
@sofaraway-9527 Did you solve it ?
@sofaraway-9527 Did you solve it ?
Hello, I meet the same problem with you. Did you solve it ?
@sofaraway-9527 Did you solve it ?
I solved this problem just now by installing CUDA 11.7, maybe you can have a try.
Hi
I am facing this error during training yolov10:
Here's some information about the environment and setup I am using:
Please let me know if you can help me solve this problem.
Thanks