updated
Browse files- Pages/Topic Model Results.py +2 -10
Pages/Topic Model Results.py
CHANGED
@@ -12,11 +12,10 @@ bertopic_model = load_model()
|
|
12 |
|
13 |
def topic_model_results():
|
14 |
st.title("Topic Model Results")
|
15 |
-
tab1, tab2, tab3, tab4
|
16 |
[
|
17 |
"Topic Word Score",
|
18 |
"Intertopic Distance Map",
|
19 |
-
"Topic Probability Distribution",
|
20 |
"Visualize Hierarchical Topics",
|
21 |
"Visualize Topics Heatmap",
|
22 |
]
|
@@ -28,16 +27,9 @@ def topic_model_results():
|
|
28 |
with st.spinner("Loading the Visualization..."):
|
29 |
st.write(bertopic_model.visualize_topics())
|
30 |
with tab3:
|
31 |
-
with st.spinner("Loading the Visualization..."):
|
32 |
-
st.write(
|
33 |
-
bertopic_model.visualize_distribution(
|
34 |
-
bertopic_model.probabilities_[0], min_probability=0.015
|
35 |
-
)
|
36 |
-
)
|
37 |
-
with tab4:
|
38 |
with st.spinner("Loading the Visualization..."):
|
39 |
st.write(bertopic_model.visualize_hierarchy())
|
40 |
-
with
|
41 |
with st.spinner("Loading the Visualization..."):
|
42 |
st.write(bertopic_model.visualize_heatmap())
|
43 |
|
|
|
12 |
|
13 |
def topic_model_results():
|
14 |
st.title("Topic Model Results")
|
15 |
+
tab1, tab2, tab3, tab4 = st.tabs(
|
16 |
[
|
17 |
"Topic Word Score",
|
18 |
"Intertopic Distance Map",
|
|
|
19 |
"Visualize Hierarchical Topics",
|
20 |
"Visualize Topics Heatmap",
|
21 |
]
|
|
|
27 |
with st.spinner("Loading the Visualization..."):
|
28 |
st.write(bertopic_model.visualize_topics())
|
29 |
with tab3:
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
30 |
with st.spinner("Loading the Visualization..."):
|
31 |
st.write(bertopic_model.visualize_hierarchy())
|
32 |
+
with tab4:
|
33 |
with st.spinner("Loading the Visualization..."):
|
34 |
st.write(bertopic_model.visualize_heatmap())
|
35 |
|