mirar.processors.photcal package

Photometric calibration processor

Subpackages

Submodules

mirar.processors.photcal.photcal_errors module

Photometric calibration errors

exception mirar.processors.photcal.photcal_errors.PhotometryCalculationError[source]

Bases: PhotometryError

Error related to the photometric calibration

exception mirar.processors.photcal.photcal_errors.PhotometryCrossMatchError[source]

Bases: PhotometryError

Error related to cross-matching photometric reference and source catalogues

exception mirar.processors.photcal.photcal_errors.PhotometryError[source]

Bases: ProcessorError

Base error for photometric calibration

exception mirar.processors.photcal.photcal_errors.PhotometryReferenceError[source]

Bases: PhotometryError

Error related to the photometric reference catalogue

exception mirar.processors.photcal.photcal_errors.PhotometrySourceError[source]

Bases: PhotometryError

Error related to the photometric source catalogue

mirar.processors.photcal.photcalibrator module

Module for running photometric calibration

class mirar.processors.photcal.photcalibrator.ImageBatchReferenceCatalogDownloader(ref_catalog_generator: Callable[[Image], BaseCatalog], temp_output_sub_dir: str = 'phot', ref_cat_header_key: str = 'RFCTPATH')[source]

Bases: BaseImageProcessor

Base processor for downloading a reference catalog for an imagebatch and save it to a specified location.

base_key = 'imagebatchrefcatdownloader'
description() str[source]

Return a description of the processor

Returns:

A description of the processor

get_output_dir()[source]

Return the :return:

class mirar.processors.photcal.photcalibrator.PhotCalibrator(ref_catalog_generator: ~collections.abc.Callable[[~mirar.data.image_data.Image], ~mirar.catalog.base.base_catalog.BaseCatalog], temp_output_sub_dir: str = 'phot', catalogs_purifier: ~collections.abc.Callable[[~astropy.table.table.Table, ~astropy.table.table.Table, ~mirar.data.image_data.Image], [<class 'astropy.table.table.Table'>, <class 'astropy.table.table.Table'>]] = <function default_image_sextractor_catalog_purifier>, num_matches_threshold: int = 5, crossmatch_radius_arcsec: float = 1.0, write_regions: bool = False, cache: bool = False, zp_calculator: ~mirar.processors.photcal.zp_calculator.base_zp_calculator.BaseZeroPointCalculator = <mirar.processors.photcal.zp_calculator.outlier_rejection_zp_calculator.OutlierRejectionZPCalculator object>, zp_column_name: str = 'MAG_AUTO')[source]

Bases: BaseProcessorWithCrossMatch

Photometric calibrator processor

Attributes:

num_matches_threshold: minimum number of matches required for photometric calibration for outlier rejection. If a ist is provided, the list is sorted and stepped through in order with increasing thresholds until the specified number of matches is reached. zp_calculator: Zero point calculator object zp_column_name: Name of the column in the photometric catalog that will be used to assign the value of “ZP_KEY” in the header of the output image. Default is “MAG_AUTO”

base_key = 'photcalibrator'
description() str[source]

Return a description of the processor

Returns:

A description of the processor

get_phot_output_dir()[source]

Return the :return:

mirar.processors.photcal.photcalibrator.get_maglim(bkg_rms_image_path: str | Path, zeropoint: float | list[float], aperture_radius_pixels: float | list[float]) float[source]

Function to calculate limiting magnitude Args:

bkg_rms_image_path: zeropoint: aperture_radius_pixels:

Returns: