At the moment I am trying to install the python package pylearn2 on Ubuntu 16.04. Online I found 2 approaches that should work, this way:
sudo pip install git+git://github.com/lisa-lab/pylearn2.git
and this way:
git clone git://github.com/lisa-lab/pylearn2.git
cd ./pylearn2/
python setup.py develop
However neither work. The first approach gives as output:
The directory '/home/myUser/.cache/pip/http' or its parent directory is not owned by the current user and the cache has been disabled. Please check the permissions and owner of that directory. If executing pip with sudo, you may want sudo's -H flag.
The directory '/home/myUser/.cache/pip' or its parent directory is not owned by the current user and caching wheels has been disabled. check the permissions and owner of that directory. If executing pip with sudo, you may want sudo's -H flag.
Collecting git+git://github.com/lisa-lab/pylearn2.git
Cloning git://github.com/lisa-lab/pylearn2.git to /tmp/pip-Tnu1do-build
Requirement already satisfied (use --upgrade to upgrade): pylearn2==0.1.dev0 from git+git://github.com/lisa-lab/pylearn2.git in /home/myUser/Documents/python downloads/pylearn2
Requirement already satisfied: numpy>=1.5 in /usr/lib/python2.7/dist-packages (from pylearn2==0.1.dev0)
Requirement already satisfied: pyyaml in /usr/local/lib/python2.7/dist-packages/PyYAML-3.12-py2.7-linux-x86_64.egg (from pylearn2==0.1.dev0)
Requirement already satisfied: argparse in /usr/lib/python2.7 (from pylearn2==0.1.dev0)
Requirement already satisfied: Theano in /usr/local/lib/python2.7/dist-packages (from pylearn2==0.1.dev0)
Requirement already satisfied: scipy>=0.11 in /usr/lib/python2.7/dist-packages (from Theano->pylearn2==0.1.dev0)
Requirement already satisfied: six>=1.9.0 in /usr/local/lib/python2.7/dist- packages (from Theano->pylearn2==0.1.dev0)
I would expect a message after this either about installing pylearn2, or about an error, but neither occurs. The second approach does give an error:
/usr/local/lib/python2.7/dist-packages/setuptools/dist.py:332: UserWarning: Normalizing '0.1dev' to '0.1.dev0'
normalized_version,
running develop
running egg_info
writing requirements to pylearn2.egg-info/requires.txt
writing pylearn2.egg-info/PKG-INFO
writing top-level names to pylearn2.egg-info/top_level.txt
writing dependency_links to pylearn2.egg-info/dependency_links.txt
reading manifest file 'pylearn2.egg-info/SOURCES.txt'
reading manifest template 'MANIFEST.in'
writing manifest file 'pylearn2.egg-info/SOURCES.txt'
running build_ext
skipping 'pylearn2/utils/_window_flip.c' Cython extension (up-to-date)
building 'pylearn2.utils._window_flip' extension
C compiler: 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
compile options: '-I/usr/lib/python2.7/dist-packages/numpy/core/include -I/usr/include/python2.7 -c'
Warning: Can`t read registry to find the necessary compiler setting
Make sure that Python modules _winreg, win32api or win32con are installed.
x86_64-linux-gnu-gcc: pylearn2/utils/_window_flip.c
In file included from /usr/lib/python2.7/dist-packages/numpy/core/include/numpy/ndarraytypes.h:1777:0,
from /usr/lib/python2.7/dist-packages/numpy/core/include/numpy/ndarrayobject.h:18,
from /usr/lib/python2.7/dist-packages/numpy/core/include/numpy/arrayobject.h:4,
from pylearn2/utils/_window_flip.c:274:
/usr/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 " \
^
In file included from /usr/lib/python2.7/dist-packages/numpy/core/include/numpy/ndarrayobject.h:27:0,
from /usr/lib/python2.7/dist-packages/numpy/core/include/numpy/arrayobject.h:4,
from pylearn2/utils/_window_flip.c:274:
/usr/lib/python2.7/dist-packages/numpy/core/include/numpy/__multiarray_api.h:1448:1: warning: ‘_import_array’ defined but not used [-Wunused-function]
_import_array(void)
^
x86_64-linux-gnu-gcc -pthread -shared -Wl,-O1 -Wl,-Bsymbolic-functions -Wl,-Bsymbolic-functions -Wl,-z,relro -fno-strict-aliasing -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes -Wdate-time -D_FORTIFY_SOURCE=2 -g -fstack-protector-strong -Wformat -Werror=format-security -Wl,-Bsymbolic-functions -Wl,-z,relro -Wdate-time -D_FORTIFY_SOURCE=2 -g -fstack-protector-strong -Wformat -Werror=format-security build/temp.linux-x86_64-2.7/pylearn2/utils/_window_flip.o -o /home/myUser/Documents/python downloads/pylearn2/pylearn2/utils/_window_flip.so
x86_64-linux-gnu-gcc: error: downloads/pylearn2/pylearn2/utils/_window_flip.so: No such file or directory
x86_64-linux-gnu-gcc: error: downloads/pylearn2/pylearn2/utils/_window_flip.so: No such file or directory
error: Command "x86_64-linux-gnu-gcc -pthread -shared -Wl,-O1 -Wl,-Bsymbolic-functions -Wl,-Bsymbolic-functions -Wl,-z,relro -fno-strict-aliasing -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes -Wdate-time -D_FORTIFY_SOURCE=2 -g -fstack-protector-strong -Wformat -Werror=format-security -Wl,-Bsymbolic-functions -Wl,-z,relro -Wdate-time -D_FORTIFY_SOURCE=2 -g -fstack-protector-strong -Wformat -Werror=format-security build/temp.linux-x86_64-2.7/pylearn2/utils/_window_flip.o -o /home/myUser/Documents/python downloads/pylearn2/pylearn2/utils/_window_flip.so" failed with exit status 1
I think the problem might lie in the lines:
x86_64-linux-gnu-gcc: error: downloads/pylearn2/pylearn2/utils/_window_flip.so: No such file or directory
x86_64-linux-gnu-gcc: error: downloads/pylearn2/pylearn2/utils/_window_flip.so: No such file or directory
Does anyone have more insight in what could be going wrong here?