Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -12,6 +12,11 @@ import accelerate
|
|
12 |
# steamlit setup
|
13 |
st.set_page_config(page_title="Sentiment Analysis on Your Cantonese Song",)
|
14 |
st.header("Cantonese Song Sentiment Analyzer")
|
|
|
|
|
|
|
|
|
|
|
15 |
button_click = st.button("Run Analysis", type="primary")
|
16 |
|
17 |
# load song
|
@@ -73,11 +78,6 @@ def senti_model(transcription):
|
|
73 |
# main
|
74 |
def main():
|
75 |
|
76 |
-
input_file = st.file_uploader("upload a song in mp3 format", type="mp3") # upload song
|
77 |
-
if input_file is not None:
|
78 |
-
st.write("File uploaded successfully!")
|
79 |
-
else:
|
80 |
-
st.write("No file uploaded.")
|
81 |
audio_preprocess()
|
82 |
transcription = asr_model()
|
83 |
final_result = senti_model(transcription)
|
|
|
12 |
# steamlit setup
|
13 |
st.set_page_config(page_title="Sentiment Analysis on Your Cantonese Song",)
|
14 |
st.header("Cantonese Song Sentiment Analyzer")
|
15 |
+
input_file = st.file_uploader("upload a song in mp3 format", type="mp3") # upload song
|
16 |
+
if input_file is not None:
|
17 |
+
st.write("File uploaded successfully!")
|
18 |
+
else:
|
19 |
+
st.write("No file uploaded.")
|
20 |
button_click = st.button("Run Analysis", type="primary")
|
21 |
|
22 |
# load song
|
|
|
78 |
# main
|
79 |
def main():
|
80 |
|
|
|
|
|
|
|
|
|
|
|
81 |
audio_preprocess()
|
82 |
transcription = asr_model()
|
83 |
final_result = senti_model(transcription)
|