Update app.py
Browse files
app.py
CHANGED
|
@@ -51,7 +51,7 @@ def transcribe(audio, history_type):
|
|
| 51 |
if isinstance(audio_data[0], np.ndarray) and len(audio_data[0]) == 2:
|
| 52 |
# Convert stereo audio data to mono by averaging the two channels
|
| 53 |
audio_data = np.mean(audio_data, axis=1).astype(np.int16)
|
| 54 |
-
|
| 55 |
# If the audio data is already mono, no conversion is needed
|
| 56 |
|
| 57 |
|
|
|
|
| 51 |
if isinstance(audio_data[0], np.ndarray) and len(audio_data[0]) == 2:
|
| 52 |
# Convert stereo audio data to mono by averaging the two channels
|
| 53 |
audio_data = np.mean(audio_data, axis=1).astype(np.int16)
|
| 54 |
+
|
| 55 |
# If the audio data is already mono, no conversion is needed
|
| 56 |
|
| 57 |
|