Skip to content

Commit 7bc56d1

Browse files
committed
init setup script
0 parents  commit 7bc56d1

File tree

1 file changed

+72
-0
lines changed

1 file changed

+72
-0
lines changed

setup.sh

Lines changed: 72 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,72 @@
1+
echo "Update the package list..."
2+
sudo apt update
3+
echo "Upgrade installed packages..."
4+
sudo apt upgrade -y
5+
echo "Install necessary packages to minimal Ubuntu system..."
6+
sudo apt install -y fish wget bzip2 curl git gcc g++ python3-dev build-essential vim nano rsync
7+
sudo apt clean
8+
sudo apt autoremove -y
9+
echo "Install miniconda..."
10+
wget --quiet https://repo.anaconda.com/miniconda/Miniconda3-latest-Linux-x86_64.sh -O ~/miniconda.sh
11+
chmod +x miniconda.sh
12+
./miniconda.sh -b -p $HOME/miniconda3
13+
echo "Init bash for miniconda..."
14+
echo ". $HOME/miniconda3/etc/profile.d/conda.sh" >> ~/.profile
15+
source ~/.profile
16+
conda init bash
17+
source ~/.profile
18+
rm miniconda.sh
19+
echo "Create conda environment for Deep Learning..."
20+
echo "name: wildfire-dl
21+
channels:
22+
- pytorch
23+
- anaconda
24+
- conda-forge
25+
- defaults
26+
dependencies:
27+
- black=19.10b0
28+
- cudatoolkit=10.2.89
29+
- flake8=3.8.3
30+
- h5netcdf=0.8.1
31+
- imbalanced-learn=0.7.0
32+
- ipython=7.13.0
33+
- jupyter=1.0.0
34+
- jupyterlab=2.1.5
35+
- matplotlib=3.2.2
36+
- notebook=6.0.3
37+
- numpy=1.18.1
38+
- pandas=1.0.3
39+
- pip=20.0.2
40+
- plac=0.9.6
41+
- pre-commit=2.5.1
42+
- python=3.7.7
43+
- pytorch=1.6.0
44+
- regionmask=0.5.0
45+
- scikit-image=0.16.2
46+
- scipy=1.4.1
47+
- sphinx=3.1.1
48+
- tensorboard=2.2.2
49+
- torchvision=0.7.0
50+
- pip:
51+
- gsutil==4.52
52+
- netcdf4==1.5.3
53+
- pytorch-lightning==0.9.0
54+
- sphinx-autoapi==1.4.0
55+
- wandb==0.8.36" >> ~/environment.yml
56+
conda env create --file environment.yml
57+
echo "Clean up conda..."
58+
conda clean -a -y
59+
rm environment.yml
60+
echo "Downloading FWI Forcings to ~/data/fwi-forcings/..."
61+
mkdir data
62+
conda activate wildfire-dl
63+
cd data
64+
mkdir fwi-forcings
65+
gsutil -m cp gs://deepfwi-forcings/*201904* fwi-forcings/
66+
gsutil -m cp gs://deepfwi-forcings/*201905* fwi-forcings/
67+
gsutil -m cp gs://deepfwi-forcings/*201906* fwi-forcings/
68+
gsutil -m cp gs://deepfwi-forcings/*201907* fwi-forcings/
69+
gsutil -m cp gs://deepfwi-forcings/*201908* fwi-forcings/
70+
gsutil -m cp gs://deepfwi-forcings/*201909* fwi-forcings/
71+
echo "Rebooting system. Please login again after some time..."
72+
sleep 5; sudo reboot -h now

0 commit comments

Comments
 (0)