Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -45,9 +45,6 @@ song_index_to_recommend = st.number_input('Enter song index:', min_value=0, max_
|
|
45 |
# Combine emotion and audio features for recommendation
|
46 |
#combined_features = np.concatenate([emotion, audio_features_scaled_knn[song_index_to_recommend]])
|
47 |
|
48 |
-
|
49 |
-
|
50 |
-
|
51 |
-
st.write(f"Song Index: {index}, Title: {row['title']}, Artist: {row['artist']}, Score: {row['score']}")
|
52 |
-
else:
|
53 |
-
st.write("No KNN Recommendations found.")
|
|
|
45 |
# Combine emotion and audio features for recommendation
|
46 |
#combined_features = np.concatenate([emotion, audio_features_scaled_knn[song_index_to_recommend]])
|
47 |
|
48 |
+
st.write("KNN Recommendations:")
|
49 |
+
for index in knn_recs.index:
|
50 |
+
st.write(f"Song Index: {index}, Title: {df.iloc[index]['title']}, Artist: {df.iloc[index]['artist']}, Score: {knn_recs.loc[index, 'score']}")
|
|
|
|
|
|