@KZ400 (Shoot You)

Are you sure you want to delete the question?

If your question is resolved, you may close it.

Leaving a resolved question undeleted may help others!

We hope you find it useful!

Yolov3で学習、!makeでエラー

Yolov3で学習、!makeでエラー

Yolov3で学習しています。!makeで以下のようなエラーが発生します。
解決方法を教えてください。

エラー文

gcc -Iinclude/ -Isrc/ -DGPU -I/usr/local/cuda/include/ -Wall -Wno-unused-result -Wno-unknown-pragmas -Wfatal-errors -fPIC -Ofast -DGPU -c ./src/iseg_layer.c -o obj/iseg_layer.o
g++ -Iinclude/ -Isrc/ -DGPU -I/usr/local/cuda/include/ -Wall -Wno-unused-result -Wno-unknown-pragmas -Wfatal-errors -fPIC -Ofast -DGPU -c ./src/image_opencv.cpp -o obj/image_opencv.o
nvcc -gencode arch=compute_30,code=sm_30 -gencode arch=compute_35,code=sm_35 -gencode arch=compute_50,code=[sm_50,compute_50] -gencode arch=compute_52,code=[sm_52,compute_52] -Iinclude/ -Isrc/ -DGPU -I/usr/local/cuda/include/ --compiler-options "-Wall -Wno-unused-result -Wno-unknown-pragmas -Wfatal-errors -fPIC -Ofast -DGPU" -c ./src/convolutional_kernels.cu -o obj/convolutional_kernels.o
nvcc fatal   : Unsupported gpu architecture 'compute_30'
Makefile:92: recipe for target 'obj/convolutional_kernels.o' failed
make: *** [obj/convolutional_kernels.o] Error1 

該当するソースコード

nvcc fatal   : Unsupported gpu architecture 'compute_30'
Makefile:92: recipe for target 'obj/convolutional_kernels.o' failed
make: *** [obj/convolutional_kernels.o] Error 1

自分で試したこと

darknetのファイルにあるMakefileの中のNVCCのパスを正しく指定すると解決するとあったのでしてみたがまず、nvccが見つからない。
また、過去3回このコードを回しているがエラーは出なかった。

0 likes

2Answer

エラーメッセージを見ると compute_30 というGPUアーキテクチャはサポートしていないと言っています。

nvcc fatal   : Unsupported gpu architecture 'compute_30'

nvcc のバージョンを確かめて、サポートしているアーキテクチャに修正すればよいのではないでしょうか?

例えば、以下は v11.3.0 のドキュメントです

See Virtual Architecture Feature List for the list of supported virtual architectures and GPU Feature List for the list of supported real architectures.

0Like

返信ありがとうございます。
nvccのバージョンが変更されていたようです。
バージョンを合わせることで解決できました。

0Like

Your answer might help someone💌