Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Hiding the ffmpeg popup that appears momentarily #2097

Open
wants to merge 3 commits into
base: main
Choose a base branch
from
Open
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions whisper/audio.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import os
from functools import lru_cache
from subprocess import CalledProcessError, run
from subprocess import CalledProcessError, run, CREATE_NO_WINDOW
from typing import Optional, Union

import numpy as np
Expand Down Expand Up @@ -55,7 +55,7 @@ def load_audio(file: str, sr: int = SAMPLE_RATE):
]
# fmt: on
try:
out = run(cmd, capture_output=True, check=True).stdout
out = run(cmd, capture_output=True, check=True, creationflags=CREATE_NO_WINDOW).stdout
except CalledProcessError as e:
raise RuntimeError(f"Failed to load audio: {e.stderr.decode()}") from e

Expand Down