How to install libgpuarray and clBLAS in python on mac os x (10.9)?

I am trying to install libgpuarray ( http://deeplearning.net/software/libgpuarray/installation.html ) for python on OSX 10.9. I installed CMake 3.0 and use the user interface. I downloaded the libgpuarray and clBLAS source code from git and unpacked it into the Users / user / libgpuarray ../ clBLAS folder, respectively.

Using CMake UI, I get the following warning when creating an assembly:

MACOSX_RPATH is not specified for the following purposes:

gpuarray (clBLAS respectively)

Running 'python setup.py build' results in the following error:

/Users/i043337/Library/Python/2.7/lib/python/site-packages/numpy/core/include/numpy/npyy_1_7_deprecated_api.h:15:2: warning:

"Using deprecated NumPy API, disable it by " "#defining NPY_NO_DEPRECATED_API NPY_1_7_API_VERSION" [-W#warnings] 

'# warning "Using the deprecated NumPy API, disable it with" \
^
pygpu / gpuarray.c: 354: 10: fatal error: gpuarray / types.h file not found - '#include "gpuarray / types.h"

Tried to figure out how to set the right path, but I'm lost to be honest.

Any help is more than appreciated!

The latest Xcode (including DeveloperTools) is installed. The Python version is 2.7 from python.org and under the following paths (Terminal $ type -a python)

python - / Library / Frameworks / Python.framework / Versions / 2.7 / bin / python
python - / usr / bin / python
python: / usr / local / bin / python

+6
source share
3 answers

I solved this by doing:

 python setup.py build_ext -I /usr/local/include -L /usr/local/lib 

instead:

 python setup.py build 

and it decided. You could probably add them to your PATH as an alternative.

Also, for anyone who will run this in the future, you may have to change link.txt in Build / src / CMakeFiles / gpuarray.dir to:

 1) omit -arch=i386 2) add -F/Library/Frameworks 

after running make in the Build / directory that you created.

0
source

I think you forgot to run

 make make install 

after cmake.

0
source

I installed it by running the following commands:

mkdir build && & cd build

cmake ..

make && & make install

cd .. && Installing python setup.py

-1
source

Source: https://habr.com/ru/post/973167/


All Articles