From 2308a9337ccba81273fe5a38ab28953d87748ce4 Mon Sep 17 00:00:00 2001 From: Jaikinator Date: Tue, 27 Jun 2023 10:20:42 +0200 Subject: [PATCH] changed type of sr --- autotranscript/audio.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/autotranscript/audio.py b/autotranscript/audio.py index 4e7ee60..7944a73 100644 --- a/autotranscript/audio.py +++ b/autotranscript/audio.py @@ -1,7 +1,7 @@ import numpy as np import torch from subprocess import CalledProcessError, run - +from typing import Union SAMPLE_RATE = 16000 class AudioProcessor: @@ -9,7 +9,7 @@ class AudioProcessor: Audio Processor using PyTorchaudio instead of PyDub """ - def __init__(self, waveform: torch.Tensor, sr : torch.Tensor, + def __init__(self, waveform: torch.Tensor, sr : int = SAMPLE_RATE, *args, **kwargs) -> None: """ Initialise audio processor