How do i get rid of setting with copy warning upon assigining the value of cosine similarity of two dataframes to the column "sim" of dataframe spotify_df and is it something I should worry about.
P.S: user_track_df has only 1 row and spotify_df has around 6000 rows and both have equal number of columns.
Code snippet:
def generate_recommendations(spotify_df, user_track_df):
spotify_df['sim'] = cosine_similarity(spotify_df.drop(['name', 'artists', 'id'], axis=1),
user_track_df.drop(['name', 'artists', 'id'], axis=1))
spotify_df.sort_values(by='sim', ascending=False, inplace=True, kind="mergesort")
spotify_df.reset_index(drop=True, inplace=True)
return spotify_df.head(10)