jeongyoonlee / Kaggler

Code for Kaggle Data Science Competitions

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

pip install on ubuntu 16.04

zilion22 opened this issue · comments

By
pip install kaggler

on ubuntu 16.04 one would get:

creating build/temp.linux-x86_64-2.7/kaggler/online_model/murmurhash
x86_64-linux-gnu-gcc -pthread -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes -fno-strict-aliasing -Wdate-time -D_FORTIFY_SOURCE=2 -g -fstack-protector-strong -Wformat -Werror=format-security -fPIC -I/usr/local/lib/python2.7/dist-packages/numpy/core/include -I. -I/usr/include/python2.7 -c kaggler/online_model/ftrl.c -o build/temp.linux-x86_64-2.7/kaggler/online_model/ftrl.o -O3
In file included from /usr/local/lib/python2.7/dist-packages/numpy/core/include/numpy/ndarraytypes.h:1788:0,
                 from /usr/local/lib/python2.7/dist-packages/numpy/core/include/numpy/ndarrayobject.h:18,
                 from /usr/local/lib/python2.7/dist-packages/numpy/core/include/numpy/arrayobject.h:4,
                 from kaggler/online_model/ftrl.c:275:
/usr/local/lib/python2.7/dist-packages/numpy/core/include/numpy/npy_1_7_deprecated_api.h:15:2: warning: #warning "Using deprecated NumPy API, disable it by " "#defining NPY_NO_DEPRECATED_API NPY_1_7_API_VERSION" [-Wcpp]
 #warning "Using deprecated NumPy API, disable it by " \
  ^
kaggler/online_model/ftrl.c:277:36: fatal error: murmurhash/MurmurHash3.h: No such file or directory
compilation terminated.
error: command 'x86_64-linux-gnu-gcc' failed with exit status 1

And I have found no way to install MurmurHash3.h on ubuntu 16.04

Thanks for using Kaggler!

murmurhash/MurmurHash3.h is included in the package.

It seems like that you need to add . to LD_LIBRARY_PATH as follows:

# if running bash:
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:.

# if running csh/tcsh:
setenv LD_LIBRARY_PATH $LD_LIBRARY_PATH:.

Hope it helps.

commented

I have the same issue.
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:. didn't help.

gcc -pthread -Wno-unused-result -Wsign-compare -DNDEBUG -g -fwrapv -O3 -Wall -m64 -fPIC -m64 -fPIC -fPIC -I/opt/conda/lib/python3.6/site-packages/numpy/core/include -I. -I/opt/conda/include/python3.6m -c kaggler/online_model/ftrl.c -o build/temp.linux-x86_64-3.6/kaggler/online_model/ftrl.o -O3 In file included from /opt/conda/lib/python3.6/site-packages/numpy/core/include/numpy/ndarraytypes.h:1821:0, from /opt/conda/lib/python3.6/site-packages/numpy/core/include/numpy/ndarrayobject.h:18, from /opt/conda/lib/python3.6/site-packages/numpy/core/include/numpy/arrayobject.h:4, from kaggler/online_model/ftrl.c:614: /opt/conda/lib/python3.6/site-packages/numpy/core/include/numpy/npy_1_7_deprecated_api.h:15:2: warning: #warning "Using deprecated NumPy API, disable it by " "#defining NPY_NO_DEPRECATED_API NPY_1_7_API_VERSION" [-Wcpp] #warning "Using deprecated NumPy API, disable it by " \ ^ kaggler/online_model/ftrl.c:616:36: fatal error: murmurhash/MurmurHash3.h: No such file or directory compilation terminated. error: command 'gcc' failed with exit status 1

Thanks @sagol. I will look into it later today or tomorrow. Meanwhile, you can install Kaggler from source.

@sagol The pip installation issue has been fixed and you can use pip to install kaggler now. Thanks!