Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
@@ -22,15 +22,7 @@ def split_multi_users(dfs):
|
|
22 |
return df
|
23 |
|
24 |
def plot_now():
|
25 |
-
# dfs = pd.read_csv("hf://spaces/pluslab/PLUS_Lab_GPUs/gpus.csv")
|
26 |
-
### delete cache
|
27 |
-
try:
|
28 |
-
os.rmdir("~/.cache/huggingface/")
|
29 |
-
print("Deleted Cache")
|
30 |
-
except Exception as e:
|
31 |
-
print(e)
|
32 |
### Load Data
|
33 |
-
# dfs = pd.read_csv("hf://datasets/pluslab/PLUS_Lab_GPUs_Data/gpus.csv")
|
34 |
dfs = datasets.load_dataset("pluslab/PLUS_Lab_GPUs_Data", download_mode='force_redownload')["train"].to_pandas()
|
35 |
dfs = dfs.drop(columns=["Unnamed: 0"])
|
36 |
dfs = dfs.fillna("FREE")
|
@@ -48,7 +40,7 @@ def plot_now():
|
|
48 |
barcornerradius=50,
|
49 |
)
|
50 |
fig.update_traces(textposition='inside', insidetextanchor='middle')
|
51 |
-
print(dfs_plot)
|
52 |
return fig, dfs
|
53 |
|
54 |
def plot_history(sample=True, sampling_interval_minutes=180):
|
|
|
22 |
return df
|
23 |
|
24 |
def plot_now():
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
25 |
### Load Data
|
|
|
26 |
dfs = datasets.load_dataset("pluslab/PLUS_Lab_GPUs_Data", download_mode='force_redownload')["train"].to_pandas()
|
27 |
dfs = dfs.drop(columns=["Unnamed: 0"])
|
28 |
dfs = dfs.fillna("FREE")
|
|
|
40 |
barcornerradius=50,
|
41 |
)
|
42 |
fig.update_traces(textposition='inside', insidetextanchor='middle')
|
43 |
+
# print(dfs_plot)
|
44 |
return fig, dfs
|
45 |
|
46 |
def plot_history(sample=True, sampling_interval_minutes=180):
|