Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
|
@@ -10,6 +10,7 @@ def process_csv(df):
|
|
| 10 |
# Apply a filter to eliminate rows with the 'Veta' column that have less than or equal to 3 words
|
| 11 |
df = df[df['Veta'].str.split().str.len() > 3]
|
| 12 |
# Delete all rows where 'Intent' contains 'Cognitive' or 'SmallTalk'
|
|
|
|
| 13 |
df = df[~df['Intent'].str.contains('Cognitive|SmallTalk')]
|
| 14 |
# Using the pandas dataframe sample function to get 200 random rows
|
| 15 |
df = df.sample(200, random_state=42, replace=True)
|
|
|
|
| 10 |
# Apply a filter to eliminate rows with the 'Veta' column that have less than or equal to 3 words
|
| 11 |
df = df[df['Veta'].str.split().str.len() > 3]
|
| 12 |
# Delete all rows where 'Intent' contains 'Cognitive' or 'SmallTalk'
|
| 13 |
+
df = df.dropna(subset=['Intent'])
|
| 14 |
df = df[~df['Intent'].str.contains('Cognitive|SmallTalk')]
|
| 15 |
# Using the pandas dataframe sample function to get 200 random rows
|
| 16 |
df = df.sample(200, random_state=42, replace=True)
|