Skip to content

Commit

Permalink
fix crash in html_visualizer when elapsed_time is None
Browse files Browse the repository at this point in the history
  • Loading branch information
jhj0411jhj committed Mar 8, 2023
1 parent 7474330 commit 5ff20ab
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions openbox/visualization/html_visualizer.py
Original file line number Diff line number Diff line change
Expand Up @@ -169,9 +169,8 @@ def generate_basic_data(self):
else:
config_str = config_str[1:-1]

table_list.append(
[idx + 1, objectives, constraints, config_dic, config_str, obs.trial_state,
round(obs.elapsed_time, 3)])
elapsed_time = round(obs.elapsed_time, 3) if obs.elapsed_time is not None else None
table_list.append([idx + 1, objectives, constraints, config_dic, config_str, obs.trial_state, elapsed_time])

config_values = list(config_dic.values())

Expand Down

0 comments on commit 5ff20ab

Please sign in to comment.