Skip to content

FourCornerLocalizer does not need flight direction #38

@garydoranjr

Description

@garydoranjr

pdsc/pdsc/localization.py

Lines 359 to 392 in 74893bb

class FourCornerLocalizer(GeodesicLocalizer):
"""
The :py:class:`FourCornerLocalizer` is a type of localizer that is used when
observation locations are described using the latitude and longitude of the
four corners of the observation.
"""
def __init__(self, corners, n_rows, n_cols, flight_direction):
"""
:param corners:
an ordered collection of the four image corners, each a latitude and
east longitude pair (in degrees); the order of the corners is:
- top left
- bottom left
- bottom right
- top right
:param n_rows: the number of rows in the image
:param n_cols: the number of columns in the image
:param flight_direction:
a multiplicative factor indicating the direction of flight relative
to the :math:`y`-direction in pixel space; if
``flight_direction=1``, then the flight direction is from the the
top down, whereas ``flight_direction=-1`` indicates a bottom-up
direction of flight
"""
if n_rows <= 0: raise ValueError('No image rows')
if n_cols <= 0: raise ValueError('No image columns')
self.n_rows = n_rows
self.n_cols = n_cols
self.flight_direction = flight_direction

The flight direction is set for the FourCornerLocalizer, but it is never actually used. It should be removed to simplify the interface.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions