Commit
•
b97a3c2
1
Parent(s):
5026b2d
Update app.py
Browse files
app.py
CHANGED
@@ -90,8 +90,8 @@ def yt_transcribe(yt_url, task, max_filesize=75.0):
|
|
90 |
with open(filepath, "rb") as f:
|
91 |
inputs = f.read()
|
92 |
|
93 |
-
inputs = ffmpeg_read(inputs,
|
94 |
-
inputs = {"array": inputs, "sampling_rate":
|
95 |
|
96 |
text = pipe(inputs, batch_size=BATCH_SIZE, generate_kwargs={"task": task})["text"]
|
97 |
|
|
|
90 |
with open(filepath, "rb") as f:
|
91 |
inputs = f.read()
|
92 |
|
93 |
+
inputs = ffmpeg_read(inputs, pipe.feature_extractor.sampling_rate)
|
94 |
+
inputs = {"array": inputs, "sampling_rate": pipe.feature_extractor.sampling_rate}
|
95 |
|
96 |
text = pipe(inputs, batch_size=BATCH_SIZE, generate_kwargs={"task": task})["text"]
|
97 |
|