andersbll / cudarray

CUDA-based NumPy
MIT License
233 stars 61 forks source link

ImportError: No module named conv_bc01 #72

Open ryh95 opened 7 years ago

ryh95 commented 7 years ago

Dear andersbll

I installed the cuda and cuDNN correctlly screenshot from 2016-12-03 18 22 06 screenshot from 2016-12-03 18 22 19

then I switched into cudarray directory

make
sudo make install
sudo python setup.py install

works fine but when I want to check if I have installed it correctly

python
import cudarray

problem appears

CUDArray: CUDA back-end not available, using NumPy.
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "cudarray/__init__.py", line 40, in <module>
    from .numpy_backend import *
  File "cudarray/numpy_backend/__init__.py", line 2, in <module>
    from .nnet import *
  File "cudarray/numpy_backend/nnet/__init__.py", line 3, in <module>
    from .conv_bc01 import *
ImportError: No module named conv_bc01

and here is my bashrc

screenshot from 2016-12-03 18 10 26

As a newbie to linux and deep learning tool, I worked on this problem for hours, but still don't make any progress.

Any suggestions would be appreciated.Thank you very much.

Era-Dorta commented 7 years ago

I had the same problem and I solved it by installing in a separate folder with virtualenv

mkdir larsen && cd larsen virtualenv venv && source venv/bin/activate export PYTHONPATH= pip install numpy cython git clone https://github.com/andersbll/cudarray.git mkdir -p cudarrayInstall/lib export INSTALL_PREFIX=$(pwd)/cudarrayInstall export CUDA_PREFIX=/usr/local/cuda export CUDNN_ENABLED=1 cd cudarray && make -j8 && make install python setup.py install

Close the terminal and open a new one cd larsen source venv/bin/activate export PYTHONPATH= export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$(pwd)/cudarrayInstall/lib Run python and import cudarray

myzhang1029 commented 2 years ago

I know this is old but in case anyone is running into this issue, please make sure you are not running inside cudarray's source directory.