Skip to content

Commit 57019e6

Browse files
committed
Fix broken model fetch link
As stated at issue #1602 currently model link has been broken. This commit addresses the problem by suggesting alternative model link that maintainer provided. So, in here, we used the supplementary package 'gdown' to download google drive files.
1 parent ab97f5b commit 57019e6

File tree

1 file changed

+26
-0
lines changed

1 file changed

+26
-0
lines changed

models/getModels.sh

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,29 @@
1+
# ------------------------- Downlaod MODELS -------------------------
2+
# (ISSUE #1602) Maintainer has provided alternative model link with google drive.
3+
# https://github.com/CMU-Perceptual-Computing-Lab/openpose/issues/1602#issuecomment-641653411
4+
MODEL_URL="https://drive.google.com/uc?id=1QCSxJZpnWvM00hx49CJ2zky7PWGzpcEh"
5+
FILENAME='models.zip'
6+
7+
# Supplementary package 'gdown' to download google drive
8+
if ! [ -x "$(command -v gdown)" ]; then
9+
echo "Please install gdown package with pip"
10+
exit
11+
fi
12+
13+
cd ..
14+
gdown ${MODEL_URL} -O ${FILENAME}
15+
unzip ${FILENAME}
16+
cd -
17+
18+
RESULT=$?
19+
if [ $RESULT -eq 0 ]; then
20+
echo "Model download success"
21+
exit
22+
else
23+
echo "Model download failure"
24+
echo "Fallback to original approach"
25+
fi
26+
127
# ------------------------- BODY, FOOT, FACE, AND HAND MODELS -------------------------
228
# Downloading body pose (COCO and MPI), face and hand models
329
OPENPOSE_URL="http://posefs1.perception.cs.cmu.edu/OpenPose/models/"

0 commit comments

Comments
 (0)