badrex commited on
Commit
5b7288e
·
verified ·
1 Parent(s): c59b5a8

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -18,8 +18,8 @@ def transcribe(audio):
18
  # convert to mono if stereo
19
  if y.ndim > 1:
20
  y = y.mean(axis=1)
21
- #y = y.astype(np.float32)
22
- #y /= np.max(np.abs(y))
23
  return transcriber({"sampling_rate": sr, "raw": y})["text"]
24
 
25
 
 
18
  # convert to mono if stereo
19
  if y.ndim > 1:
20
  y = y.mean(axis=1)
21
+ y = y.astype(np.float32)
22
+ y /= np.max(np.abs(y))
23
  return transcriber({"sampling_rate": sr, "raw": y})["text"]
24
 
25