From 0b07963c81155b621dd45b878b869a78b8c9de49 Mon Sep 17 00:00:00 2001 From: Sacha Chua Date: Sat, 5 Nov 2022 07:55:05 -0400 Subject: Caption updates --- roles/caption/templates/run-aeneas.sh | 14 ++++++++++++++ 1 file changed, 14 insertions(+) create mode 100755 roles/caption/templates/run-aeneas.sh (limited to 'roles/caption/templates/run-aeneas.sh') diff --git a/roles/caption/templates/run-aeneas.sh b/roles/caption/templates/run-aeneas.sh new file mode 100755 index 0000000..6f40134 --- /dev/null +++ b/roles/caption/templates/run-aeneas.sh @@ -0,0 +1,14 @@ +#!/usr/bin/bash +# +# {{ ansible_managed }} +# +AUDIO=$(ls *.opus *.ogg | head -n1) +BASE=$(echo $AUDIO | perl -pe 's/^(emacsconf-2022-.*?--.*?--.*?)--.*/$1/') +echo $AUDIO +echo $BASE +if [ ! -f $BASE--whisper.vtt ]; then + cp ${BASE}--main.vtt ${BASE}--whisper.vtt +fi +python3 -m aeneas.tools.execute_task $AUDIO *.txt "task_language=eng|os_task_file_format=vtt|is_text_type=plain" ${BASE}--aeneas.vtt +cp ${BASE}--aeneas.vtt ${BASE}--main.vtt +/data/emacsconf/2022/scripts/upload.sh ${BASE}--main.vtt -- cgit v1.2.3