2

I need to install numpy 1.9 ('cause some methods are available in this version, not in the previous) which isn't the numpy package proposed yet today (apt-get returns 1.8).

How to install the latest version of numpy, scipy, scikit and parallel python? I'm quite new to manage unusual install (using tar.gz?). My guess:

  • download the latest package and unpack them somewhere (how to do that and in which folder?)
  • adding some Personal Package Archives (PPA), but which one and how to do that sudo add-apt-repository ppa:<name of the ppa>? I tried but I have now some errors (connexion error to access ppa)

Thanks for your incoming help.

anonymous2
  • 4,325
sol
  • 135

1 Answers1

2

You need a custom Python environment? Build a custom Python environment. It's easy.

sudo apt-get install python-virtualenv

# cd to wherever you want to keep your distribution

# create it
virtualenv --no-site-packages virtualenv

# activate it
source ./virtualenv/bin/activate

pip install numpy scipy scikit-learn

You'd install all your other requirements in there too. You also have to make sure your scripts use the virtualenv too. If you're calling them globally, that can just mean making sure they're called with this /path/to/virtualenv/bin/python instead of your system version.

Or if they're called from a Bash script, you can call the activation script and your path will be updated automatically.


There is a strong argument against using pip in your global site-packages. Apt won't respect it. It won't respect Apt. They will trample over each other and can cause serious issues, especially if you accidentally upgrade a system package that isn't backwards compatible.

It seems easy to begin with but it's not a long-term solution.

Oli
  • 299,380