pyampp.gxbox.selector_api

Classes

CoordMode

Coordinate representation used by the GUI center fields.

BoxGeometrySelection

Workflow-relevant box geometry values in the same shape as pyAMPP GUI fields.

SelectorSessionInput

Inputs needed to launch a future standalone map/box selector GUI.

DisplayFovSelection

Observer-plane image FOV used for synthetic image framing and canvas centering.

DisplayFovBoxSelection

Observer-aligned 3D FOV box.

SelectorDialogResult

Accepted result returned by the standalone selector dialog.

GeometrySelectionConsumer

Callback protocol for receiving accepted geometry selections.

Module Contents

class pyampp.gxbox.selector_api.CoordMode[source]

Bases: str, enum.Enum

Coordinate representation used by the GUI center fields.

HPC = 'hpc'[source]
HGC = 'hgc'[source]
HGS = 'hgs'[source]
class pyampp.gxbox.selector_api.BoxGeometrySelection[source]

Workflow-relevant box geometry values in the same shape as pyAMPP GUI fields.

These map directly to the existing PyAmppGUI input widgets: - coord_x / coord_y -> coord_x_edit / coord_y_edit - grid_x / grid_y / grid_z -> grid_*_edit - dx_km -> res_edit (CLI --dx-km)

coord_mode: CoordMode[source]
coord_x: float[source]
coord_y: float[source]
grid_x: int[source]
grid_y: int[source]
grid_z: int[source]
dx_km: float[source]
as_gui_text_fields() dict[str, str][source]

Return values formatted for direct assignment to QLineEdit widgets.

class pyampp.gxbox.selector_api.SelectorSessionInput[source]

Inputs needed to launch a future standalone map/box selector GUI.

map_ids and initial_map_id are UI-only state for visualization and are not part of the geometry return contract.

time_iso: str[source]
data_dir: str[source]
geometry: BoxGeometrySelection[source]
fov: DisplayFovSelection | None = None[source]
fov_box: DisplayFovBoxSelection | None = None[source]
square_fov: bool = False[source]
allow_geometry_edit: bool = True[source]
map_ids: tuple[str, Ellipsis] = ()[source]
map_files: dict[str, str] | None = None[source]
refmaps: dict[str, dict[str, Any]] | None = None[source]
base_maps: dict[str, Any] | None = None[source]
base_wcs_header: str | None = None[source]
base_geometry: BoxGeometrySelection | None = None[source]
map_source_mode: str = 'auto'[source]
display_observer_key: str = 'earth'[source]
custom_observer_ephemeris: dict[str, Any] | None = None[source]
custom_observer_label: str | None = None[source]
custom_observer_source: str | None = None[source]
available_observer_keys: tuple[str, Ellipsis] | None = None[source]
observer_availability_notice: str | None = None[source]
initial_map_id: str | None = None[source]
pad_frac: float | None = None[source]
class pyampp.gxbox.selector_api.DisplayFovSelection[source]

Observer-plane image FOV used for synthetic image framing and canvas centering.

This is intentionally separate from the model box geometry. Values are expressed in helioprojective (observer-plane) arcsec, regardless of the red-box input coordinate mode.

center_x_arcsec: float[source]
center_y_arcsec: float[source]
width_arcsec: float[source]
height_arcsec: float[source]
as_gui_text_fields() dict[str, str][source]
class pyampp.gxbox.selector_api.DisplayFovBoxSelection[source]

Observer-aligned 3D FOV box.

The x/y footprint matches the image-plane FOV rectangle in helioprojective arcsec. The z extent is stored in observer-centric heliocentric coordinates (Mm) along the line of sight, where larger values are closer to the observer.

center_x_arcsec: float[source]
center_y_arcsec: float[source]
width_arcsec: float[source]
height_arcsec: float[source]
z_min_mm: float[source]
z_max_mm: float[source]
corners_local_mm: tuple[tuple[float, float, float], Ellipsis] | None = None[source]
observer_key: str = 'earth'[source]
classmethod from_display_fov(fov: DisplayFovSelection, z_min_mm: float, z_max_mm: float, *, observer_key: str = 'earth') DisplayFovBoxSelection[source]
as_observer_metadata(*, square: bool = False) dict[str, float | str | bool][source]
class pyampp.gxbox.selector_api.SelectorDialogResult[source]

Accepted result returned by the standalone selector dialog.

geometry: BoxGeometrySelection[source]
fov: DisplayFovSelection | None = None[source]
square_fov: bool = False[source]
class pyampp.gxbox.selector_api.GeometrySelectionConsumer[source]

Bases: Protocol

Callback protocol for receiving accepted geometry selections.

apply_geometry_selection(selection: BoxGeometrySelection) None[source]

Apply an accepted geometry selection to the host GUI/application.