Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
|
@@ -116,7 +116,7 @@ def spectrogram_image_from_file(filename, max_volume: float = 50, power_for_imag
|
|
| 116 |
Generate a spectrogram image from an MP3 file.
|
| 117 |
"""
|
| 118 |
|
| 119 |
-
max_volume = int(
|
| 120 |
power_for_image = float(args.powerforimage)
|
| 121 |
|
| 122 |
# Load MP3 file into AudioSegment object
|
|
@@ -144,7 +144,7 @@ def spectrogram_image_from_file(filename, max_volume: float = 50, power_for_imag
|
|
| 144 |
|
| 145 |
def convert(audio):
|
| 146 |
|
| 147 |
-
image = spectrogram_image_from_file(audio)
|
| 148 |
|
| 149 |
return image
|
| 150 |
|
|
|
|
| 116 |
Generate a spectrogram image from an MP3 file.
|
| 117 |
"""
|
| 118 |
|
| 119 |
+
max_volume = int(max_volume)
|
| 120 |
power_for_image = float(args.powerforimage)
|
| 121 |
|
| 122 |
# Load MP3 file into AudioSegment object
|
|
|
|
| 144 |
|
| 145 |
def convert(audio):
|
| 146 |
|
| 147 |
+
image = spectrogram_image_from_file(audio, 255)
|
| 148 |
|
| 149 |
return image
|
| 150 |
|