-
Notifications
You must be signed in to change notification settings - Fork 26
/
preprocess.sh
43 lines (39 loc) · 1.67 KB
/
preprocess.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
celeb=$1
mode=$2
if [ "$mode" = "train" ]
then
echo "--------------- Preprocessing mode: train ---------------"
echo
python preprocessing/detect.py --celeb $celeb --split
python preprocessing/eye_landmarks.py --celeb $celeb --mouth --align
python preprocessing/segment_face.py --celeb $celeb
python preprocessing/reconstruct.py --celeb $celeb \
--save_shapes \
--save_nmfcs
python preprocessing/align.py --celeb $celeb --faces_and_masks \
--shapes \
--nmfcs \
--landmarks
elif [ "$mode" = "test" ]
then
echo "--------------- Preprocessing mode: test ---------------"
echo
python preprocessing/detect.py --celeb $celeb --save_videos_info --save_full_frames
python preprocessing/eye_landmarks.py --celeb $celeb --align
python preprocessing/segment_face.py --celeb $celeb
python preprocessing/reconstruct.py --celeb $celeb \
--save_shapes \
--save_nmfcs
python preprocessing/align.py --celeb $celeb --faces_and_masks \
--shapes \
--nmfcs \
--landmarks
elif [ "$mode" = "reference" ]
then
echo "--------------- Preprocessing mode: reference ---------------"
echo
python preprocessing/detect.py --celeb $celeb --save_full_frames
python preprocessing/reconstruct.py --celeb $celeb
else
echo "Invalid mode given"
fi