Fix Whisper.cpp on Windows (#422)

This commit is contained in:
Chidi Williams 2023-04-29 19:30:40 +00:00 committed by GitHub
parent cb5ad74620
commit 66bd9a1834
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 12 additions and 3 deletions

View file

@ -7,4 +7,4 @@ omit =
directory = coverage/html
[report]
fail_under = 68
fail_under = 76

View file

@ -72,6 +72,12 @@ jobs:
sudo apt install -y libpulse-mainloop-glib0 libegl1-mesa-dev libgstreamer-plugins-base1.0-dev libgstreamer1.0-dev libportaudio2
fi
if [ "$RUNNER_OS" == "Windows" ]; then
curl -OL "https://github.com/ggerganov/whisper.cpp/releases/download/v1.3.0/whisper-bin-x64.zip"
unzip whisper-bin-x64.zip
mv main.exe whisper_cpp.exe
fi
poetry run make test
shell: bash
@ -146,7 +152,11 @@ jobs:
poetry run make bundle_mac
elif [ "$RUNNER_OS" == "Windows" ]; then
curl -OL "https://github.com/ggerganov/whisper.cpp/releases/download/v1.3.0/whisper-bin-x64.zip"
unzip whisper-bin-x64.zip
mv main.exe whisper_cpp.exe
poetry run make bundle_windows
elif [ "$RUNNER_OS" == "Linux" ]; then

View file

@ -52,7 +52,6 @@ class TestRecordingTranscriber:
assert 'Bienvenue dans Passe' in text
@pytest.mark.skipif(platform.system() == 'Windows', reason='whisper_cpp not printing segments on Windows')
class TestWhisperCppFileTranscriber:
@pytest.mark.parametrize(
'word_level_timings,expected_segments',