Install numpy without sudo

I am trying to install numpy on a remote host where I do not have administrator privileges. I have successfully installed Python 2.7 and pip inside virtualenv and can use pip to install trivial things like pip install Markdown. But if I write install numpy or scipy, these are errors on SystemError: Cannot compile 'Python.h'. Perhaps you need to install python-dev|python-devel.I do not have rights to sudo apt-get or apt-get, therefore I can not do sudo apt-get install python27-develor sudo apt-get install python-devel. I wanted to build from the source to use the --user option, but the source is the .deb file, and to build it requires even more things that I need apt-get. I tried contacting the administrator, but I am advised to leave my own settings in my local environment. What should I do? OS system - Ubuntu 14.04 LTS.

+4
source share
1 answer

The reason for the response of the admins is simple. Ubuntu also uses python for internal scripts. This way the administrator will not update or modify the python installation if you need a newer version of the package.

Here is what I would like to try:

  • Compile the python 2.7 source yourself and set it to your preferred path in your home directory. This way you always have all the necessary headers. Put the translator in your PATH.

(optional) Install PYTHONUSERHOME in local python site packages.

  • Install virtualenv package via pip
  • Configuring virtualenv envirnoment for numpy etc.

() 4. Blas, . OpenBlas

  • cython virtualenv... , , , numpy
  • numpy scipy virtualenv BLAS

python, virtualenv . . , python .

+1

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


All Articles