Skip to content

Commit

Permalink
page data merge
Browse files Browse the repository at this point in the history
Signed-off-by: Melvin Strobl <[email protected]>
  • Loading branch information
Melvin Strobl committed Nov 18, 2024
1 parent 6799cf3 commit 0a43b40
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions app/pages/1-training.py
Original file line number Diff line number Diff line change
Expand Up @@ -134,6 +134,7 @@ def on_preference_changed(
- Button text indicating the next state.
"""
page_data = {
**page_data,
"noise_params": {
"BitFlip": bf,
"PhaseFlip": pf,
Expand All @@ -146,7 +147,7 @@ def on_preference_changed(
"stepsize": (
stepsize if stepsize is not None and stepsize > 0 else DEFAULT_STEPSIZE
),
} | page_data
}

page_log_training = reset_log()

Expand Down Expand Up @@ -401,14 +402,14 @@ def update_ent_cap(

if len(page_log_training["ctrl_params"]) > 0:
fig_ent_cap.add_scatter(
name="Control Parameters", y=page_log_training["ctrl_params"]
name="Control Param. Mean", y=page_log_training["ctrl_params"]
)

fig_ent_cap.update_layout(
title="Entangling Capability",
template="simple_white",
xaxis_title="Step",
yaxis_title="Entangling Capability",
# yaxis_title="Entangling Capability",
xaxis_range=[
0,
page_data["steps"] if page_data is not None else DEFAULT_N_STEPS,
Expand Down

0 comments on commit 0a43b40

Please sign in to comment.