Image Cleaning#

Cleaning/denoising of images (tailcuts cleaning, dilation, filtering).

An example of image cleaning and dilation:

../../_images/dilate.png

API Reference#

ctapipe.image.cleaning Module#

Image Cleaning Algorithms (identification of noisy pixels)

All algorithms return a boolean mask that is True for pixels surviving the cleaning.

To get a zero-suppressed image and pixel list, use image[mask], geom.pix_id[mask], or to keep the same image size and just set unclean pixels to 0 or similar, use image[~mask] = 0

Functions#

tailcuts_clean(geom, image[, ...])

Clean an image by selection pixels that pass a two-threshold tail-cuts procedure.

bright_cleaning(image, threshold, fraction)

Clean an image by removing pixels below a fraction of the mean charge in the n_pixels brightest pixels.

dilate(geom, mask)

Add one row of neighbors to the true values of a pixel mask and return the new mask.

mars_cleaning_1st_pass(geom, image[, ...])

Clean an image by selecting pixels that pass a three-threshold tail-cuts procedure.

fact_image_cleaning(geom, image, arrival_times)

Clean an image by selection pixels that pass the fact cleaning procedure.

apply_time_delta_cleaning(geom, mask, ...)

Identify all pixels from selection that have less than N neighbors that arrived within a given timeframe.

apply_time_average_cleaning(geom, mask, ...)

Extract all pixels that arrived within a given timeframe with respect to the time average of the pixels on the main island.

time_constrained_clean(geom, image, ...[, ...])

Time constrained cleaning by MAGIC

nsb_image_cleaning(geom, image, arrival_times)

Clean an image in 5 Steps:

Classes#

ImageCleaner(**kwargs)

Abstract class for all configurable Image Cleaning algorithms.

TailcutsImageCleaner(**kwargs)

Clean images using the standard picture/boundary technique.

NSBImageCleaner(**kwargs)

Clean images based on lstchains image cleaning technique described in [LST23].

MARSImageCleaner(**kwargs)

1st-pass MARS-like Image cleaner (See ctapipe.image.mars_cleaning_1st_pass)

FACTImageCleaner(**kwargs)

Clean images using the FACT technique.

TimeConstrainedImageCleaner(**kwargs)

MAGIC-like Image cleaner with timing information (See ctapipe.image.time_constrained_clean).

Class Inheritance Diagram#

Inheritance diagram of ctapipe.image.cleaning.ImageCleaner, ctapipe.image.cleaning.TailcutsImageCleaner, ctapipe.image.cleaning.NSBImageCleaner, ctapipe.image.cleaning.MARSImageCleaner, ctapipe.image.cleaning.FACTImageCleaner, ctapipe.image.cleaning.TimeConstrainedImageCleaner