|
|
|
@ -27,6 +27,7 @@ from .workflows import (
@@ -27,6 +27,7 @@ from .workflows import (
|
|
|
|
|
|
|
|
|
|
PARAMETERS_FILE = "mia-gui-parameters.json" |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
class MtorImageAnalysis(QWidget): |
|
|
|
|
def __init__(self): |
|
|
|
|
super().__init__() |
|
|
|
@ -89,14 +90,14 @@ class MtorImageAnalysis(QWidget):
@@ -89,14 +90,14 @@ class MtorImageAnalysis(QWidget):
|
|
|
|
|
self.btn_exit.clicked.connect(QApplication.instance().quit) |
|
|
|
|
|
|
|
|
|
self.fields_map = { |
|
|
|
|
'folder': (self.dir_selected, str), |
|
|
|
|
'top': (self.roi_top_input, int), |
|
|
|
|
'right': (self.roi_right_input, int), |
|
|
|
|
'bottom': (self.roi_bottom_input, int), |
|
|
|
|
'left': (self.roi_left_input, int), |
|
|
|
|
'cut_pad_x': (self.pad_x_input, int), |
|
|
|
|
'cut_pad_y': (self.pad_y_input, int), |
|
|
|
|
'boost': (self.cc_boost_input, int), |
|
|
|
|
"folder": (self.dir_selected, str), |
|
|
|
|
"top": (self.roi_top_input, int), |
|
|
|
|
"right": (self.roi_right_input, int), |
|
|
|
|
"bottom": (self.roi_bottom_input, int), |
|
|
|
|
"left": (self.roi_left_input, int), |
|
|
|
|
"cut_pad_x": (self.pad_x_input, int), |
|
|
|
|
"cut_pad_y": (self.pad_y_input, int), |
|
|
|
|
"boost": (self.cc_boost_input, int), |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
# Layout |
|
|
|
@ -203,7 +204,9 @@ class MtorImageAnalysis(QWidget):
@@ -203,7 +204,9 @@ class MtorImageAnalysis(QWidget):
|
|
|
|
|
parameter_path = Path(parameters["folder"]) / PARAMETERS_FILE |
|
|
|
|
try: |
|
|
|
|
with parameter_path.open("w") as fh: |
|
|
|
|
tmp = {k: v for k, v in parameters.items() if k != "folder"} |
|
|
|
|
tmp = { |
|
|
|
|
k: v for k, v in parameters.items() if k != "folder" |
|
|
|
|
} |
|
|
|
|
print(tmp) |
|
|
|
|
json.dump(tmp, fh) |
|
|
|
|
except Exception: |
|
|
|
|