gwcs.coordinate_frames._LegacyCoordinateFrameProtocol¶
- class gwcs.coordinate_frames._LegacyCoordinateFrameProtocol(*args, **kwargs)¶
Bases:
ProtocolOriginal API definition for a coordinate frame. This is used for deprecation warnings and to identify when to patch the
is_high_levelmethod to the frame.
Attributes¶
Names describing the axes of the frame. |
|
The position of the axes in the frame in the transform. |
|
An upcase string (or tuple of strings) describing the type of the axis. |
|
The UCD 1+ physical types for the axes, in frame order. |
|
The name of the coordinate frame. |
|
The number of axes described by this frame. |
|
The reference frame of the coordinates described by this frame. |
|
The units of the axes in this frame. |
|
The APE 14 object classes for this frame. |
|
The APE 14 object components for this frame. |
- abstract property _LegacyCoordinateFrameProtocol.axes_names: tuple[str, ...]¶
Names describing the axes of the frame.
- abstract property _LegacyCoordinateFrameProtocol.axes_order: tuple[int, ...]¶
The position of the axes in the frame in the transform.
- abstract property _LegacyCoordinateFrameProtocol.axes_type: AxesType¶
An upcase string (or tuple of strings) describing the type of the axis.
See AxisType for the known values, but you can also use your own custom one.
- abstract property _LegacyCoordinateFrameProtocol.axis_physical_types: tuple[str | None, ...]¶
The UCD 1+ physical types for the axes, in frame order.
- abstract property _LegacyCoordinateFrameProtocol.naxes: int¶
The number of axes described by this frame.
- abstract property _LegacyCoordinateFrameProtocol.reference_frame: AstropyBuiltInFrame | None¶
The reference frame of the coordinates described by this frame.
This is usually an Astropy object such as
SkyCoordorTime.
- abstract property _LegacyCoordinateFrameProtocol.unit: tuple[Unit | None, ...]¶
The units of the axes in this frame.
- abstract property _LegacyCoordinateFrameProtocol.world_axis_object_classes: WorldAxisObjectClasses¶
The APE 14 object classes for this frame.
- abstract property _LegacyCoordinateFrameProtocol.world_axis_object_components: list[WorldAxisObjectComponent]¶
The APE 14 object components for this frame.
Methods¶
|
Add units to the arrays |
|
Convert high level coordinate objects to "values" as described by this frame. |
|
Remove units from the input arrays |
|
Convert "values" to high level coordinate objects described by this frame. |
- _LegacyCoordinateFrameProtocol.add_units(arrays)¶
Add units to the arrays
- Parameters:
arrays (
tuple[LowLevelInput,...] |LowLevelInput)- Return type:
- _LegacyCoordinateFrameProtocol.from_high_level_coordinates(*high_level_coords, correct_1d=True)¶
Convert high level coordinate objects to “values” as described by this frame.
“values” are the coordinates in array or scalar form, and high level objects are things such as
SkyCoordorQuantity. See Shared Python Interface for World Coordinate Systems for details.- Parameters:
high_level_coordinates – One (or more) high level object describing the coordinate.
- Returns:
values –
naxisnumber of coordinates as scalars or arrays.- Return type:
- _LegacyCoordinateFrameProtocol.remove_units(arrays)¶
Remove units from the input arrays
- Parameters:
arrays (
tuple[LowLevelInput,...] |LowLevelInput)- Return type:
- _LegacyCoordinateFrameProtocol.to_high_level_coordinates(*values, correct_1d=True)¶
Convert “values” to high level coordinate objects described by this frame.
“values” are the coordinates in array or scalar form, and high level objects are things such as
SkyCoordorQuantity. See Shared Python Interface for World Coordinate Systems for details.- Parameters:
values (
numbers.Number,numpy.ndarray, orQuantity) –naxisnumber of coordinates as scalars or arrays.- Returns:
high_level_coordinates – One (or more) high level object describing the coordinate.
- Return type: