src.edit.event_values package

Submodules

src.edit.event_values.event_values_controller module

Event Values Controller

class src.edit.event_values.event_values_controller.eventValuesController(file_type, event_values, event_ids, number_of_epochs, number_of_frames)[source]

Bases: edit.event_values.event_values_listener.eventValuesListener

cancel_button_clicked()[source]

Close the window.

confirm_button_clicked(event_name, latency)[source]

Close the window and send the information to the main controller. Display an error message if the number of events is different from the number of epochs, because there must be a event for each epoch. :param event_name: The event name. :type event_name: str :param latency: The latency of the event. :type latency: int

delete_button_clicked()[source]

Delete the information of the event displayed.

editing_finished_clicked(event_number)[source]

Load the event’s information based on the event number given. :param event_number: The event number :type event_number: int

get_epoch_number_from_latency(latency)[source]

Get the number of the epoch associated to the latency given. :param latency: The latency :type latency: int :return: epoch_number: The epoch number :rtype: int

get_event_info_from_number(event_number)[source]

Get the information of an event based on an event number. :param event_number: The event number :type event_number: int :return: current_event_name: The event name. latency: The event latency. :rtype: str, int

get_max_event_id()[source]

Get the greatest event id in the event ids dictionary. :return: max_event_id: The greatest event id :rtype: int

insert_button_clicked(event_name, latency)[source]

Save the information of the last event displayed before inserting a new event. :param event_name: The event name. :type event_name: str :param latency: The latency of the event. :type latency: int

insert_new_event_id()[source]

Insert a new event id in the dictionary containing all the event ids.

next_button_clicked(event_name, latency)[source]

Save the information of the last event displayed before displaying the information of the next event. :param event_name: The event name. :type event_name: str :param latency: The latency of the event. :type latency: int

previous_button_clicked(event_name, latency)[source]

Save the information of the last event displayed before displaying the information of the previous event. :param event_name: The event name. :type event_name: str :param latency: The latency of the event. :type latency: int

set_listener(listener)[source]

Set the main listener so that the controller is able to communicate with the main controller. :param listener: main listener :type listener: mainController

update_event_data(event_name, latency)[source]

Update the information of an event. :param event_name: The event name. :type event_name: str :param latency: The latency of the event. :type latency: int

update_event_displayed()[source]

Update the information of the event displayed based on the current event number (could have change because of the next, previous, etc. button pushed.

update_event_ids()[source]

Update the event ids. When a new event is inserted or a new event type is created by changing one, a new event id is associated to it. If an event id has no event associated to it (e.g. because of the deletion of an event), the event id is removed.

src.edit.event_values.event_values_listener module

Event Values Listener

class src.edit.event_values.event_values_listener.eventValuesListener[source]

Bases: abc.ABC

Listener doing the connection between the controller and the view for displaying the events’ information. It retrieves the information from the view to send it to the controller.

cancel_button_clicked()[source]
confirm_button_clicked(event_name, latency)[source]
delete_button_clicked()[source]
editing_finished_clicked(event_number)[source]
insert_button_clicked(event_name, latency)[source]
next_button_clicked(event_name, latency)[source]
previous_button_clicked(event_name, latency)[source]

src.edit.event_values.event_values_view module

Event Values View

class src.edit.event_values.event_values_view.eventValuesView(event_values, event_ids, number_of_epochs, number_of_frames)[source]

Bases: PyQt5.QtWidgets.QWidget

cancel_event_values_trigger()[source]

Send the information to the controller that the computation is cancelled.

confirm_event_values_trigger()[source]

Retrieve the event name and latency and send the information to the controller.

delete_button_trigger()[source]

Send the information to the controller to delete the current event.

editing_finished_trigger()[source]

Retrieve the new event number wanted to be displayed and send the information to the controller to display the wanted event.

insert_button_trigger()[source]

Retrieve the event name and latency and send the information to the controller to insert a new event.

next_button_trigger()[source]

Retrieve the event name and latency and send the information to the controller to display the next channel.

previous_button_trigger()[source]

Retrieve the event name and latency and send the information to the controller to display the previous channel.

set_event_values(event_values)[source]

Set the event values. :param event_values: The event values :type event_values: list of, list of int

set_listener(listener)[source]

Set the listener to the controller. :param listener: Listener to the controller. :type listener: eventValuesController

update_event_displayed(event_number, event_name, epoch_number, latency)[source]

Update the event displayed on the window. :param event_number: The event number. :type event_number: int :param event_name: The event name. :type event_name: str :param epoch_number: The epoch number. :type epoch_number: int :param latency: The latency of the event. :type latency: int

Module contents