Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
|
@@ -12,11 +12,24 @@ import pandas as pd
|
|
| 12 |
columns_to_click = ["Paper / Repo"]
|
| 13 |
|
| 14 |
def get_data():
|
|
|
|
| 15 |
df = pd.read_csv(
|
| 16 |
"https://docs.google.com/spreadsheets/d/e/2PACX-1vSC40sszorOjHfozmNqJT9lFiJhG94u3fbr3Ss_7fzcU3xqqJQuW1Ie_SNcWEB-uIsBi9NBUK7-ddet/pub?output=csv",
|
| 17 |
skiprows=1,
|
| 18 |
)
|
| 19 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 20 |
|
| 21 |
# %% app.ipynb 2
|
| 22 |
# Drop footers
|
|
|
|
| 12 |
columns_to_click = ["Paper / Repo"]
|
| 13 |
|
| 14 |
def get_data():
|
| 15 |
+
# Load the CSV file into a DataFrame
|
| 16 |
df = pd.read_csv(
|
| 17 |
"https://docs.google.com/spreadsheets/d/e/2PACX-1vSC40sszorOjHfozmNqJT9lFiJhG94u3fbr3Ss_7fzcU3xqqJQuW1Ie_SNcWEB-uIsBi9NBUK7-ddet/pub?output=csv",
|
| 18 |
skiprows=1,
|
| 19 |
)
|
| 20 |
|
| 21 |
+
# Drop rows where the 'Model' column is NaN
|
| 22 |
+
df.dropna(subset=['Model'], inplace=True)
|
| 23 |
+
|
| 24 |
+
# Drop rows where the 'Parameters \n(B)' column is 'TBA'
|
| 25 |
+
df = df[df["Parameters \n(B)"] != "TBA"]
|
| 26 |
+
|
| 27 |
+
# Apply make_clickable_cell to the specified columns
|
| 28 |
+
for col in columns_to_click:
|
| 29 |
+
df[col] = df[col].apply(make_clickable_cell)
|
| 30 |
+
|
| 31 |
+
return df
|
| 32 |
+
|
| 33 |
|
| 34 |
# %% app.ipynb 2
|
| 35 |
# Drop footers
|