Spaces:
Sleeping
Sleeping
Editing filepaths
Browse files
app.py
CHANGED
@@ -2,23 +2,20 @@ import streamlit as st
|
|
2 |
import pandas as pd
|
3 |
import numpy as np
|
4 |
import altair as alt
|
|
|
5 |
from PIL import Image
|
6 |
from embeddings.embeddings import load_model
|
7 |
from sentence_transformers import util
|
8 |
-
# Create sample data
|
9 |
-
data = pd.DataFrame({
|
10 |
-
'Name': ['Alice', 'Bob', 'Charlie', 'David'],
|
11 |
-
'Age': [25, 30, 22, 35]
|
12 |
-
})
|
13 |
|
|
|
14 |
# Sample PNG file
|
15 |
-
image = Image.open('plots
|
16 |
|
17 |
# Sample HTML chart
|
18 |
-
chart_data = pd.read_csv(r"data
|
19 |
|
20 |
# Create a Streamlit app
|
21 |
-
st.set_page_config(page_title="
|
22 |
|
23 |
# Define tabs
|
24 |
tabs = ["Search", "Clustering Results"]
|
|
|
2 |
import pandas as pd
|
3 |
import numpy as np
|
4 |
import altair as alt
|
5 |
+
import os
|
6 |
from PIL import Image
|
7 |
from embeddings.embeddings import load_model
|
8 |
from sentence_transformers import util
|
|
|
|
|
|
|
|
|
|
|
9 |
|
10 |
+
print(os.listdir())
|
11 |
# Sample PNG file
|
12 |
+
image = Image.open('plots/clusters.png')
|
13 |
|
14 |
# Sample HTML chart
|
15 |
+
chart_data = pd.read_csv(r"data/top_cluster_dataset.csv",dtype={'Headline': str, 'x': np.float64, 'y': np.float64, 'labels': str})
|
16 |
|
17 |
# Create a Streamlit app
|
18 |
+
st.set_page_config(page_title="Sinhala Embedding Space", page_icon=":bar_chart:")
|
19 |
|
20 |
# Define tabs
|
21 |
tabs = ["Search", "Clustering Results"]
|