首页 > 解决方案 > 测试yolov3模型时出现cuda错误>> CUDA状态错误:文件:./src/dark_cuda.c : ()

问题描述

CUDA status Error: file: ./src/dark_cuda.c : () : line: 39 : build time: Feb  9 2021 - 13:15:44 

CUDA Error: no CUDA-capable device is detected
CUDA Error: no CUDA-capable device is detected: Bad file descriptor
darknet: ./src/utils.c:331: error: Assertion `0' failed.

我在 G-Colab 上用自定义数据训练了一个 yolov3 模型,在测试时遇到了这个错误。 在用于测试的 yolov3 cfg 中,我采用 batch = 1 和 subdivisons = 1,而对于训练,我采用 batch = 32 和 subdivisions = 8

标签: deep-learningcomputer-visionconv-neural-networkyolodarknet

解决方案


我通过运行这个暗网解决了它>> https://github.com/AlexeyAB/darknet

%cd darknet
!sed -i 's/GPU=0/GPU=1/g' Makefile
!cat Makefile
!make

推荐阅读