AperturePhotometry#
- class stellarphot.photometry.photometry.AperturePhotometry(*, settings: PhotometrySettings)[source]#
Bases:
BaseModelClass to perform aperture photometry on one or more images
Create a new model by parsing and validating input data from keyword arguments.
Raises [
ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.selfis explicitly positional-only to allowselfas a field name.Attributes Summary
Configuration for the model, should be a dictionary conforming to [
ConfigDict][pydantic.config.ConfigDict].Methods Summary
__call__(file_or_directory, **kwargs)Perform aperture photometry on a single image or a directory of images.
Attributes Documentation
- model_config = {}#
Configuration for the model, should be a dictionary conforming to [
ConfigDict][pydantic.config.ConfigDict].
Methods Documentation
- __call__(file_or_directory: str | Path, **kwargs) PhotometryData[source]#
Perform aperture photometry on a single image or a directory of images.
- Parameters:
- file_or_directorystr or Path
The file or directory on which to perform aperture photometry.
- loglinestr, optional (Default: “single_image_photometry:”)
String to prepend to all log messages, only used for single image photometry.
- reject_unmatchedbool, optional (Default: True)
If
True, any sources that are not detected on all the images are rejected. If you are interested in a source that can intermittently fall below your detection limits, we suggest setting this toFalseso that all sources detected on each image are reported. Only used for multi-image photometry.- object_of_intereststr, optional (Default: None)
Name of the object of interest. The only files on which photometry will be done are those whose header contains the keyword
OBJECTwhose value isobject_of_interest. Only used for multi-image photometry to select which files to perform photometry on.
- Returns:
- photom_data
stellarphot.PhotometryData Photometry data for all the sources on which aperture photometry was performed in all the images. This may be a subset of the sources in the source list if locations were too close to the edge of any one image or to each other for successful aperture photometry.
- photom_data