Update app.py
Browse files
app.py
CHANGED
@@ -29,9 +29,10 @@ if uploaded_audio is not None:
|
|
29 |
channels=1
|
30 |
)
|
31 |
|
32 |
-
# Slow down the audio
|
33 |
st.write("Slowing down audio...")
|
34 |
-
|
|
|
35 |
|
36 |
# Export the slowed audio to a file
|
37 |
slowed_audio.export("output_audio.wav", format="wav")
|
|
|
29 |
channels=1
|
30 |
)
|
31 |
|
32 |
+
# Slow down the audio by changing the frame rate
|
33 |
st.write("Slowing down audio...")
|
34 |
+
slowed_sample_rate = int(sample_rate * 0.7)
|
35 |
+
slowed_audio = reduced_audio.set_frame_rate(slowed_sample_rate)
|
36 |
|
37 |
# Export the slowed audio to a file
|
38 |
slowed_audio.export("output_audio.wav", format="wav")
|