forked from espnet/espnet
-
Notifications
You must be signed in to change notification settings - Fork 0
/
install_visual.sh
115 lines (103 loc) · 2.91 KB
/
install_visual.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
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
#!/usr/bin/env bash
set -euo pipefail
if [ $# != 0 ]; then
echo "Usage: $0"
exit 1;
fi
if [ ! -e visual.done ]; then
(
# Install gdown
if ! python3 -c "import gdown" &> /dev/null; then
(
set -euo pipefail
python3 -m pip install gdown
)
else
echo "gdown is already installed."
fi
# Install skvideo
if ! python3 -c "import skvideo" &> /dev/null; then
(
set -euo pipefail
python3 -m pip install sk-video
)
else
echo "skvideo is already installed."
fi
# Install skimage
if ! python3 -c "import skimage" &> /dev/null; then
(
set -euo pipefail
python3 -m pip install scikit-image
)
else
echo "skimage is already installed."
fi
# Install cv2
if ! python3 -c "import cv2" &> /dev/null; then
(
set -euo pipefail
python3 -m pip install opencv-python
)
else
echo "cv2 is already installed."
fi
# Install python_speech_features
if ! python3 -c "import python_speech_features" &> /dev/null; then
(
set -euo pipefail
python3 -m pip install python_speech_features
)
else
echo "python_speech_features is already installed."
fi
# Install torchlm
if ! python3 -c "import torchlm" &> /dev/null; then
(
set -euo pipefail
python3 -m pip install torchlm --no-deps
)
else
echo "torchlm is already installed."
fi
# Install onnx
if ! python3 -c "import onnx" &> /dev/null; then
(
set -euo pipefail
python3 -m pip install onnx
)
else
echo "onnx is already installed."
fi
# Install onnxruntime
if ! python3 -c "import torchlm" &> /dev/null; then
(
set -euo pipefail
python3 -m pip install onnxruntime
)
else
echo "onnxruntime is already installed."
fi
# Install av
if ! python3 -c "import av" &> /dev/null; then
(
set -euo pipefail
python3 -m pip install av
)
else
echo "av is already installed."
fi
# Install torchvision
if ! python3 -c "import torchvision" &> /dev/null; then
(
set -euo pipefail
python3 -m pip install torchvision --no-deps
)
else
echo "torchvision is already installed."
fi
)
touch visual.done
else
echo "visual components are already installed."
fi