cleanup
parent
c418666a52
commit
6668614bbd
|
@ -1,10 +1,9 @@
|
|||
#!/bin/bash
|
||||
|
||||
# Where screenshots are saved
|
||||
SC_ROOT="model_data/screenshots"
|
||||
SC_ROOT="model_data/tau_small/screenshots"
|
||||
|
||||
# WILL BE DELETED
|
||||
mkdir out
|
||||
OUTPUT_DIR="out/video_output"
|
||||
|
||||
render_dir () {
|
||||
|
@ -18,7 +17,11 @@ render_dir () {
|
|||
$OUTPUT_DIR/${1##*/}.mp4
|
||||
}
|
||||
|
||||
mkdir $OUTPUT_DIR
|
||||
|
||||
|
||||
# Todo: error out if exists
|
||||
mkdir -p $OUTPUT_DIR
|
||||
|
||||
|
||||
echo "Making episode files..."
|
||||
for D in $SC_ROOT/*; do
|
||||
|
@ -32,25 +35,25 @@ echo "Done."
|
|||
|
||||
# Generate video for each run
|
||||
for f in $OUTPUT_DIR/*.mp4; do
|
||||
echo file \'$f\' >> $OUTPUT_DIR/merge_list;
|
||||
echo file \'$f\' >> video_merge_list
|
||||
done
|
||||
|
||||
# Merge videos
|
||||
ffmpeg \
|
||||
-loglevel quiet -stats -y \
|
||||
-loglevel error -stats -y \
|
||||
-f concat \
|
||||
-safe 0 \
|
||||
-i merge_list \
|
||||
-i video_merge_list \
|
||||
-c copy \
|
||||
$OUTPUT_DIR/00-all.mp4
|
||||
$OUTPUT_DIR/00-all.mp4
|
||||
|
||||
rm $OUTPUT_DIR/merge_list
|
||||
rm video_merge_list
|
||||
|
||||
# Make accelerated video
|
||||
ffmpeg \
|
||||
-loglevel quiet -stats -y \
|
||||
-i $OUTPUT_DIR/00-all.mp4 -y \
|
||||
-r 60 \
|
||||
-loglevel error -stats -y \
|
||||
-i $OUTPUT_DIR/00-all.mp4 \
|
||||
-framerate 60 \
|
||||
-filter:v "setpts=0.125*PTS" \
|
||||
8x.mp4
|
||||
|
||||
|
|
Reference in New Issue