我对运行nvcc和nvidia-smi所显示的不同CUDA版本感到非常困惑。我在ubuntu 16.04上安装了cuda9.2和cuda10。现在我将PATH设置为cuda9.2。所以当我跑的时候
$ which nvcc
/usr/local/cuda-9.2/bin/nvcc
然而,当我跑步的时候
$ nvidia-smi
Wed Nov 21 19:41:32 2018
+-----------------------------------------------------------------------------+
| NVIDIA-SMI 410.72 Driver Version: 410.72 CUDA Version: 10.0 |
|-------------------------------+----------------------+----------------------+
| GPU Name Persistence-M| Bus-Id Disp.A | Volatile Uncorr. ECC |
| Fan Temp Perf Pwr:Usage/Cap| Memory-Usage | GPU-Util Compute M. |
|===============================+======================+======================|
| 0 GeForce GTX 106... Off | 00000000:01:00.0 Off | N/A |
| N/A 53C P0 26W / N/A | 379MiB / 6078MiB | 2% Default |
+-------------------------------+----------------------+----------------------+
+-----------------------------------------------------------------------------+
| Processes: GPU Memory |
| GPU PID Type Process name Usage |
|=============================================================================|
| 0 1324 G /usr/lib/xorg/Xorg 225MiB |
| 0 2844 G compiz 146MiB |
| 0 15550 G /usr/lib/firefox/firefox 1MiB |
| 0 19992 G /usr/lib/firefox/firefox 1MiB |
| 0 23605 G /usr/lib/firefox/firefox 1MiB |
所以我是使用cuda9.2作为nvcc建议,还是我使用cuda10作为nvidia-smi建议?我看到了这个答案,但它没有提供对混乱的直接答案,它只是要求我们重新安装CUDA工具包,我已经这样做了。