Skip to content

Commit

Permalink
grouping the commands. this refs #79
Browse files Browse the repository at this point in the history
  • Loading branch information
JeanBilheux committed Aug 18, 2023
1 parent 6f8faa9 commit f097449
Show file tree
Hide file tree
Showing 4 changed files with 24 additions and 9 deletions.
6 changes: 5 additions & 1 deletion src/hyperctui/autonomous_reconstruction/event_handler.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@

from hyperctui import EvaluationRegionKeys
from hyperctui import interact_me_style, normal_style, error_style, label_in_focus_style
from hyperctui.commands_launcher import CommandLauncher

from hyperctui.session import SessionKeys

Expand Down Expand Up @@ -167,6 +168,9 @@ def start_acquisition(self):

self.init_autonomous_table()

o_cmd = CommandLauncher(parent=self.parent)
o_cmd.launch_preprocessing_autonomous_reconstruction()

def stop_acquisition(self):
self.parent.ui.autonomous_projections_groupBox.setEnabled(True)
self.parent.ui.autonomous_evaluation_groupBox.setEnabled(True)
Expand Down Expand Up @@ -390,7 +394,7 @@ def refresh_reconstruction_table_clicked(self):
o_config = ConfigHandler(parent=self.parent)
o_config.load_reconstruction_config()





Expand Down
15 changes: 14 additions & 1 deletion src/hyperctui/commands_launcher.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,17 @@


class CommandLauncher(Parent):
pass

def launch_ob_first_projections_acquisition(self):
# get the number of OBs requested (if any)

# get the title

pass

def launch_preprocessing_autonomous_reconstruction(self):
# list of angles
# evaluation regions
# TOF regions

pass
6 changes: 0 additions & 6 deletions src/hyperctui/event_handler.py
Original file line number Diff line number Diff line change
Expand Up @@ -156,12 +156,6 @@ def main_tab_changed(self, new_tab_index=0):
self.parent.ui.setGeometry(rect)
self.parent.current_tab_index = new_tab_index

def start_acquisition(self):
"""
script that will call Shimin's code to take OB and first projections
"""
pass

def freeze_number_ob_sample_requested(self):
"""
this freeze the number of OB and sample measured and record the initial list of OBs and sample folders
Expand Down
6 changes: 5 additions & 1 deletion src/hyperctui/hyperctui.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@
from hyperctui.utilities.config_handler import ConfigHandler
from hyperctui.utilities.folder_path import FolderPath
from hyperctui.utilities.status_message_config import StatusMessageStatus, show_status_message
from hyperctui.commands_launcher import CommandLauncher

# warnings.filterwarnings('ignore')
DEBUG = True
Expand Down Expand Up @@ -350,8 +351,11 @@ def number_of_projections_changed(self, value):
def start_acquisition_clicked(self):
self.session_dict[SessionKeys.process_in_progress] = True
self.session_dict[SessionKeys.started_acquisition] = True

o_cmd = CommandLauncher(parent=self)
o_cmd.launch_ob_first_projections_acquisition()

o_event = EventHandler(parent=self)
o_event.start_acquisition()
o_event.freeze_number_ob_sample_requested()
self.launch_pre_processing_monitor_view()
self.ui.start_acquisition_pushButton.setEnabled(False)
Expand Down

0 comments on commit f097449

Please sign in to comment.