error MSB3721: "C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v9.0\bin\nvcc.exe" -genco

created at 08-26-2021 views: 24

error message

error MSB3721: "C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v9.0\bin\nvcc.exe" -gencode=arch=compute_20,code=“sm_20,compute_20” -gencode=arch=compute_30,code=“sm_30,compute_30” -gencode=arch=compute_50,code=“sm_50,compute_50” --use-local-env -ccbin "C:\Program Files
(cuda9.0targets 707)

environment

  • window10
  • cuda9.0
  • cudnn
  • visual Studio2015

reason

I set the CUDA Toolkit Custom Dir wrong. I set it to C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA at the beginning. I opened the file location and found that it was wrong. It needs to be set to C:\Program Files\NVIDIA GPU Computing Toolkit\ CUDA\v9.0

CUDA Toolkit Custom Dir

Then the problem solved.

created at:08-26-2021
edited at: 08-26-2021: