NIIHAAD commited on
Commit
ba7d371
·
1 Parent(s): e4ccad5

update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -1
app.py CHANGED
@@ -164,7 +164,9 @@ def preprocess_sound(df):
164
  df[col] = 0
165
 
166
  # Tags
167
- df["tags_list"] = df["tags"].fillna("").str.lower().str.split(",")
 
 
168
  # One-Hot Encoding tags à la volée
169
  all_tags = [t.strip() for sub in df["tags_list"] for t in sub if t.strip() != ""]
170
  frequent_tags = set(all_tags) # simplifié, car threshold appliqué dans Colab déjà
 
164
  df[col] = 0
165
 
166
  # Tags
167
+ # Tags
168
+ df["tags_list"] = df["tags"].fillna("").astype(str).str.lower().str.split(",")
169
+
170
  # One-Hot Encoding tags à la volée
171
  all_tags = [t.strip() for sub in df["tags_list"] for t in sub if t.strip() != ""]
172
  frequent_tags = set(all_tags) # simplifié, car threshold appliqué dans Colab déjà