Skip to content

Commit

Permalink
Bug fix
Browse files Browse the repository at this point in the history
  • Loading branch information
picaultj committed Dec 19, 2024
1 parent 10cf9a5 commit 96d393d
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions bertrend/trend_analysis/visualizations.py
Original file line number Diff line number Diff line change
Expand Up @@ -146,7 +146,7 @@ def plot_topics_per_timestamp(topic_models: Dict[pd.Timestamp, BERTopic]) -> Non
def create_topic_size_evolution_figure(topic_ids=None):
fig = go.Figure()

topic_sizes = st.session_state.topic_sizes
topic_sizes = st.session_state["bertrend"].topic_sizes

if topic_ids is None:
# If topic_ids is not provided, include all topics
Expand Down Expand Up @@ -201,9 +201,9 @@ def plot_topic_size_evolution(
Tuple[float, float]: The q1 and q3 values representing the 10th and 90th percentiles of popularity values.
"""

topic_sizes = st.session_state.topic_sizes
topic_last_popularity = st.session_state.topic_last_popularity
topic_last_update = st.session_state.topic_last_update
topic_sizes = st.session_state["bertrend"].topic_sizes
topic_last_popularity = st.session_state["bertrend"].topic_last_popularity
topic_last_update = st.session_state["bertrend"].topic_last_update

window_size_timedelta = pd.Timedelta(days=window_size)
granularity_timedelta = pd.Timedelta(days=granularity)
Expand Down

0 comments on commit 96d393d

Please sign in to comment.