forked from oxford-cs-deepnlp-2017/practical-1
-
Notifications
You must be signed in to change notification settings - Fork 0
/
install-python.sh
executable file
·38 lines (29 loc) · 922 Bytes
/
install-python.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
#!/bin/bash
##############################
# check if installation is already done in user's dir
USER_DIR=/home/scratch/$USER/anaconda3
if [ -d $USER_DIR ] ; then
echo You already have a directory called $USER_DIR
echo You have either already installed it, or you can remove this
echo directory and rerun this script if you are trying to reinstall.
exit 1
fi
##############################
# install python
echo Installing python 3.5
# Go to tmp
cd /tmp/
# Download Anaconda python 3.5
wget --quiet https://repo.continuum.io/archive/Anaconda3-4.2.0-Linux-x86_64.sh
bash Anaconda3-4.2.0-Linux-x86_64.sh -b -p $USER_DIR
rm Anaconda3-4.2.0-Linux-x86_64.sh
# Add anaconda3 path
printf "export PATH='%s/bin':\$PATH" "$USER_DIR" >> ~/.bashrc
source ~/.bashrc
# Update anaconda
conda update -y conda
# Install word2vec dependencies
pip install gensim
echo
echo Anaconda python 3.5 has been installed
echo