projection.LambertAzimutal

projection.LambertAzimutal(
    width,
    height,
    center_latitude=90.0,
    center_longitude=0.0,
    radius=None,
    rotation=0.0,
)

Lambert azimuthal equidistant projection with a parametrized center point.

This projection preserves distances and directions from the center point. It maps a hemisphere (or any angular radius) centered on an arbitrary latitude/longitude to a square image.

See: Azimuthal equidistant projection on Wikipedia

Methods

Name Description
get_coordinates Get the latitude and longitude for each pixel in the projection.
is_in_bounds Check if coordinates are within the projection radius.
is_valid_index Check if pixel indexes are valid (not FILL_VALUE).
project_to_indexes Project latitude and longitude coordinates to pixel indexes in the

get_coordinates

projection.LambertAzimutal.get_coordinates()

Get the latitude and longitude for each pixel in the projection.

Returns a meshgrid of coordinates for the entire image. Pixels outside the circular projection area have NaN coordinates.

Returns: tuple[np.ndarray, np.ndarray]: - latitude: 2D array of latitude values for each pixel. - longitude: 2D array of longitude values for each pixel.

is_in_bounds

projection.LambertAzimutal.is_in_bounds(latitude, longitude)

Check if coordinates are within the projection radius.

Args: latitude: Latitude value(s) in degrees. longitude: Longitude value(s) in degrees.

Returns: np.ndarray: Boolean array indicating which coordinates are within the projection radius.

is_valid_index

projection.LambertAzimutal.is_valid_index(x_indexes, y_indexes)

Check if pixel indexes are valid (not FILL_VALUE).

Args: x_indexes: The x pixel indexes to check. y_indexes: The y pixel indexes to check.

Returns: np.ndarray: Boolean array indicating which indexes are valid.

project_to_indexes

projection.LambertAzimutal.project_to_indexes(latitude, longitude)

Project latitude and longitude coordinates to pixel indexes in the azimuthal equidistant projection.

Args: latitude: Latitude value(s) in degrees. longitude: Longitude value(s) in degrees.

Returns: tuple[np.ndarray, np.ndarray]: (x_indexes, y_indexes) — pixel coordinates. Returns (FILL_VALUE, FILL_VALUE) for coordinates outside the projection radius. Check validity with is_valid_index().