Created
February 28, 2023 16:28
-
-
Save mknz/8fb841b6827f48f8163cf2baed21167e to your computer and use it in GitHub Desktop.
Revisions
-
mknz revised this gist
Feb 28, 2023 . No changes.There are no files selected for viewing
-
mknz created this gist
Feb 28, 2023 .There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,8 @@ #!/bin/bash WORKDIR=/tmp/whisper rm -rf $WORKDIR mkdir $WORKDIR URL=\'$1\' SAVEFILE=\'$WORKDIR/tmp.3gpp\' python -c "from pytube import YouTube; YouTube($URL).streams.first().download(filename=$SAVEFILE)" ffmpeg -i $WORKDIR/tmp.3gpp -ar 16000 -ac 1 -c:a pcm_s16le $WORKDIR/tmp.wav &> /dev/null