mg-pso-gui 0.2.51__py3-none-any.whl → 0.2.52__py3-none-any.whl

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.
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: mg-pso-gui
3
- Version: 0.2.51
3
+ Version: 0.2.52
4
4
  Summary: GUI for MG-PSO
5
5
  Author: Robert Cordingly
6
6
  Author-email: <rcording@uw.ed>
@@ -1,15 +1,15 @@
1
1
  mgpsogui/__init__.py,sha256=q7AfBjeJABnFtbsZnsObpUwaXKPDVYtz46G6MKXLF74,42
2
2
  mgpsogui/mgpsogui.py,sha256=NIZmyNcbwC8EgSwf1ubdMUSJscrIEgoD4jLYziqHQ-k,148
3
3
  mgpsogui/start.yaml,sha256=ZjCVLb-MLqAxrGRm9kA7_SDpa-45EuKIELNQ2QqCAiU,4713
4
- mgpsogui/gui/HomePage.py,sha256=WdbmNOcQ7qD-WmuL98T4v6j5vtQpS4MNwH6EjKHVYoE,21825
5
- mgpsogui/gui/OptionManager.py,sha256=HLVib_lHdMijykF78bJ9_PEl-oROuC8lxd1oBS7524U,21898
4
+ mgpsogui/gui/HomePage.py,sha256=oSlJAwpmX2vpu5TB8RlnCVP8GezNZV9LTTWN0_qXZaU,21828
5
+ mgpsogui/gui/OptionManager.py,sha256=_TT-RSUYdRTzoBr8STx_XDdPt--31byQsL8zmxM7quA,22003
6
6
  mgpsogui/gui/OptionManager_backup.py,sha256=TCWfPnHL2foN5id47jsi267lamRG6yGU6y_M29eOOJk,18530
7
7
  mgpsogui/gui/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
8
8
  mgpsogui/gui/General/ParameterView.py,sha256=gTpsXQomHgWxdHhiMxjOk171PeefXqdpVQefH88PE_c,6384
9
9
  mgpsogui/gui/General/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
10
10
  mgpsogui/gui/PlatformTab/PlatformTab.py,sha256=XVaXjNoH1MBI-587CWigLIT3LGT00yzEAEnXNkzCLrk,10947
11
11
  mgpsogui/gui/PlatformTab/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
12
- mgpsogui/gui/RunTab/RunTab.py,sha256=8FT7mdxNRQrftDuU0v4LoK1eyH8_RHwLOyM4dz8O_4A,1850
12
+ mgpsogui/gui/RunTab/RunTab.py,sha256=ggqPDEtTEWv9Li1JHutHgIZrsFF4SVE3mgU6haK6M-U,4904
13
13
  mgpsogui/gui/RunTab/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
14
14
  mgpsogui/gui/SetupTab/BoundsEditorWindow.py,sha256=U64oaiDIOaimjbqKMz5rQNq2o1SrQtrRHDdTYQ9ux1s,2870
15
15
  mgpsogui/gui/SetupTab/BoundsList.py,sha256=1pjSiIadZs2BX-EvBCCjMCTBh-g7Y9oZE6VPI-3bEP0,12383
@@ -21,7 +21,7 @@ mgpsogui/gui/SetupTab/ListParametersView.py,sha256=mkGaC5cXhEOy5oD0MbTyK9z7VGZp0
21
21
  mgpsogui/gui/SetupTab/OptimalParameterView.py,sha256=nliUEWA840cPBQt7wjiZ-L7uBOp_ozzJhyBkL08fJzI,1752
22
22
  mgpsogui/gui/SetupTab/OverrideParameterMetrics.py,sha256=rBfaSitYDOajbHvyi2TfoXAHYlz1cCt028UVpIJ_Dc0,3369
23
23
  mgpsogui/gui/SetupTab/OverrideParameterWindow.py,sha256=UpZDxTaFxee0BeviUYXeiIlMNYNy00qz3zlMlM5VcXE,1291
24
- mgpsogui/gui/SetupTab/SetupTab.py,sha256=7XUJW4r2n0-J4Mv6qk4B5yYqUaxaO5UB4ryYnOHQX4c,2800
24
+ mgpsogui/gui/SetupTab/SetupTab.py,sha256=3V8LYvg5ulTll1hhguB_XpSoOR-w72vHh_Z3gw3nCxc,2758
25
25
  mgpsogui/gui/SetupTab/StepView.py,sha256=e3QhepeAfDJdhefsJvzyppRuMdVAFKEnbZLtrFIczU4,8936
26
26
  mgpsogui/gui/SetupTab/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
27
27
  mgpsogui/gui/VisualizeTab/MatrixEditor.py,sha256=Gzyl2hRgjIfO5n0bCZZoXp_vOFvfsJPaGXDUMeRQg10,3171
@@ -69,8 +69,8 @@ mgpsogui/util/recosu/utils/trace_writer.py,sha256=V9BJlOjCbNYGoXGEk3CF5wjifBxvar
69
69
  mgpsogui/util/recosu/utils/utils.py,sha256=QB8vftq3142ekG0ORjz0ZBHU5YknXbR0oTsrxrPAsF0,3951
70
70
  mgpsogui/util/recosu/utils/plot/__init__.py,sha256=h1KjM7_tNDv351pcwt8A6Ibb1jhwWyx5Gbu-zj-sI3Q,71
71
71
  mgpsogui/util/recosu/utils/plot/cost_steps.py,sha256=1Ce11AJyweWkmvjXPxEygzS-h8yVLmQEDLS53yjPLqQ,3779
72
- mg_pso_gui-0.2.51.dist-info/METADATA,sha256=w1u0-SQxOl1v36QEizVbG9UgYPTIR3yAFVFn_eKouGw,9455
73
- mg_pso_gui-0.2.51.dist-info/WHEEL,sha256=cVxcB9AmuTcXqmwrtPhNK88dr7IR_b6qagTj0UvIEbY,91
74
- mg_pso_gui-0.2.51.dist-info/entry_points.txt,sha256=jg82VOFjR1XDGrchs1wJSCqKYE4Ozv12aBcCSp--koA,117
75
- mg_pso_gui-0.2.51.dist-info/top_level.txt,sha256=y7JuS9xJN5YdxUsQ3PSVjN8MzQAnR146bP3ZN3PYWdE,9
76
- mg_pso_gui-0.2.51.dist-info/RECORD,,
72
+ mg_pso_gui-0.2.52.dist-info/METADATA,sha256=OrpbWVuc3rHgbsL5iNI7zPAmPAlPhOQ_c3CC79rBux0,9455
73
+ mg_pso_gui-0.2.52.dist-info/WHEEL,sha256=cVxcB9AmuTcXqmwrtPhNK88dr7IR_b6qagTj0UvIEbY,91
74
+ mg_pso_gui-0.2.52.dist-info/entry_points.txt,sha256=jg82VOFjR1XDGrchs1wJSCqKYE4Ozv12aBcCSp--koA,117
75
+ mg_pso_gui-0.2.52.dist-info/top_level.txt,sha256=y7JuS9xJN5YdxUsQ3PSVjN8MzQAnR146bP3ZN3PYWdE,9
76
+ mg_pso_gui-0.2.52.dist-info/RECORD,,
mgpsogui/gui/HomePage.py CHANGED
@@ -161,7 +161,7 @@ class App(customtkinter.CTk):
161
161
  self.tabview.grid(row=1, column=0, padx=(0, 0), pady=(10, 10), sticky="nsew")
162
162
  tab1 = "Platform"
163
163
  tab2 = "Setup"
164
- tab3 = "Logs"
164
+ tab3 = "Project"
165
165
  tab4 = "Results"
166
166
 
167
167
  self.tabview.add(tab1)
@@ -371,6 +371,9 @@ class OptionManager():
371
371
  path = filename.replace(file_name + ".json", "")
372
372
  self._project_data["path"] = path
373
373
  self._project_data["name"] = file_name
374
+
375
+ def copy_list(self, source_mode):
376
+ self._data[self._mode_sv.get()] = self._data[source_mode]
374
377
 
375
378
  def get_data(self):
376
379
  return self._data[self._mode_sv.get()]
@@ -8,15 +8,23 @@ import re
8
8
  import ast
9
9
  import pandas as pd
10
10
  import numpy as np
11
+ import os
12
+ import platform
13
+ import subprocess
11
14
 
12
15
  from ...util import PSORunner
13
16
  from ...util import GraphGenerator
14
17
  from ...util.CTkToolTip import CTkToolTip as ctt
18
+ import customtkinter
19
+
20
+ from . import OptimalParameterView as opv
15
21
 
16
22
  def create_tab(self, tab):
17
23
 
18
24
  # URL
19
25
  tab.grid_columnconfigure(0, weight=1)
26
+ tab.grid_columnconfigure(1, weight=5)
27
+ tab.grid_columnconfigure(2, weight=5)
20
28
  tab.grid_rowconfigure(0, weight=1)
21
29
  tab.grid_rowconfigure(1, weight=200)
22
30
 
@@ -36,7 +44,65 @@ def create_tab(self, tab):
36
44
  #self.progress_message_right = customtkinter.CTkLabel(self.progress_container, text="")
37
45
  #self.progress_message_right.grid(row=0, column=2, padx=(10, 10), pady=(10, 10), sticky="e")
38
46
 
47
+ self.optimal_param_frame = opv.OptimalParameterView(tab, option_manager=self.option_manager)
48
+ self.optimal_param_frame.grid(row=0, column=0, padx=(10, 10), pady=(10, 0), sticky="nsew")
49
+ self.optimal_param_frame.grid_columnconfigure(0, weight=1)
50
+ self.optimal_param_frame.grid_rowconfigure(0, weight=1)
51
+
39
52
  self.textbox = customtkinter.CTkTextbox(tab)
40
- self.textbox.grid(row=1, column=0, padx=(20, 20), pady=(20, 20), sticky="nsew")
41
- self.textbox.insert("0.0", "Welcome to the CSIP PSO Calibration Tool!\n\nUse the Setup tab to define steps and calibration parameters. Use this tab to view logs and observe calibration progress. Once finished, use the Results tab to generate figures and graphs.")
42
-
53
+ self.textbox.grid(row=0, column=1, padx=(20, 20), pady=(20, 20), sticky="nsew")
54
+ self.textbox.insert("0.0", "Welcome to the CSIP PSO Calibration Tool!\n\nUse the Setup tab to define steps and calibration parameters. Use this tab to view logs and manage your Project. Once finished, use the Results tab to generate figures and graphs.")
55
+
56
+ self.project_editor = customtkinter.CTkScrollableFrame(tab, label_text="Project Editor")
57
+ self.project_editor.grid(row=0, column=2, padx=(20, 20), pady=(20, 20), sticky="nsew")
58
+ self.project_editor.grid_columnconfigure(0, weight=1)
59
+ self.project_editor.grid_rowconfigure(0, weight=1)
60
+
61
+ customtkinter.CTkLabel(self.project_editor, text="Copy Data to Current Mode:").grid(row=0, column=0, padx=(20, 20), pady=(5, 10), sticky="ew")
62
+
63
+ def copy_sense():
64
+ self.option_manager.copy_list("Sensitivity Analysis")
65
+ self.refresh_step_view(0)
66
+
67
+ def copy_halton():
68
+ self.option_manager.copy_list("Sampling: Halton")
69
+ self.refresh_step_view(0)
70
+
71
+ def copy_random():
72
+ self.option_manager.copy_list("Sampling: Random")
73
+ self.refresh_step_view(0)
74
+
75
+ def copy_optim():
76
+ self.option_manager.copy_list("Optimization")
77
+ self.refresh_step_view(0)
78
+
79
+ def open_project_folder():
80
+ # Open the file in the default program
81
+ folder = self.option_manager.get_project_folder()
82
+
83
+ if not os.path.exists(folder):
84
+ os.makedirs(folder)
85
+
86
+ if platform.system() == "Windows":
87
+ os.startfile(folder)
88
+ elif platform.system() == "Darwin":
89
+ subprocess.Popen(["open", folder])
90
+ else:
91
+ subprocess.Popen(["xdg-open", folder])
92
+
93
+ self.analysis_copy = customtkinter.CTkButton(self.project_editor, text="From Sensitivity Analysis", command=copy_sense)
94
+ self.analysis_copy.grid(row=1, column=0, padx=(20, 20), pady=(5, 10), sticky="ew")
95
+
96
+ self.halton_copy = customtkinter.CTkButton(self.project_editor, text="From Sampling: Halton", command=copy_halton)
97
+ self.halton_copy.grid(row=2, column=0, padx=(20, 20), pady=(5, 10), sticky="ew")
98
+
99
+ self.random_copy = customtkinter.CTkButton(self.project_editor, text="From Sampling: Random", command=copy_random)
100
+ self.random_copy.grid(row=3, column=0, padx=(20, 20), pady=(5, 10), sticky="ew")
101
+
102
+ self.optimization_copy = customtkinter.CTkButton(self.project_editor, text="From Optimization", command=copy_optim)
103
+ self.optimization_copy.grid(row=4, column=0, padx=(20, 20), pady=(5, 10), sticky="ew")
104
+
105
+ customtkinter.CTkLabel(self.project_editor, text="Project Management:").grid(row=5, column=0, padx=(20, 20), pady=(5, 10), sticky="ew")
106
+
107
+ self.open_folder = customtkinter.CTkButton(self.project_editor, text="Open Project Folder", command=open_project_folder)
108
+ self.open_folder.grid(row=4, column=0, padx=(20, 20), pady=(5, 10), sticky="ew")
@@ -1,7 +1,6 @@
1
1
 
2
2
 
3
3
  from . import StepView as sv
4
- from . import OptimalParameterView as opv
5
4
  from ..General import ParameterView as pv
6
5
 
7
6
  import customtkinter