本文主要是介绍yolov8 ultralytics库进行多机多卡DDP训练,希望对大家解决编程问题提供一定的参考价值,需要的开发者们随着小编来一起学习吧!
参考:
https://github.com/ultralytics/ultralytics/issues/6286
ddp训练报错,问题修改:
https://blog.csdn.net/weixin_41012399/article/details/134379417
RuntimeError: CUDA error: invalid device ordinal CUDA kernel errors
might be asynchronously reported at some other API call, so the
stacktrace below might be incorrect. For debugging consider passing
CUDA_LAUNCH_BLOCKING=1. Compile withTORCH_USE_CUDA_DSA
to enable
device-side assertions.
主要修改机器二上代码即可(主节点不用修改):
1)/root/miniconda3/envs/up/lib/python3.9/site-packages/ultralytics/engine/trainer.py
from ultralytics.utils import (DEFAULT_CFG, LOGGER, RANK
这篇关于yolov8 ultralytics库进行多机多卡DDP训练的文章就介绍到这儿,希望我们推荐的文章对编程师们有所帮助!