I'm using spaCy which requires a much newer version of python-numpy than the system version provided by Debian Jessie. So I remove numpy using apt-get and install new versions using pip and pip3. But removing the system numpy removes my terminator (nice terminal app for Debian). I use this application all the time so I don't want it to disappear? Is there a way to retain the system version of numpy and also use a new version of numpy with spaCy? I don't want to use virtual machines. Is there a way to use virtualenv or some other tool to do this?
I've found a nice way of doing what the FHS should be doing by default. I can download the very latest pip3 version and install all recent packages in a way that will keep them separated from the rest of the OS (as /usr/local should be doing, but doesn't do!!!). I've included the spaCy installation as an example:
virtualenv -p python3 ~/bleeding-edge-virtualenv
source ~/bleeding-edge-virtualenv/bin/activate
mkdir -p python/workspaces && cd python/workspaces
wget https://bootstrap.pypa.io/get-pip.py -O ./get-pip.py
python3 ./get-pip.py
python3 --version
pip 9.0.1 from /home/ekenny/bleeding-edge-virtualenv/lib/python3.4/site-packages (python 3.4)
git clone https://github.com/explosion/spaCy
cd spaCy
pip3 download -m requirements.txt
pip3 install -r requirements.txt
python3 setup.py install
deactivate
Then I can remove all the crud under /usr/local and never have to worry about duplicate stuff. Full bleeding edge environment loadable at any time using activate . Happy days.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.