update resmaple_file docstring
This commit is contained in:
@@ -19,12 +19,13 @@ def resample(file: str, sr: int = 16000):
|
|||||||
# https://github.com/openai/whisper/blob/7858aa9c08d98f75575035ecd6481f462d66ca27/whisper/audio.py#L22
|
# https://github.com/openai/whisper/blob/7858aa9c08d98f75575035ecd6481f462d66ca27/whisper/audio.py#L22
|
||||||
Open an audio file and read as mono waveform, resampling as necessary,
|
Open an audio file and read as mono waveform, resampling as necessary,
|
||||||
save the resampled audio
|
save the resampled audio
|
||||||
Parameters
|
|
||||||
----------
|
Args:
|
||||||
file: str
|
file (str): The audio file to open
|
||||||
The audio file to open
|
sr (int): The sample rate to resample the audio if necessary
|
||||||
sr: int
|
|
||||||
The sample rate to resample the audio if necessary
|
Returns:
|
||||||
|
resampled_file (str): The resampled audio file
|
||||||
"""
|
"""
|
||||||
try:
|
try:
|
||||||
# This launches a subprocess to decode audio while down-mixing and resampling as necessary.
|
# This launches a subprocess to decode audio while down-mixing and resampling as necessary.
|
||||||
|
|||||||
Reference in New Issue
Block a user