-
Notifications
You must be signed in to change notification settings - Fork 3
/
DAIN_retrieve_timing_autopixel4.sh
34 lines (33 loc) · 1.6 KB
/
DAIN_retrieve_timing_autopixel4.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
THISFILE=`basename "$0"`
PYSCRIPTPATH="${0%\\*}\\" #If the .sh script is somewhere else, put the absolute path instead
PARAM_FOLDER=$(dirname -- "$1")
#PARAM_FOLDER="${1%\\*}" #The python script will be local to the image (for creating new ones)
cd "$PARAM_FOLDER"
python -V
(
for FILE in "$@"
do
FULLNAME=$(basename -- "$FILE")
NAME="${FULLNAME%.*}"
EXTENSION="${FULLNAME##*.}"
PARENTFOLDER=$(dirname -- "$FILE")
echo python "$PYSCRIPTPATH"transfer_palette_and_time.py "$FILE" "$PARENTFOLDER""/""$NAME""/interpolated_frames"
python "$PYSCRIPTPATH"transfer_palette_and_time.py "$FILE" "$PARENTFOLDER""/""$NAME""/interpolated_frames"
mv "$NAME"_EXT_interpolated_frames.gif "$NAME"_interp.gif
#bash "$PYSCRIPTPATH"_unoptimize_gif.sh "$NAME"_interp.gif
#bash "$PYSCRIPTPATH""bg empty.sh" "$NAME"_interp.gif
#mv "$NAME""_interp#_empty.gif" "$NAME"_interp.gif
###bash "$PYSCRIPTPATH"_unoptimize_gif.sh "$NAME"_interp.gif
bash "$PYSCRIPTPATH""redux nearest 4.sh" "$NAME"_interp.gif
###bash "$PYSCRIPTPATH"_unoptimize_gif.sh "$NAME"_interp_N4.gif
bash "$PYSCRIPTPATH""resample X4.sh" "$NAME"_interp_N4.gif
bash "$PYSCRIPTPATH"_unoptimize_gif.sh "$NAME"_interp_N4_X4.gif
(
mkdir output_N4
)
mv "$NAME"_interp.gif output_N4/"$NAME""(interp).gif"
mv "$NAME"_interp_N4.gif output_N4/"$NAME""_interp_N4.gif"
mv "$NAME"_interp_N4_X4.gif output_N4/"$NAME""_interp_N4_X4.gif"
done
)
exec $SHELL