forked from Alibaba-MIIL/TResNet
-
Notifications
You must be signed in to change notification settings - Fork 0
/
sotabench_setup.sh
46 lines (39 loc) · 2.12 KB
/
sotabench_setup.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
39
40
41
42
43
44
45
46
#!/usr/bin/env bash -x
source /workspace/venv/bin/activate
PYTHON=${PYTHON:-"python"}
export DEBIAN_FRONTEND=noninteractive
# REPO="$( cd "$(dirname "$0")" ; cd .. ; pwd -P )"
# cd $REPO
$PYTHON -m pip install -e .
$PYTHON -m pip install torch==1.4.0
$PYTHON -m pip install torchvision==0.5.0
$PYTHON -m pip install git+https://github.com/mapillary/[email protected]
$PYTHON -m pip install gdown
$PYTHON -m pip install --upgrade pip
$PYTHON -m pip install --upgrade Pillow
### Pillow-simd with libjpeg turbo
$PYTHON -m pip uninstall -y pillow
apt-get update
apt-get install -y libjpeg-dev zlib1g-dev libpng-dev libwebp-dev
CFLAGS="${CFLAGS} -mavx2" $PYTHON -m pip install --upgrade --no-cache-dir --force-reinstall --no-binary :all:--compile https://github.com/mrT23/pillow-simd/zipball/simd/7.0.x
$PYTHON -c "from PIL import Image; print(Image.PILLOW_VERSION)"
#python -m pip uninstall -y pillow
#python -m pip install -U --force-reinstall pip
#conda install -c conda-forge libjpeg-turbo pillow==7.0.0
#apt-get -qq update
#apt-get install -y libwebp-dev
#CFLAGS="${CFLAGS} -mavx2" pip install --upgrade --no-cache-dir --force-reinstall \
#--no-binary :all:--compile https://github.com/mrT23/pillow-simd/zipball/simd/7.0.x
#conda install -y jpeg libtiff
#python -c "from PIL import Image; print(Image.PILLOW_VERSION)"
gdown https://drive.google.com/uc?id=1pySDEdfvLRROaNXi-fWrd_aV9N6W9Yjo
gdown https://drive.google.com/uc?id=12_VnXYI-4JaUYOOIsZXYCJdpiLCJ4dHV
gdown https://drive.google.com/uc?id=14X7xL1uf3c9dVGzRdV49bTjCBNvT9koA
gdown https://drive.google.com/uc?id=1HKFZEWPIwk5ZR0_MjJNkpQLyM_0yX0Qq
apt-get install wget
wget https://onedrive.hyper.ai/down/ImageNet/data/ImageNet2012/ILSVRC2012_devkit_t12.tar.gz -P ./.data/vision/imagenet
wget https://onedrive.hyper.ai/down/ImageNet/data/ImageNet2012/ILSVRC2012_img_val.tar -P ./.data/vision/imagenet
# gdown https://drive.google.com/file/d/1pySDEdfvLRROaNXi-fWrd_aV9N6W9Yjo/view?usp=sharing
#gdown https://drive.google.com/uc?id=1cTOwVmxLqWhNl8zg2ZZJfiyejEcOq1RR
#gdown https://drive.google.com/uc?id=1jgKXMoJpZ6Sow_sJhgi5tec7AyeQCLbH
#gdown https://drive.google.com/uc?id=1IIPU77tcS83cBRTAfKeGvAmcBL5D196r