Spaces:
Sleeping
Sleeping
remove logger
Browse files
recommendation-api/tracks.py
CHANGED
@@ -1,17 +1,9 @@
|
|
1 |
import pandas as pd
|
2 |
-
import logging
|
3 |
-
|
4 |
-
logger = logging.getLogger(__name__)
|
5 |
|
6 |
# Read the CSV files
|
7 |
-
logger.info("Reading tracks data from csv ...")
|
8 |
tracks_df = pd.read_csv('data/music_info.csv')
|
9 |
-
|
10 |
-
# Remove NaN's from data and construct concatenated format (as with trained model)
|
11 |
tracks_df.fillna('', inplace=True)
|
12 |
tracks_df["entry"] = tracks_df["name"] + ", " + tracks_df["artist"] + ", " + tracks_df["year"].astype(str)
|
13 |
-
|
14 |
-
logger.info("Reading user listening history from csv ...")
|
15 |
track_interactions_df = pd.read_csv('data/user_listening_history_10k.csv')
|
16 |
|
17 |
# Merge data on those two csvs
|
|
|
1 |
import pandas as pd
|
|
|
|
|
|
|
2 |
|
3 |
# Read the CSV files
|
|
|
4 |
tracks_df = pd.read_csv('data/music_info.csv')
|
|
|
|
|
5 |
tracks_df.fillna('', inplace=True)
|
6 |
tracks_df["entry"] = tracks_df["name"] + ", " + tracks_df["artist"] + ", " + tracks_df["year"].astype(str)
|
|
|
|
|
7 |
track_interactions_df = pd.read_csv('data/user_listening_history_10k.csv')
|
8 |
|
9 |
# Merge data on those two csvs
|