Spaces:
Sleeping
Sleeping
Update apps/sdg.py
Browse files- apps/sdg.py +2 -2
apps/sdg.py
CHANGED
@@ -12,7 +12,7 @@ def app():
|
|
12 |
model_name = 'sentence-transformers/all-MiniLM-L6-v2'
|
13 |
model = SentenceTransformer(model_name)
|
14 |
|
15 |
-
with st.spinner("π load
|
16 |
df_osdg = pd.read_csv('https://zenodo.org/record/5550238/files/osdg-community-dataset-v21-09-30.csv',sep='\t')
|
17 |
df_osdg = df_osdg[df_osdg['agreement']>.95]
|
18 |
df_osdg = df_osdg[df_osdg['labels_positive']>4]
|
@@ -42,7 +42,7 @@ def app():
|
|
42 |
docs = list(df_osdg['text'])
|
43 |
docs_embeddings = model.encode(docs)
|
44 |
|
45 |
-
with st.spinner("π
|
46 |
n_neighbors = 15
|
47 |
n_components = 3
|
48 |
random_state =42
|
|
|
12 |
model_name = 'sentence-transformers/all-MiniLM-L6-v2'
|
13 |
model = SentenceTransformer(model_name)
|
14 |
|
15 |
+
with st.spinner("π load and embed SDG texts"):
|
16 |
df_osdg = pd.read_csv('https://zenodo.org/record/5550238/files/osdg-community-dataset-v21-09-30.csv',sep='\t')
|
17 |
df_osdg = df_osdg[df_osdg['agreement']>.95]
|
18 |
df_osdg = df_osdg[df_osdg['labels_positive']>4]
|
|
|
42 |
docs = list(df_osdg['text'])
|
43 |
docs_embeddings = model.encode(docs)
|
44 |
|
45 |
+
with st.spinner("π map to 3D for visualisation"):
|
46 |
n_neighbors = 15
|
47 |
n_components = 3
|
48 |
random_state =42
|