mg-pso-gui 0.1.44__tar.gz → 0.1.46__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {mg-pso-gui-0.1.44 → mg-pso-gui-0.1.46}/PKG-INFO +1 -1
- {mg-pso-gui-0.1.44 → mg-pso-gui-0.1.46}/mg_pso_gui.egg-info/PKG-INFO +1 -1
- {mg-pso-gui-0.1.44 → mg-pso-gui-0.1.46}/mgpsogui/util/GraphGenerator.py +70 -1
- {mg-pso-gui-0.1.44 → mg-pso-gui-0.1.46}/setup.py +1 -1
- {mg-pso-gui-0.1.44 → mg-pso-gui-0.1.46}/mg_pso_gui.egg-info/SOURCES.txt +0 -0
- {mg-pso-gui-0.1.44 → mg-pso-gui-0.1.46}/mg_pso_gui.egg-info/dependency_links.txt +0 -0
- {mg-pso-gui-0.1.44 → mg-pso-gui-0.1.46}/mg_pso_gui.egg-info/entry_points.txt +0 -0
- {mg-pso-gui-0.1.44 → mg-pso-gui-0.1.46}/mg_pso_gui.egg-info/requires.txt +0 -0
- {mg-pso-gui-0.1.44 → mg-pso-gui-0.1.46}/mg_pso_gui.egg-info/top_level.txt +0 -0
- {mg-pso-gui-0.1.44 → mg-pso-gui-0.1.46}/mgpsogui/__init__.py +0 -0
- {mg-pso-gui-0.1.44 → mg-pso-gui-0.1.46}/mgpsogui/gui/HomePage.py +0 -0
- {mg-pso-gui-0.1.44 → mg-pso-gui-0.1.46}/mgpsogui/gui/OptionManager.py +0 -0
- {mg-pso-gui-0.1.44 → mg-pso-gui-0.1.46}/mgpsogui/gui/PlatformTab/PlatformTab.py +0 -0
- {mg-pso-gui-0.1.44 → mg-pso-gui-0.1.46}/mgpsogui/gui/PlatformTab/__init__.py +0 -0
- {mg-pso-gui-0.1.44 → mg-pso-gui-0.1.46}/mgpsogui/gui/RunTab/RunTab.py +0 -0
- {mg-pso-gui-0.1.44 → mg-pso-gui-0.1.46}/mgpsogui/gui/RunTab/__init__.py +0 -0
- {mg-pso-gui-0.1.44 → mg-pso-gui-0.1.46}/mgpsogui/gui/SetupTab/BoundsEditorWindow.py +0 -0
- {mg-pso-gui-0.1.44 → mg-pso-gui-0.1.46}/mgpsogui/gui/SetupTab/BoundsList.py +0 -0
- {mg-pso-gui-0.1.44 → mg-pso-gui-0.1.46}/mgpsogui/gui/SetupTab/CalibrationParametersView.py +0 -0
- {mg-pso-gui-0.1.44 → mg-pso-gui-0.1.46}/mgpsogui/gui/SetupTab/FunctionsList.py +0 -0
- {mg-pso-gui-0.1.44 → mg-pso-gui-0.1.46}/mgpsogui/gui/SetupTab/ListParametersView.py +0 -0
- {mg-pso-gui-0.1.44 → mg-pso-gui-0.1.46}/mgpsogui/gui/SetupTab/SetupTab.py +0 -0
- {mg-pso-gui-0.1.44 → mg-pso-gui-0.1.46}/mgpsogui/gui/SetupTab/StaticParameterView.py +0 -0
- {mg-pso-gui-0.1.44 → mg-pso-gui-0.1.46}/mgpsogui/gui/SetupTab/StepView.py +0 -0
- {mg-pso-gui-0.1.44 → mg-pso-gui-0.1.46}/mgpsogui/gui/SetupTab/__init__.py +0 -0
- {mg-pso-gui-0.1.44 → mg-pso-gui-0.1.46}/mgpsogui/gui/VisualizeTab/SideBar.py +0 -0
- {mg-pso-gui-0.1.44 → mg-pso-gui-0.1.46}/mgpsogui/gui/VisualizeTab/VisualizeTab.py +0 -0
- {mg-pso-gui-0.1.44 → mg-pso-gui-0.1.46}/mgpsogui/gui/VisualizeTab/__init__.py +0 -0
- {mg-pso-gui-0.1.44 → mg-pso-gui-0.1.46}/mgpsogui/gui/__init__.py +0 -0
- {mg-pso-gui-0.1.44 → mg-pso-gui-0.1.46}/mgpsogui/gui/images/IGOW 4 Logo.png +0 -0
- {mg-pso-gui-0.1.44 → mg-pso-gui-0.1.46}/mgpsogui/gui/images/collapse.png +0 -0
- {mg-pso-gui-0.1.44 → mg-pso-gui-0.1.46}/mgpsogui/gui/images/down.png +0 -0
- {mg-pso-gui-0.1.44 → mg-pso-gui-0.1.46}/mgpsogui/gui/images/expand.png +0 -0
- {mg-pso-gui-0.1.44 → mg-pso-gui-0.1.46}/mgpsogui/gui/images/play.png +0 -0
- {mg-pso-gui-0.1.44 → mg-pso-gui-0.1.46}/mgpsogui/gui/images/refresh.png +0 -0
- {mg-pso-gui-0.1.44 → mg-pso-gui-0.1.46}/mgpsogui/gui/images/refresh_hd.png +0 -0
- {mg-pso-gui-0.1.44 → mg-pso-gui-0.1.46}/mgpsogui/gui/images/stop.png +0 -0
- {mg-pso-gui-0.1.44 → mg-pso-gui-0.1.46}/mgpsogui/gui/images/test.png +0 -0
- {mg-pso-gui-0.1.44 → mg-pso-gui-0.1.46}/mgpsogui/gui/images/trash.png +0 -0
- {mg-pso-gui-0.1.44 → mg-pso-gui-0.1.46}/mgpsogui/gui/images/up.png +0 -0
- {mg-pso-gui-0.1.44 → mg-pso-gui-0.1.46}/mgpsogui/mgpsogui.py +0 -0
- {mg-pso-gui-0.1.44 → mg-pso-gui-0.1.46}/mgpsogui/start.yaml +0 -0
- {mg-pso-gui-0.1.44 → mg-pso-gui-0.1.46}/mgpsogui/util/CTkToolTip/__init__.py +0 -0
- {mg-pso-gui-0.1.44 → mg-pso-gui-0.1.46}/mgpsogui/util/CTkToolTip/ctk_tooltip.py +0 -0
- {mg-pso-gui-0.1.44 → mg-pso-gui-0.1.46}/mgpsogui/util/PSORunner.py +0 -0
- {mg-pso-gui-0.1.44 → mg-pso-gui-0.1.46}/mgpsogui/util/__init__.py +0 -0
- {mg-pso-gui-0.1.44 → mg-pso-gui-0.1.46}/mgpsogui/util/recosu/__init__.py +0 -0
- {mg-pso-gui-0.1.44 → mg-pso-gui-0.1.46}/mgpsogui/util/recosu/pso/__init__.py +0 -0
- {mg-pso-gui-0.1.44 → mg-pso-gui-0.1.46}/mgpsogui/util/recosu/pso/csip_access.py +0 -0
- {mg-pso-gui-0.1.44 → mg-pso-gui-0.1.46}/mgpsogui/util/recosu/pso/pso.py +0 -0
- {mg-pso-gui-0.1.44 → mg-pso-gui-0.1.46}/mgpsogui/util/recosu/utils/__init__.py +0 -0
- {mg-pso-gui-0.1.44 → mg-pso-gui-0.1.46}/mgpsogui/util/recosu/utils/plot/__init__.py +0 -0
- {mg-pso-gui-0.1.44 → mg-pso-gui-0.1.46}/mgpsogui/util/recosu/utils/plot/cost_steps.py +0 -0
- {mg-pso-gui-0.1.44 → mg-pso-gui-0.1.46}/mgpsogui/util/recosu/utils/trace_writer.py +0 -0
- {mg-pso-gui-0.1.44 → mg-pso-gui-0.1.46}/mgpsogui/util/recosu/utils/utils.py +0 -0
- {mg-pso-gui-0.1.44 → mg-pso-gui-0.1.46}/setup.cfg +0 -0
|
@@ -26,6 +26,9 @@ def generate_graphs(HomePage):
|
|
|
26
26
|
elif (selected_graph == "Calibrated Parameters"):
|
|
27
27
|
HomePage.selected_graph_name = "calibrated_params_by_round"
|
|
28
28
|
calibrated_params_by_round(HomePage.running_config['steps'], HomePage.calibration_data, HomePage.option_manager)
|
|
29
|
+
elif (selected_graph == "Custom CSV"):
|
|
30
|
+
HomePage.selected_graph_name = "custom_csv"
|
|
31
|
+
custom_csv(HomePage, HomePage.option_manager)
|
|
29
32
|
|
|
30
33
|
image_path = os.path.join(folder, HomePage.selected_graph_name + ".png")
|
|
31
34
|
|
|
@@ -272,4 +275,70 @@ def calibrated_params_by_round(config, list_of_objs, option_manager):
|
|
|
272
275
|
with open(os.path.join(folder, "calibrated_params_by_round.html"), "w") as f:
|
|
273
276
|
f.write(html)
|
|
274
277
|
|
|
275
|
-
return fig
|
|
278
|
+
return fig
|
|
279
|
+
|
|
280
|
+
def custom_csv(homepage, option_manager):
|
|
281
|
+
fig = go.Figure()
|
|
282
|
+
|
|
283
|
+
data = homepage.csv_data
|
|
284
|
+
|
|
285
|
+
x = homepage.csv_x_selector.get()
|
|
286
|
+
val = homepage.csv_y1_selector.get()
|
|
287
|
+
val2 = homepage.csv_y2_selector.get()
|
|
288
|
+
|
|
289
|
+
xx = None
|
|
290
|
+
if x == "time":
|
|
291
|
+
xx = pd.to_datetime(data["time"], format='%Y-%m-%d', errors='coerce').iloc[2:]
|
|
292
|
+
else:
|
|
293
|
+
xx = pd.to_numeric(data[x], errors="coerce").iloc[2:]
|
|
294
|
+
|
|
295
|
+
yy = pd.to_numeric(data[val], errors="coerce").iloc[2]
|
|
296
|
+
|
|
297
|
+
yy_unit = pd.to_numeric(data[val], errors="coerce").iloc[2]
|
|
298
|
+
|
|
299
|
+
yy2 = pd.to_numeric(data[val2], errors="coerce").iloc[2:]
|
|
300
|
+
|
|
301
|
+
yy2_unit = pd.to_numeric(data[val2], errors="coerce").iloc[2]
|
|
302
|
+
|
|
303
|
+
fig.add_trace(go.Scatter(x=xx, y=yy, name=val))
|
|
304
|
+
fig.add_trace(go.Scatter(x=xx, y=yy2, name=val2, yaxis='y2'))
|
|
305
|
+
|
|
306
|
+
fig.update_layout(
|
|
307
|
+
title="",
|
|
308
|
+
xaxis_title=x,
|
|
309
|
+
yaxis_title=val,
|
|
310
|
+
font=dict(color='white'),
|
|
311
|
+
paper_bgcolor='rgba(42, 42, 42, 0)',
|
|
312
|
+
plot_bgcolor='rgb(62, 62, 62)',
|
|
313
|
+
xaxis=dict(
|
|
314
|
+
gridcolor='rgb(72, 72, 72)',
|
|
315
|
+
gridwidth=1
|
|
316
|
+
),
|
|
317
|
+
yaxis=dict(
|
|
318
|
+
title=val + " (" + str(yy_unit) + ")",
|
|
319
|
+
autorange=True,
|
|
320
|
+
gridcolor='rgb(72, 72, 72)',
|
|
321
|
+
gridwidth=0.1
|
|
322
|
+
),
|
|
323
|
+
yaxis2=dict(
|
|
324
|
+
title=val2 + " (" + str(yy2_unit) + ")",
|
|
325
|
+
overlaying='y',
|
|
326
|
+
side='right'
|
|
327
|
+
)
|
|
328
|
+
)
|
|
329
|
+
|
|
330
|
+
info = option_manager.get_project_data()
|
|
331
|
+
folder = os.path.join(info['path'], info['name'])
|
|
332
|
+
|
|
333
|
+
if not os.path.exists(folder):
|
|
334
|
+
os.makedirs(folder)
|
|
335
|
+
|
|
336
|
+
fig.write_image(os.path.join(folder, "custom_csv.png"), width=1280, height=720)
|
|
337
|
+
fig.write_html(os.path.join(folder, "custom_csv.html"), include_plotlyjs='cdn', auto_open=False)
|
|
338
|
+
with open(os.path.join(folder, "custom_csv.html"), "r") as f:
|
|
339
|
+
html = f.read()
|
|
340
|
+
html = html.replace("<body>", "<body bgcolor='#2a2a2a'>")
|
|
341
|
+
with open(os.path.join(folder, "custom_csv.html"), "w") as f:
|
|
342
|
+
f.write(html)
|
|
343
|
+
|
|
344
|
+
return fig
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|