pyvisor.GUI.model package
Submodules
pyvisor.GUI.model.animal module
- class pyvisor.GUI.model.animal.Animal(number: int, name: str)[source]
Bases:
objectRepresents a single animal being observed.
Each animal has a numeric ID, a display name, and a dictionary of
Behaviourobjects keyed by their label strings.
pyvisor.GUI.model.behaviour module
- class pyvisor.GUI.model.behaviour.Behaviour(animal_number: int = None, color: str = '#C0C0C0', icon_path: str = None, name: str = None, compatible_with: List[str] = None)[source]
Bases:
ScorerActionA scoreable behaviour linked to an animal.
Extends
ScorerActionwith animal association, display colour, icon path, and a compatibility list controlling which other behaviours can be active simultaneously.- ANIMAL_MOVIE = -1
- static from_savable_dict_to_dict_of_objects(plain_dict: Dict[str, Dict[str, Any]]) Dict[str, Behaviour][source]
- property icon
pyvisor.GUI.model.callback_handler module
Simple observer-pattern callback registry.
- class pyvisor.GUI.model.callback_handler.CallbackHandler[source]
Bases:
objectManages a set of registered callback functions.
Widgets register callables via
register()and receive a numeric ID for later removal. Iterating over the handler invokes all registered callbacks.
pyvisor.GUI.model.gui_data_interface module
- class pyvisor.GUI.model.gui_data_interface.GUIDataInterface[source]
Bases:
objectCentral data model shared across all GUI tabs.
Holds the animal/behaviour definitions, device selection, movie bindings, autosave settings, and the active scorer instance. Provides callback hooks so UI widgets can react to model changes.
- change_button_binding(action: ScorerAction, button_identifier: str | None, is_behaviour: bool)[source]
- get_action_assigned_to(button_identifier) Tuple[Behaviour, bool] | Tuple[None, bool][source]
Find the first action bound to button_identifier.
Returns
(action, is_behaviour)or(None, False).
- get_scorer_actions_without_buttons_assigned() List[ScorerAction][source]
- exception pyvisor.GUI.model.gui_data_interface.NameExistsException[source]
Bases:
RuntimeError
- exception pyvisor.GUI.model.gui_data_interface.NameIdenticalException[source]
Bases:
RuntimeError
pyvisor.GUI.model.key_bindings module
pyvisor.GUI.model.movie_bindings module
- class pyvisor.GUI.model.movie_bindings.MovieBindings[source]
Bases:
objectCollection of movie-control actions with their key bindings.
Manages bindings for play/pause, stop, forward, reverse, FPS adjustment, and frame stepping.
- get_action_assigned_to(device: str, button_identifier: str) ScorerAction[source]
- get_actions_without_buttons_assigned(device: str) List[ScorerAction][source]
pyvisor.GUI.model.scorer_action module
Module contents
Data model classes shared across the pyVISOR GUI.