acstools.utils_findsat_mrt.streak_persistence(cutout, dx, streak_y0, streak_stdev, max_width=None, plot_streak=False)

Measure streak persistence across image.

The persistence is measured by breaking the trail into even chunks and trying to fit a Gaussian to a 1D cross-section from each chunk. Successful fits contribute to the persistence score.

  • cutout (ndarray) – Cutout of the trail. This should be the same cutout generated in filter_sources() so that the trail is aligned horizontally across the cutout.

  • dx (int) – Size of each chunk to be analyzed.

  • streak_y0 (float) – y-coordinate of the trail derived from the analysis of its global cross-section.

  • streak_stdev (float) – Gaussian sigma value determined from the analysis of its global cross-section.

  • max_width (int, optional) – Maximum allowed width for a trail to be considered robust. This should be the same as whatever was used in filter_sources(). The default is None.

  • plot_streak (bool, optional) – Set to turn on plotting. WARNING: THIS CAN GENERATE MANY PLOTS DEPENDING ON HOW MANY SECTIONS A TRAIL IS BROKEN INTO. The default is False.


pscore – Persistence score of the input trail.

Return type: