1. 問(wèn)題描述
依然是在 wsl2 下的 ubuntu20.04 上運(yùn)行 YOLOv8 出現(xiàn)了以下錯(cuò)誤
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.
網(wǎng)上搜索的,得到的結(jié)果可能是說(shuō) torch、torchvision、cuda版本不對(duì)應(yīng)導(dǎo)致,并采用下列方式解決
torch.cuda.current_device()
但實(shí)際上有可能是無(wú)法解決的
,至少對(duì)于我來(lái)說(shuō)是這樣的 ??文章來(lái)源:http://www.zghlxwxcb.cn/news/detail-651994.html
2. 解決問(wèn)題 ?
?? 導(dǎo)致此問(wèn)題的原因可能是 指定的GPU的顯存不足
,需要將 batch size 改小
文章來(lái)源地址http://www.zghlxwxcb.cn/news/detail-651994.html
到了這里,關(guān)于【Error】CUDA error: unknown error的文章就介紹完了。如果您還想了解更多內(nèi)容,請(qǐng)?jiān)谟疑辖撬阉鱐OY模板網(wǎng)以前的文章或繼續(xù)瀏覽下面的相關(guān)文章,希望大家以后多多支持TOY模板網(wǎng)!