lsst.afw  14.0-27-gbdf48f848+1
Public Member Functions | Static Public Member Functions | Protected Types | Protected Member Functions | Friends | List of all members
lsst::afw::image::PhotoCalib Class Reference

The photometric calibration of an exposure. More...

#include <PhotoCalib.h>

Inheritance diagram for lsst::afw::image::PhotoCalib:
lsst::afw::table::io::PersistableFacade< PhotoCalib > lsst::afw::table::io::Persistable

Public Member Functions

 PhotoCalib (PhotoCalib const &)=delete
 
 PhotoCalib (PhotoCalib &&)=delete
 
PhotoCalib & operator= (PhotoCalib const &)=delete
 
PhotoCalib & operator= (PhotoCalib &&)=delete
 
 PhotoCalib ()
 Create a empty, zeroed calibration. More...
 
 PhotoCalib (double calibrationMean, double calibrationErr=0, afw::geom::Box2I const &bbox=afw::geom::Box2I())
 Create a non-spatially-varying calibration. More...
 
 PhotoCalib (std::shared_ptr< afw::math::BoundedField > calibration, double calibrationErr=0)
 Create a spatially-varying calibration. More...
 
 PhotoCalib (double calibrationMean, double calibrationErr, std::shared_ptr< afw::math::BoundedField > calibration, bool isConstant)
 Create a calibration with a pre-computed mean. More...
 
double instFluxToMaggies (double instFlux, afw::geom::Point< double, 2 > const &point) const
 Convert instFlux in ADU to maggies at a point in the BoundedField. More...
 
double instFluxToMaggies (double instFlux) const
 
Measurement instFluxToMaggies (double instFlux, double instFluxErr, afw::geom::Point< double, 2 > const &point) const
 Convert instFlux and error in instFlux (ADU) to maggies and maggies error. More...
 
Measurement instFluxToMaggies (double instFlux, double instFluxErr) const
 
Measurement instFluxToMaggies (const afw::table::SourceRecord &sourceRecord, std::string const &instFluxField) const
 Convert sourceRecord[instFluxField_instFlux] (ADU) at location (sourceRecord.get("x"), sourceRecord.get("y")) (pixels) to maggies and maggie error. More...
 
ndarray::Array< double, 2, 2 > instFluxToMaggies (afw::table::SourceCatalog const &sourceCatalog, std::string const &instFluxField) const
 Convert sourceCatalog[instFluxField_instFlux] (ADU) at locations (sourceCatalog.get("x"), sourceCatalog.get("y")) (pixels) to maggies. More...
 
void instFluxToMaggies (afw::table::SourceCatalog &sourceCatalog, std::string const &instFluxField, std::string const &outField) const
 Convert sourceCatalog[instFluxField_instFlux] (ADU) at locations (sourceCatalog.get("x"), sourceCatalog.get("y")) (pixels) to maggies and write the results back to sourceCatalog[outField_mag]. More...
 
double instFluxToMagnitude (double instFlux, afw::geom::Point< double, 2 > const &point) const
 Convert instFlux in ADU to AB magnitude. More...
 
double instFluxToMagnitude (double instFlux) const
 
Measurement instFluxToMagnitude (double instFlux, double instFluxErr, afw::geom::Point< double, 2 > const &point) const
 Convert instFlux and error in instFlux (ADU) to AB magnitude and magnitude error. More...
 
Measurement instFluxToMagnitude (double instFlux, double instFluxErr) const
 
Measurement instFluxToMagnitude (afw::table::SourceRecord const &sourceRecord, std::string const &instFluxField) const
 Convert sourceRecord[instFluxField_instFlux] (ADU) at location (sourceRecord.get("x"), sourceRecord.get("y")) (pixels) to AB magnitude. More...
 
ndarray::Array< double, 2, 2 > instFluxToMagnitude (afw::table::SourceCatalog const &sourceCatalog, std::string const &instFluxField) const
 Convert sourceCatalog[instFluxField_instFlux] (ADU) at locations (sourceCatalog.get("x"), sourceCatalog.get("y")) (pixels) to AB magnitudes. More...
 
void instFluxToMagnitude (afw::table::SourceCatalog &sourceCatalog, std::string const &instFluxField, std::string const &outField) const
 Convert instFluxes in a catalog to AB magnitudes and write back into the catalog. More...
 
double magnitudeToInstFlux (double magnitude) const
 Convert AB magnitude to instFlux (ADU), using the mean instFlux/magnitude scaling factor. More...
 
double getCalibrationMean () const
 Get the mean photometric calibration (equal to 1 / getInstFluxMag0()). More...
 
double getCalibrationErr () const
 Get the mean photometric calibration error. More...
 
double getInstFluxMag0 () const
 Get the magnitude zero point (equal to 1 / mean(calibration)). More...
 
std::shared_ptr< afw::math::BoundedField > computeScaledCalibration () const
 Calculates the spatially-variable calibration, normalized by the mean in the valid domain. More...
 
std::shared_ptr< afw::math::BoundedField > computeScalingTo (std::shared_ptr< PhotoCalib > other) const
 Calculates the scaling between this PhotoCalib and another PhotoCalib. More...
 
bool operator== (PhotoCalib const &rhs) const
 Two PhotoCalibs are equal if their component bounded fields and calibrationErr are equal. More...
 
bool operator!= (PhotoCalib const &rhs) const
 Two PhotoCalibs are equal if their component bounded fields and calibrationErr are equal. More...
 
bool isPersistable () const
 Return true if this particular object can be persisted using afw::table::io. More...
 
void writeFits (std::string const &fileName, std::string const &mode="w") const
 Write the object to a regular FITS file. More...
 
void writeFits (fits::MemFileManager &manager, std::string const &mode="w") const
 Write the object to a FITS image in memory. More...
 
void writeFits (fits::Fits &fitsfile) const
 Write the object to an already-open FITS object. More...
 

Static Public Member Functions

static std::shared_ptr< PhotoCalib > readFits (fits::Fits &fitsfile)
 Read an object from an already open FITS object. More...
 
static std::shared_ptr< PhotoCalib > readFits (std::string const &fileName, int hdu=INT_MIN)
 Read an object from a regular FITS file. More...
 
static std::shared_ptr< PhotoCalib > readFits (fits::MemFileManager &manager, int hdu=INT_MIN)
 Read an object from a FITS file in memory. More...
 

Protected Types

typedef io::OutputArchiveHandle OutputArchiveHandle
 

Protected Member Functions

virtual std::string getPersistenceName () const
 Return the unique name used to persist this object and look up its factory. More...
 
virtual void write (OutputArchiveHandle &handle) const
 Write the object to one or more catalogs. More...
 
virtual std::string getPythonModule () const
 Return the fully-qualified Python module that should be imported to guarantee that its factory is registered. More...
 

Friends

std::ostream & operator<< (std::ostream &os, PhotoCalib const &photoCalib)
 

Detailed Description

The photometric calibration of an exposure.

A PhotoCalib is a BoundedField (a function with a specified domain) that converts from post-ISR counts-on-chip (ADU) to flux and magnitude. It is defined in terms of "maggies", which are a linear unit defined in SDSS (definition given in nanomaggies): http://www.sdss.org/dr12/algorithms/magnitudes/#nmgy

PhotoCalib is immutable.

The spatially varying flux calibration has units of maggies/ADU, and is defined such that, at a position (x,y) in the domain of the boundedField calibration and for a given measured source instFlux:

\[ instFlux*calibration(x,y) = flux [maggies] \]

while the errors (constant on the domain) are defined as:

\[ sqrt((instFluxErr/instFlux)^2 + (calibrationErr/calibration)^2)*flux = fluxErr [maggies] \]

This implies that the conversions from instFlux and instFlux error to magnitude and magnitude error are as follows:

\[ -2.5*log_{10}(instFlux*calibration(x,y)) = magnitude \]

and

\[ 2.5/log(10)*sqrt((instFluxErr/instFlux)^2 + (calibrationErr/calibration)^2) = magnitudeErr \]

Definition at line 81 of file PhotoCalib.h.

Member Typedef Documentation

◆ OutputArchiveHandle

typedef io::OutputArchiveHandle lsst::afw::table::io::Persistable::OutputArchiveHandle
protectedinherited

Definition at line 107 of file Persistable.h.

Constructor & Destructor Documentation

◆ PhotoCalib() [1/6]

lsst::afw::image::PhotoCalib::PhotoCalib ( PhotoCalib const &  )
delete

◆ PhotoCalib() [2/6]

lsst::afw::image::PhotoCalib::PhotoCalib ( PhotoCalib &&  )
delete

◆ PhotoCalib() [3/6]

lsst::afw::image::PhotoCalib::PhotoCalib ( )
inline

Create a empty, zeroed calibration.

Definition at line 92 of file PhotoCalib.h.

◆ PhotoCalib() [4/6]

lsst::afw::image::PhotoCalib::PhotoCalib ( double  calibrationMean,
double  calibrationErr = 0,
afw::geom::Box2I const &  bbox = afw::geom::Box2I() 
)
inlineexplicit

Create a non-spatially-varying calibration.

Parameters
[in]calibrationMeanThe spatially-constant calibration.
[in]calibrationErrThe error on the calibration.
[in]bboxThe bounding box on which this PhotoCalib is valid. If not specified, this PhotoCalib is valid at any point (i.e. an empty bbox).

Definition at line 102 of file PhotoCalib.h.

◆ PhotoCalib() [5/6]

lsst::afw::image::PhotoCalib::PhotoCalib ( std::shared_ptr< afw::math::BoundedField >  calibration,
double  calibrationErr = 0 
)
inline

Create a spatially-varying calibration.

Parameters
[in]calibrationThe spatially varying photometric calibration.
[in]calibrationErrThe error on the calibration.

Definition at line 117 of file PhotoCalib.h.

◆ PhotoCalib() [6/6]

lsst::afw::image::PhotoCalib::PhotoCalib ( double  calibrationMean,
double  calibrationErr,
std::shared_ptr< afw::math::BoundedField >  calibration,
bool  isConstant 
)
inline

Create a calibration with a pre-computed mean.

Primarily for de-persistence.

Parameters
[in]calibrationMeanThe mean of the calibration() over its bounding box.
[in]calibrationThe spatially varying photometric calibration.
[in]calibrationErrThe error on the calibration.
[in]isConstantIs this PhotoCalib spatially constant?

Definition at line 131 of file PhotoCalib.h.

Member Function Documentation

◆ computeScaledCalibration()

std::shared_ptr< math::BoundedField > lsst::afw::image::PhotoCalib::computeScaledCalibration ( ) const

Calculates the spatially-variable calibration, normalized by the mean in the valid domain.

This value is defined, for instFlux at (x,y), such that:

\[ instFlux*computeScaledCalibration()(x,y)*getCalibrationMean() = instFluxToMaggies(instFlux, (x,y)) \]

See also
PhotoCalib::getCalibrationMean()
Returns
The normalized spatially-variable calibration.

Definition at line 182 of file PhotoCalib.cc.

◆ computeScalingTo()

std::shared_ptr< math::BoundedField > lsst::afw::image::PhotoCalib::computeScalingTo ( std::shared_ptr< PhotoCalib >  other) const

Calculates the scaling between this PhotoCalib and another PhotoCalib.

The BoundedFields of these PhotoCalibs must have the same BBoxes (or one or both must be empty).

With:

  • c = instFlux at position (x,y)
  • this = this PhotoCalib
  • other = other PhotoCalib
  • return = BoundedField returned by this method the return value from this method is defined as:

    \[ this.instFluxToMaggies(c, (x,y))*return(x, y) = other.instFluxToMaggies(c, (x,y)) \]

Parameters
[in]otherThe PhotoCalib to scale to.
Returns
The BoundedField as defined above.
Warning
Not implemented yet: See DM-10154.

Definition at line 186 of file PhotoCalib.cc.

◆ getCalibrationErr()

double lsst::afw::image::PhotoCalib::getCalibrationErr ( ) const
inline

Get the mean photometric calibration error.

This value is defined such that for some instFluxErr, instFlux, and flux:

\[ sqrt((instFluxErr/instFlux)^2 + (calibrationErr/calibration(x,y))^2)*flux = fluxErr (in maggies) \]

See also
PhotoCalib::computeScaledCalibration(), getCalibrationMean()
Returns
The calibration error.

Definition at line 337 of file PhotoCalib.h.

◆ getCalibrationMean()

double lsst::afw::image::PhotoCalib::getCalibrationMean ( ) const
inline

Get the mean photometric calibration (equal to 1 / getInstFluxMag0()).

This value is defined, for instFlux at (x,y), such that:

\[ instFlux*computeScaledCalibration()(x,y)*getCalibrationMean() = instFluxToMaggies(instFlux, (x,y)) \]

See also
PhotoCalib::computeScaledCalibration(), getCalibrationErr(), getInstFluxMag0()
Returns
The spatial mean of this calibration.

Definition at line 323 of file PhotoCalib.h.

◆ getInstFluxMag0()

double lsst::afw::image::PhotoCalib::getInstFluxMag0 ( ) const
inline

Get the magnitude zero point (equal to 1 / mean(calibration)).

This value is defined, for instFlux at (x,y), such that:

\[ instFlux*computeScaledCalibration()(x,y)/getInstFluxMag0() = instFluxToMaggies(instFlux, (x,y)) \]

See also
PhotoCalib::computeScaledCalibration(), getCalibrationMean()
Returns
The instFlux magnitude zero point.

Definition at line 351 of file PhotoCalib.h.

◆ getPersistenceName()

std::string lsst::afw::image::PhotoCalib::getPersistenceName ( ) const
protectedvirtual

Return the unique name used to persist this object and look up its factory.

Must be less than ArchiveIndexSchema::MAX_NAME_LENGTH characters.

Reimplemented from lsst::afw::table::io::Persistable.

Definition at line 264 of file PhotoCalib.cc.

◆ getPythonModule()

virtual std::string lsst::afw::table::io::Persistable::getPythonModule ( ) const
protectedvirtualinherited

Return the fully-qualified Python module that should be imported to guarantee that its factory is registered.

Must be less than ArchiveIndexSchema::MAX_MODULE_LENGTH characters.

Will be ignored if empty.

Reimplemented in lsst::afw::math::Kernel, lsst::afw::geom::SkyWcs, lsst::afw::image::Wcs, lsst::afw::detection::Footprint, lsst::afw::math::ChebyshevBoundedField, lsst::afw::math::Function< ReturnT >, lsst::afw::math::Function< Kernel::Pixel >, lsst::afw::math::TransformBoundedField, lsst::afw::detection::GaussianPsf, and lsst::afw::image::CoaddInputs.

◆ instFluxToMaggies() [1/7]

double lsst::afw::image::PhotoCalib::instFluxToMaggies ( double  instFlux,
afw::geom::Point< double, 2 > const &  point 
) const

Convert instFlux in ADU to maggies at a point in the BoundedField.

If passed point, use the exact calculation at that point, otherwise, use the mean scaling factor.

Parameters
[in]instFluxThe source instFlux in ADU.
[in]pointThe point that instFlux is measured at.
Returns
The flux in maggies.

Definition at line 59 of file PhotoCalib.cc.

◆ instFluxToMaggies() [2/7]

double lsst::afw::image::PhotoCalib::instFluxToMaggies ( double  instFlux) const

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Definition at line 66 of file PhotoCalib.cc.

◆ instFluxToMaggies() [3/7]

Measurement lsst::afw::image::PhotoCalib::instFluxToMaggies ( double  instFlux,
double  instFluxErr,
afw::geom::Point< double, 2 > const &  point 
) const

Convert instFlux and error in instFlux (ADU) to maggies and maggies error.

If passed point, use the exact calculation at that point, otherwise, use the mean scaling factor.

Parameters
[in]instFluxThe source fluxinstFlux in ADU.
[in]instFluxErrThe instFlux error.
[in]pointThe point that instFlux is measured at.
Returns
The flux in maggies and error.

Definition at line 68 of file PhotoCalib.cc.

◆ instFluxToMaggies() [4/7]

Measurement lsst::afw::image::PhotoCalib::instFluxToMaggies ( double  instFlux,
double  instFluxErr 
) const

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Definition at line 80 of file PhotoCalib.cc.

◆ instFluxToMaggies() [5/7]

Measurement lsst::afw::image::PhotoCalib::instFluxToMaggies ( const afw::table::SourceRecord &  sourceRecord,
std::string const &  instFluxField 
) const

Convert sourceRecord[instFluxField_instFlux] (ADU) at location (sourceRecord.get("x"), sourceRecord.get("y")) (pixels) to maggies and maggie error.

Parameters
[in]sourceRecordThe source record to get instFlux and position from.
[in]instFluxFieldThe instFlux field: Keys of the form "*_flux" and "*_fluxSigma" must exist. For example: instFluxField = "PsfFlux" -> "PsfFlux_flux", "PsfFlux_fluxSigma"
Returns
The flux in maggies and error for this source.

Definition at line 86 of file PhotoCalib.cc.

◆ instFluxToMaggies() [6/7]

ndarray::Array< double, 2, 2 > lsst::afw::image::PhotoCalib::instFluxToMaggies ( afw::table::SourceCatalog const &  sourceCatalog,
std::string const &  instFluxField 
) const

Convert sourceCatalog[instFluxField_instFlux] (ADU) at locations (sourceCatalog.get("x"), sourceCatalog.get("y")) (pixels) to maggies.

Parameters
[in]sourceCatalogThe source catalog to get instFlux and position from.
[in]instFluxFieldThe instFlux field: Keys of the form "*_flux" and "*_fluxSigma" must exist. For example: instFluxField = "PsfFlux" -> "PsfFlux_flux", "PsfFlux_fluxSigma"
Returns
The flux in maggies and error for this source.

Definition at line 93 of file PhotoCalib.cc.

◆ instFluxToMaggies() [7/7]

void lsst::afw::image::PhotoCalib::instFluxToMaggies ( afw::table::SourceCatalog &  sourceCatalog,
std::string const &  instFluxField,
std::string const &  outField 
) const

Convert sourceCatalog[instFluxField_instFlux] (ADU) at locations (sourceCatalog.get("x"), sourceCatalog.get("y")) (pixels) to maggies and write the results back to sourceCatalog[outField_mag].

Parameters
[in]sourceCatalogThe source catalog to get instFlux and position from.
[in]instFluxFieldThe instFlux field: Keys of the form "*_flux" and "*_fluxSigma" must exist. For example: instFluxField = "PsfFlux" -> "PsfFlux_flux", "PsfFlux_fluxSigma"
[in]outFieldThe field to write the maggies and maggie errors to. Keys of the form "*_flux" and "*_fluxSigma" must exist in the schema.
Warning
Not implemented yet: See DM-10155.

Definition at line 101 of file PhotoCalib.cc.

◆ instFluxToMagnitude() [1/7]

double lsst::afw::image::PhotoCalib::instFluxToMagnitude ( double  instFlux,
afw::geom::Point< double, 2 > const &  point 
) const

Convert instFlux in ADU to AB magnitude.

If passed point, use the exact calculation at that point, otherwise, use the mean scaling factor.

Parameters
[in]instFluxThe source instFlux in ADU.
[in]pointThe point that instFlux is measured at.
Returns
The AB magnitude.

Definition at line 117 of file PhotoCalib.cc.

◆ instFluxToMagnitude() [2/7]

double lsst::afw::image::PhotoCalib::instFluxToMagnitude ( double  instFlux) const

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Definition at line 124 of file PhotoCalib.cc.

◆ instFluxToMagnitude() [3/7]

Measurement lsst::afw::image::PhotoCalib::instFluxToMagnitude ( double  instFlux,
double  instFluxErr,
afw::geom::Point< double, 2 > const &  point 
) const

Convert instFlux and error in instFlux (ADU) to AB magnitude and magnitude error.

If passed point, use the exact calculation at that point, otherwise, use the mean scaling factor.

Parameters
[in]instFluxThe source instFlux in ADU.
[in]instFluxErrThe instFlux error (standard deviation).
[in]pointThe point that instFlux is measured at.
Returns
The AB magnitude and error.

Definition at line 128 of file PhotoCalib.cc.

◆ instFluxToMagnitude() [4/7]

Measurement lsst::afw::image::PhotoCalib::instFluxToMagnitude ( double  instFlux,
double  instFluxErr 
) const

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Definition at line 140 of file PhotoCalib.cc.

◆ instFluxToMagnitude() [5/7]

Measurement lsst::afw::image::PhotoCalib::instFluxToMagnitude ( afw::table::SourceRecord const &  sourceRecord,
std::string const &  instFluxField 
) const

Convert sourceRecord[instFluxField_instFlux] (ADU) at location (sourceRecord.get("x"), sourceRecord.get("y")) (pixels) to AB magnitude.

Parameters
[in]sourceRecordThe source record to get instFlux and position from.
[in]instFluxFieldThe instFlux field: Keys of the form "*_flux" and "*_fluxSigma" must exist. For example: instFluxField = "PsfFlux" -> "PsfFlux_instFlux", "PsfFlux_fluxSigma"
Returns
The magnitude and magnitude error for this source.

Definition at line 146 of file PhotoCalib.cc.

◆ instFluxToMagnitude() [6/7]

ndarray::Array< double, 2, 2 > lsst::afw::image::PhotoCalib::instFluxToMagnitude ( afw::table::SourceCatalog const &  sourceCatalog,
std::string const &  instFluxField 
) const

Convert sourceCatalog[instFluxField_instFlux] (ADU) at locations (sourceCatalog.get("x"), sourceCatalog.get("y")) (pixels) to AB magnitudes.

Parameters
[in]sourceCatalogThe source catalog to get instFlux and position from.
[in]instFluxFieldThe instFlux field: Keys of the form "*_flux" and "*_fluxSigma" must exist. For example: instFluxField = "PsfFlux" -> "PsfFlux_instFlux", "PsfFlux_fluxSigma"
Returns
The magnitudes and magnitude errors for the sources.

Definition at line 154 of file PhotoCalib.cc.

◆ instFluxToMagnitude() [7/7]

void lsst::afw::image::PhotoCalib::instFluxToMagnitude ( afw::table::SourceCatalog &  sourceCatalog,
std::string const &  instFluxField,
std::string const &  outField 
) const

Convert instFluxes in a catalog to AB magnitudes and write back into the catalog.

Convert sourceCatalog[instFluxField_instFlux] (ADU) at locations (sourceCatalog.get("x"), sourceCatalog.get("y")) (pixels) to AB magnitudes and write the results back to sourceCatalog[outField_mag].

Parameters
[in]sourceCatalogThe source catalog to get instFlux and position from.
[in]instFluxFieldThe instFlux field: Keys of the form "*_flux" and "*_fluxSigma" must exist. For example: instFluxField = "PsfFlux" -> "PsfFlux_instFlux", "PsfFlux_fluxSigma"
[in]outFieldThe field to write the magnitudes and magnitude errors to. Keys of the form "*_flux", "*_fluxSigma", *_mag", and "*_magErr" must exist in the schema.
Warning
Not implemented yet: See DM-10155.

Definition at line 162 of file PhotoCalib.cc.

◆ isPersistable()

bool lsst::afw::image::PhotoCalib::isPersistable ( ) const
inlinevirtual

Return true if this particular object can be persisted using afw::table::io.

Reimplemented from lsst::afw::table::io::Persistable.

Definition at line 397 of file PhotoCalib.h.

◆ magnitudeToInstFlux()

double lsst::afw::image::PhotoCalib::magnitudeToInstFlux ( double  magnitude) const

Convert AB magnitude to instFlux (ADU), using the mean instFlux/magnitude scaling factor.

Parameters
[in]magnitudeThe AB magnitude to convert.
Returns
Source instFlux in ADU.

Definition at line 178 of file PhotoCalib.cc.

◆ operator!=()

bool lsst::afw::image::PhotoCalib::operator!= ( PhotoCalib const &  rhs) const
inline

Two PhotoCalibs are equal if their component bounded fields and calibrationErr are equal.

Definition at line 395 of file PhotoCalib.h.

◆ operator=() [1/2]

PhotoCalib& lsst::afw::image::PhotoCalib::operator= ( PhotoCalib const &  )
delete

◆ operator=() [2/2]

PhotoCalib& lsst::afw::image::PhotoCalib::operator= ( PhotoCalib &&  )
delete

◆ operator==()

bool lsst::afw::image::PhotoCalib::operator== ( PhotoCalib const &  rhs) const

Two PhotoCalibs are equal if their component bounded fields and calibrationErr are equal.

Definition at line 190 of file PhotoCalib.cc.

◆ readFits() [1/3]

static std::shared_ptr<PhotoCalib > lsst::afw::table::io::PersistableFacade< PhotoCalib >::readFits ( fits::Fits &  fitsfile)
inlinestaticinherited

Read an object from an already open FITS object.

Parameters
[in]fitsfileFITS object to read from, already positioned at the desired HDU.

Definition at line 180 of file Persistable.h.

◆ readFits() [2/3]

static std::shared_ptr<PhotoCalib > lsst::afw::table::io::PersistableFacade< PhotoCalib >::readFits ( std::string const &  fileName,
int  hdu = INT_MIN 
)
inlinestaticinherited

Read an object from a regular FITS file.

Parameters
[in]fileNameName of the file to read.
[in]hduHDU to read, where 0 is the primary. The special value of INT_MIN skips the primary HDU if it is empty.

Definition at line 191 of file Persistable.h.

◆ readFits() [3/3]

static std::shared_ptr<PhotoCalib > lsst::afw::table::io::PersistableFacade< PhotoCalib >::readFits ( fits::MemFileManager &  manager,
int  hdu = INT_MIN 
)
inlinestaticinherited

Read an object from a FITS file in memory.

Parameters
[in]managerManager for the memory to read from.
[in]hduHDU to read, where 0 is the primary. The special value of INT_MIN skips the primary HDU if it is empty.

Definition at line 202 of file Persistable.h.

◆ write()

void lsst::afw::image::PhotoCalib::write ( OutputArchiveHandle &  handle) const
protectedvirtual

Write the object to one or more catalogs.

The handle object passed to this function provides an interface for adding new catalogs and adding nested objects to the same archive (while checking for duplicates). See OutputArchiveHandle for more information.

Reimplemented from lsst::afw::table::io::Persistable.

Definition at line 266 of file PhotoCalib.cc.

◆ writeFits() [1/3]

void lsst::afw::table::io::Persistable::writeFits ( std::string const &  fileName,
std::string const &  mode = "w" 
) const
inherited

Write the object to a regular FITS file.

Parameters
[in]fileNameName of the file to write to.
[in]modeIf "w", any existing file with the given name will be overwritten. If "a", new HDUs will be appended to an existing file.

◆ writeFits() [2/3]

void lsst::afw::table::io::Persistable::writeFits ( fits::MemFileManager &  manager,
std::string const &  mode = "w" 
) const
inherited

Write the object to a FITS image in memory.

Parameters
[in]managerName of the file to write to.
[in]modeIf "w", any existing file with the given name will be overwritten. If "a", new HDUs will be appended to an existing file.

◆ writeFits() [3/3]

void lsst::afw::table::io::Persistable::writeFits ( fits::Fits &  fitsfile) const
inherited

Write the object to an already-open FITS object.

Parameters
[in]fitsfileOpen FITS object to write to.

Friends And Related Function Documentation

◆ operator<<

std::ostream& operator<< ( std::ostream &  os,
PhotoCalib const &  photoCalib 
)
friend

Definition at line 199 of file PhotoCalib.cc.


The documentation for this class was generated from the following files: