Jittor / jittor

Jittor is a high-performance deep learning framework based on JIT compiling and meta-operators.
https://cg.cs.tsinghua.edu.cn/jittor/
Apache License 2.0
3.08k stars 311 forks source link

manjaro安装jittor成功,启用cuda失败 #41

Open atmtntut opened 4 years ago

atmtntut commented 4 years ago

manjaro上安装jittor,由于不是ubuntu于是参考官方手动安装教程: 1.安装python3,python3-dev,pip,g++(我本来就装了,又装上llvm,clang,但后面会出几个错误,最后解决不掉放弃) 2.安装openmp,openmpi sudo pacman -S openmp openmpi 3.git clone https://github.com/Jittor/jittor.git 修改./jittor/setup.py,注释掉第12行关于ubuntu的断言 sudo pip3 install ./jittor export cc_path="g++" 4.python3 -m jittor.test.test_example 测试成功,至此可以尝下鲜了

5.export nvcc_path="/opt/cuda/bin/nvcc" python3 -m jittor.test.test_cuda 失败,报如下错误: [i 0328 18:08:32.095712 56 init.py:186] Found gdb(9.1) at /usr/bin/gdb. [i 0328 18:08:32.103046 56 init.py:186] Found addr2line(2.34) at /usr/bin/addr2line. [i 0328 18:08:32.197722 56 compiler.py:803] pybind_include: -I/usr/include/python3.8 -I/home/lmzl/.local/include/python3.8 [i 0328 18:08:32.214142 56 compiler.py:805] extension_suffix: .cpython-38-x86_64-linux-gnu.so [i 0328 18:08:32.415568 56 cuda_flags.cc:19] CUDA disabled. [i 0328 18:08:32.415576 56 jit_compiler.cc:20] Load cc_path: g++ [i 0328 18:08:32.415579 56 jit_compiler.cc:23] Load nvcc_path: /opt/cuda/bin/nvcc CUDA error at /usr/lib/python3.8/site-packages/jittor/src/ops/array_op.cc:29 code=35(cudaErrorInsufficientDriver) "cudaStreamCreateWithFlags(&stream, cudaStreamNonBlocking)" terminate called after throwing an instance of 'std::runtime_error' what(): CUDA error [1] 10783 abort (core dumped) python3 -m jittor.test.test_cuda

$ nvidia-smi Sat Mar 28 18:26:06 2020
+-----------------------------------------------------------------------------+ | NVIDIA-SMI 430.64 Driver Version: 430.64 CUDA Version: 10.1 | |-------------------------------+----------------------+----------------------+ | 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 On | N/A | | 37% 34C P0 30W / 120W | 338MiB / 6076MiB | 0% Default | +-------------------------------+----------------------+----------------------+

+-----------------------------------------------------------------------------+ | Processes: GPU Memory | | GPU PID Type Process name Usage | |=============================================================================| | 0 678 G /usr/lib/Xorg 18MiB | | 0 907 G /usr/lib/Xorg 120MiB | | 0 957 G /usr/bin/gnome-shell 84MiB | | 0 1400 G ...AAAAAAAAAAAAAAgAAAAAAAAA --shared-files 83MiB | +-----------------------------------------------------------------------------+

希望能尽快支持其他发行版,加油!

Jittor commented 4 years ago

谢谢您的支持,目前我们正式支持只有ubuntu,有用户在centos下尝试成功过。 我刚刚查了下cudaErrorInsufficientDriver这个错误,有可能是nvcc和显卡驱动不匹配导致的,您可以提供一下nvcc的版本信息吗nvcc --version

atmtntut commented 4 years ago

谢谢您的支持,目前我们正式支持只有ubuntu,有用户在centos下尝试成功过。 我刚刚查了下cudaErrorInsufficientDriver这个错误,有可能是nvcc和显卡驱动不匹配导致的,您可以提供一下nvcc的版本信息吗nvcc --version

我成功了! 确实是驱动和cuda版本不匹配导致的,升级驱动到最新,使驱动cuda版本,和cuda库版本一致就可以了,谢谢!

Jittor commented 4 years ago

谢谢~如果后续有任何问题欢迎反馈