pyanno4rt.gui.windows

GUI windows module.


The module aims to provide methods and classes to …

Subpackages

Overview

Classes

CompareWindow

Plan comparison window for the GUI.

InfoWindow

Information window for the GUI.

LogWindow

Logging window for the application.

PlanCreationWindow

Plan creation window for the application.

SettingsWindow

Settings window for the GUI.

TextWindow

Text window for the application.

TreeWindow

Tree window for the application.

MainWindow

Main window for the GUI.

Classes

class pyanno4rt.gui.windows.CompareWindow(parent=None)[source]

Bases: PyQt5.QtWidgets.QMainWindow, pyanno4rt.gui.compilations.compare_window.Ui_compare_window

Plan comparison window for the GUI.

This class creates the plan comparison window for the graphical user interface, including some general information on the package.

Overview

Methods

position()

.

close()

.

Members

position()[source]

.

close()[source]

.

class pyanno4rt.gui.windows.InfoWindow(parent=None)[source]

Bases: PyQt5.QtWidgets.QMainWindow, pyanno4rt.gui.compilations.info_window.Ui_info_window

Information window for the GUI.

This class creates the information window for the graphical user interface, including some general information on the package.

Overview

Methods

position()

.

close()

.

Members

position()[source]

.

close()[source]

.

class pyanno4rt.gui.windows.LogWindow(parent=None)[source]

Bases: PyQt5.QtWidgets.QMainWindow, pyanno4rt.gui.compilations.log_window.Ui_log_window

Logging window for the application.

This class creates the log window for the graphical user interface, including the output of the logger.

Overview

Methods

position()

.

update_log_output()

.

close()

.

Members

position()[source]

.

update_log_output()[source]

.

close()[source]

.

class pyanno4rt.gui.windows.PlanCreationWindow(parent=None)[source]

Bases: PyQt5.QtWidgets.QMainWindow, pyanno4rt.gui.compilations.plan_creation_window.Ui_plan_creation_window

Plan creation window for the application.

This class creates a plan creation window for the graphical user interface, including input fields to declare a plan.

Overview

Methods

eventFilter(source, event)

Customize the event filters.

position()

.

update_create_button()

.

update_by_new_plan_reference()

.

add_imaging_path()

Add the CT and segmentation data from a folder.

add_dose_matrix_path()

Add the dose-influence matrix from a folder.

create()

.

close()

.

Members

eventFilter(source, event)[source]

Customize the event filters.

Parameters:
  • source

  • event

Return type:

position()[source]

.

update_create_button()[source]

.

update_by_new_plan_reference()[source]

.

add_imaging_path()[source]

Add the CT and segmentation data from a folder.

add_dose_matrix_path()[source]

Add the dose-influence matrix from a folder.

create()[source]

.

close()[source]

.

class pyanno4rt.gui.windows.SettingsWindow(parent=None)[source]

Bases: PyQt5.QtWidgets.QMainWindow, pyanno4rt.gui.compilations.settings_window.Ui_settings_window

Settings window for the GUI.

This class creates the settings window for the graphical user interface, including some user-definable parameters.

Overview

Methods

eventFilter(source, event)

Customize the event filters.

position()

.

get_fields()

.

set_fields(settings)

.

reset()

.

save_apply_close()

.

Members

eventFilter(source, event)[source]

Customize the event filters.

Parameters:
  • source

  • event

Return type:

position()[source]

.

get_fields()[source]

.

set_fields(settings)[source]

.

reset()[source]

.

save_apply_close()[source]

.

class pyanno4rt.gui.windows.TextWindow(parent=None)[source]

Bases: PyQt5.QtWidgets.QMainWindow, pyanno4rt.gui.compilations.text_window.Ui_text_window

Text window for the application.

This class creates a text window for the graphical user interface, including a scrollable text box for display.

Overview

Methods

position()

.

close()

.

Members

position()[source]

.

close()[source]

.

class pyanno4rt.gui.windows.TreeWindow(title, parent=None)[source]

Bases: PyQt5.QtWidgets.QMainWindow, pyanno4rt.gui.compilations.tree_window.Ui_tree_window

Tree window for the application.

This class creates a tree window for the graphical user interface, including a tree-based table view for dictionaries.

Overview

Methods

position()

.

create_tree_from_dict(data, parent)

.

show_item_text(tree, item)

.

expand_all()

.

collapse_all()

.

close()

.

Members

position()[source]

.

create_tree_from_dict(data=None, parent=None)[source]

.

show_item_text(tree, item)[source]

.

expand_all()[source]

.

collapse_all()[source]

.

close()[source]

.

class pyanno4rt.gui.windows.MainWindow(treatment_plan, application=None)[source]

Bases: PyQt5.QtWidgets.QMainWindow, pyanno4rt.gui.compilations.main_window.Ui_main_window

Main window for the GUI.

This class creates the main window for the graphical user interface, including logo, labels, and input/control elements.

Parameters:
  • treatment_plan (object of class TreatmentPlan) – Instance of the class TreatmentPlan, which provides methods and classes to generate treatment plans.

  • application (object of class SpyderQApplication) – Instance of the class SpyderQApplication for managing control flow and main settings of the graphical user interface.

Overview

Methods

connect_signals()

Connect the event signals to the GUI elements.

eventFilter(source, event)

Customize the event filters.

mousePressEvent(event)

-

set_initial_plan(treatment_plan)

Set the initial treatment plan in the GUI.

set_enabled(fieldnames)

Enable multiple fields by their names.

set_disabled(fieldnames)

Disable multiple fields by their names.

set_zero_line_cursor(fieldnames)

Set the line edit cursor positions to zero.

set_styles(key_value_pairs)

Set the element stylesheets from key-value pairs.

activate(treatment_plan)

Activate a treatment plan instance in the GUI.

load_tpi()

Load the treatment plan from a snapshot folder.

save_tpi()

Save the treatment plan to a snapshot folder.

drop_tpi()

Remove the current treatment plan.

select_plan()

Select a treatment plan.

initialize()

Initialize the treatment plan.

configure()

Configure the treatment plan.

optimize()

Optimize the treatment plan.

evaluate()

Evaluate the treatment plan.

visualize()

Visualize the treatment plan.

update_configuration()

Update the configuration parameters.

update_optimization()

Update the optimization parameters.

update_evaluation()

Update the evaluation parameters.

set_configuration()

Set the configuration parameters.

set_optimization()

Set the optimization parameters.

set_evaluation()

Set the evaluation parameters.

clear_configuration()

Clear the configuration parameters.

clear_optimization()

Clear the optimization parameters.

clear_evaluation()

Clear the evaluation parameters.

transform_configuration_to_dict()

Transform the configuration fields into a dictionary.

transform_optimization_to_dict()

Transform the optimization fields into a dictionary.

transform_evaluation_to_dict()

Transform the evaluation fields into a dictionary.

open_plan_creation_window()

Open the plan creation window.

open_settings_window()

Open the settings window.

open_info_window()

Open the information window.

open_compare_window()

Open the plan comparison window.

open_component_window(name)

Open a component window.

open_parameter_window()

Open the plan parameter window.

open_plan_window()

Open the plan data window.

open_model_data_window()

Open the model data window.

open_feature_map_window()

Open the feature map window.

open_log_window()

Open the log window.

open_question_dialog()

Open a question dialog.

add_imaging_path()

Add the CT and segmentation data from a folder.

add_dose_matrix_path()

Add the dose-influence matrix from a folder.

remove_component()

Remove the selected component from the instance.

edit_component()

Open a component window.

add_initial_fluence_vector()

Add the initial fluence vector from a file.

add_lower_var_bounds()

Add the lower variable bounds from a file.

add_upper_var_bounds()

Add the upper variable bounds from a file.

update_init_button()

.

update_by_initial_strategy()

Update the GUI by the initial strategy.

update_by_initial_fluence()

Update the GUI by the initial fluence vector.

update_by_reference()

Update the GUI by the reference plan.

update_by_method()

Update the GUI by the optimization method.

update_by_solver()

Update the GUI by the solver.

update_reference_plans()

Update the available reference plans.

update_comparison_plans()

.

update_compare_button()

.

exit_window()

Exit the session and close the window.

Members

connect_signals()[source]

Connect the event signals to the GUI elements.

eventFilter(source, event)[source]

Customize the event filters.

Parameters:
  • source

  • event

Return type:

mousePressEvent(event)[source]
set_initial_plan(treatment_plan)[source]

Set the initial treatment plan in the GUI.

Parameters:

treatment_plan

set_enabled(fieldnames)[source]

Enable multiple fields by their names.

Parameters:

fieldnames

set_disabled(fieldnames)[source]

Disable multiple fields by their names.

Parameters:

fieldnames

set_zero_line_cursor(fieldnames)[source]

Set the line edit cursor positions to zero.

Parameters:

fieldnames

set_styles(key_value_pairs)[source]

Set the element stylesheets from key-value pairs.

Parameters:

key_value_pairs

activate(treatment_plan)[source]

Activate a treatment plan instance in the GUI.

Parameters:

treatment_plan

load_tpi()[source]

Load the treatment plan from a snapshot folder.

save_tpi()[source]

Save the treatment plan to a snapshot folder.

drop_tpi()[source]

Remove the current treatment plan.

select_plan()[source]

Select a treatment plan.

initialize()[source]

Initialize the treatment plan.

Returns:

Indicator for the success of the initialization.

Return type:

bool

configure()[source]

Configure the treatment plan.

Returns:

Indicator for the success of the configuration.

Return type:

bool

optimize()[source]

Optimize the treatment plan.

Returns:

Indicator for the success of the optimization.

Return type:

bool

evaluate()[source]

Evaluate the treatment plan.

Returns:

Indicator for the success of the evaluation.

Return type:

bool

visualize()[source]

Visualize the treatment plan.

Returns:

Indicator for the success of the visualization.

Return type:

bool

update_configuration()[source]

Update the configuration parameters.

update_optimization()[source]

Update the optimization parameters.

update_evaluation()[source]

Update the evaluation parameters.

set_configuration()[source]

Set the configuration parameters.

set_optimization()[source]

Set the optimization parameters.

set_evaluation()[source]

Set the evaluation parameters.

clear_configuration()[source]

Clear the configuration parameters.

clear_optimization()[source]

Clear the optimization parameters.

clear_evaluation()[source]

Clear the evaluation parameters.

transform_configuration_to_dict()[source]

Transform the configuration fields into a dictionary.

Returns:

Dictionary with the configuration parameters.

Return type:

dict

transform_optimization_to_dict()[source]

Transform the optimization fields into a dictionary.

Returns:

Dictionary with the optimization parameters.

Return type:

dict

transform_evaluation_to_dict()[source]

Transform the evaluation fields into a dictionary.

Returns:

Dictionary with the evaluation parameters.

Return type:

dict

open_plan_creation_window()[source]

Open the plan creation window.

open_settings_window()[source]

Open the settings window.

open_info_window()[source]

Open the information window.

open_compare_window()[source]

Open the plan comparison window.

open_component_window(name)[source]

Open a component window.

open_parameter_window()[source]

Open the plan parameter window.

open_plan_window()[source]

Open the plan data window.

open_model_data_window()[source]

Open the model data window.

open_feature_map_window()[source]

Open the feature map window.

open_log_window()[source]

Open the log window.

open_question_dialog()[source]

Open a question dialog.

add_imaging_path()[source]

Add the CT and segmentation data from a folder.

add_dose_matrix_path()[source]

Add the dose-influence matrix from a folder.

remove_component()[source]

Remove the selected component from the instance.

edit_component()[source]

Open a component window.

add_initial_fluence_vector()[source]

Add the initial fluence vector from a file.

add_lower_var_bounds()[source]

Add the lower variable bounds from a file.

add_upper_var_bounds()[source]

Add the upper variable bounds from a file.

update_init_button()[source]

.

update_by_initial_strategy()[source]

Update the GUI by the initial strategy.

update_by_initial_fluence()[source]

Update the GUI by the initial fluence vector.

update_by_reference()[source]

Update the GUI by the reference plan.

update_by_method()[source]

Update the GUI by the optimization method.

update_by_solver()[source]

Update the GUI by the solver.

update_reference_plans()[source]

Update the available reference plans.

update_comparison_plans()[source]

.

update_compare_button()[source]

.

exit_window()[source]

Exit the session and close the window.