Spaces:
Build error
Build error
Update app.py
Browse files
app.py
CHANGED
@@ -59,14 +59,26 @@ def predict(text_input):
|
|
59 |
)
|
60 |
arxivml_label_layers.append(np.load(io.BytesIO(label_file.content), allow_pickle=True))
|
61 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
62 |
plot = datamapplot.create_interactive_plot(
|
63 |
arxivml_data_map,
|
64 |
-
arxivml_label_layers[
|
65 |
-
|
66 |
-
|
67 |
-
|
|
|
|
|
68 |
|
69 |
|
|
|
|
|
70 |
|
71 |
|
72 |
|
|
|
59 |
)
|
60 |
arxivml_label_layers.append(np.load(io.BytesIO(label_file.content), allow_pickle=True))
|
61 |
|
62 |
+
|
63 |
+
|
64 |
+
hover_data_file = requests.get(
|
65 |
+
f"{base_url}/raw/interactive/examples/arxiv_ml_hover_data.npy"
|
66 |
+
)
|
67 |
+
arxiv_hover_data = np.load(io.BytesIO(hover_data_file.content), allow_pickle=True)
|
68 |
+
|
69 |
+
|
70 |
plot = datamapplot.create_interactive_plot(
|
71 |
arxivml_data_map,
|
72 |
+
arxivml_label_layers[0],
|
73 |
+
arxivml_label_layers[2],
|
74 |
+
arxivml_label_layers[4],
|
75 |
+
hover_text = arxiv_hover_data,
|
76 |
+
font_family="Roboto Condensed",
|
77 |
+
)
|
78 |
|
79 |
|
80 |
+
|
81 |
+
plot.save(file_path)
|
82 |
|
83 |
|
84 |
|