Skip to main content

fovea

Fovea landmark extraction, shared between step packages.

Lives here rather than in a step package so that neither the GA step nor the lesion step depends on the other. ga_calculation_with_fovea re-exports it to keep its own import path working.

Module

Functions

get_central_slice_landmark_point

def get_central_slice_landmark_point(    central_slice: int | None,    landmarks_list: FoveaLandmarks | None,    landmark_idx: int = 2,)> numpy.ndarray[typing.Any, numpy.dtype[typing.Any]] | None:

Get the central slice middle point from the fovea prediction.

Arguments

  • central_slice: Central slice of the fovea prediction.
  • landmarks_list: List of 3-element lists of landmarks (slice, x, y).
  • landmark_idx: Index of the middle landmark in the tuple.

Returns Numpy array of the middle point of the central slice, or None.