25 #ifndef LSST_AFW_IMAGE_EXPOSURE_H 26 #define LSST_AFW_IMAGE_EXPOSURE_H 84 explicit Exposure(
unsigned int width,
unsigned int height,
109 explicit Exposure(MaskedImageT& maskedImage,
182 bool const deep =
false);
188 template <
typename OtherPixelT>
197 "Exposure's converting copy constructor must make a deep copy");
218 return Exposure(*
this, bbox, origin,
false);
238 return _info->getDetector();
276 return _maskedImage.
getBBox(origin);
295 _info->setDetector(detector);
314 bool hasPsf()
const {
return _info->hasPsf(); }
317 bool hasWcs()
const {
return _info->hasWcs(); }
438 MaskedImageT _maskedImage;
445 template <
typename ImagePixelT,
typename MaskPixelT,
typename VariancePixelT>
458 #endif // LSST_AFW_IMAGE_EXPOSURE_H int getWidth() const
Return the Exposure's width.
void setFilter(Filter const &filter)
Set the Exposure's filter.
afw::table::PointKey< int > dimensions
virtual ~Exposure()
Destructor.
std::shared_ptr< Calib const > getCalib() const
Return the Exposure's Calib object.
void setInfo(std::shared_ptr< ExposureInfo > exposureInfo)
Set the ExposureInfo that aggregates all the non-image components.
int getHeight() const
Return the Exposure's height.
int getY0() const
Return the Exposure's row-origin.
void setCalib(std::shared_ptr< Calib > calib)
Set the Exposure's Calib object.
void setXY0(lsst::geom::Point2I const &origin)
Set the Exposure's origin (including correcting the Wcs)
A class to contain the data, WCS, and other information needed to describe an image of the sky...
Options for writing an image to FITS.
Exposure operator[](lsst::geom::Box2I const &bbox) const
Return a subimage corresponding to the given box (interpreted as PARENT coordinates).
void setWcs(std::shared_ptr< geom::SkyWcs > wcs)
std::shared_ptr< ExposureInfo > getInfo()
Get the ExposureInfo that aggregates all the non-image components. Never null.
void setMetadata(std::shared_ptr< lsst::daf::base::PropertySet > metadata)
lsst::geom::Point2I getXY0() const
Return the Exposure's origin.
A simple struct that combines the two arguments that must be passed to most cfitsio routines and cont...
MaskedImage< ImageT, MaskT, VarianceT > MaskedImageT
lsst::geom::Point2I getXY0() const
Return the image's origin.
lsst::geom::Box2I getBBox(ImageOrigin const origin=PARENT) const
bool hasWcs() const
Does this Exposure have a Wcs?
Exposure subset(lsst::geom::Box2I const &bbox, ImageOrigin origin=PARENT) const
Return a subimage corresponding to the given box.
std::shared_ptr< ExposureInfo const > getInfo() const
Get the ExposureInfo that aggregates all the non-image components. Never null.
static Exposure readFits(fits::MemFileManager &manager)
Read an Exposure from a FITS RAM file.
table::Key< table::Array< std::uint8_t > > wcs
lsst::geom::Extent2I getDimensions() const
std::shared_ptr< Exposure< ImagePixelT, MaskPixelT, VariancePixelT > > makeExposure(MaskedImage< ImagePixelT, MaskPixelT, VariancePixelT > &mimage, std::shared_ptr< geom::SkyWcs const > wcs=std::shared_ptr< geom::SkyWcs const >())
A function to return an Exposure of the correct type (cf.
int getHeight() const
Return the number of rows in the image.
MaskedImageT getMaskedImage() const
Return the MaskedImage.
A base class for image defects.
MaskedImageT getMaskedImage()
Return the MaskedImage.
int getX0() const
Return the Exposure's column-origin.
int getX0() const
Return the image's column-origin.
Lifetime-management for memory that goes into FITS memory files.
std::shared_ptr< lsst::daf::base::PropertySet > getMetadata() const
Return flexible metadata.
Exposure getCutout(lsst::geom::SpherePoint const ¢er, lsst::geom::Extent2I const &size) const
Return an Exposure that is a small cutout of the original.
void setMaskedImage(MaskedImageT &maskedImage)
Set the MaskedImage of the Exposure.
bool hasPsf() const
Does this Exposure have a Psf?
table::Key< int > detector
std::int32_t MaskPixel
default type for Masks and MaskedImage Masks
Holds an integer identifier for an LSST filter.
std::shared_ptr< RecordT > src
int getY0() const
Return the image's row-origin.
std::shared_ptr< Calib > getCalib()
Return the Exposure's Calib object.
#define LSST_EXCEPT(type,...)
Create an exception with a given type.
static Exposure readFits(std::string const &filename)
Read an Exposure from a regular FITS file.
Exposure(Exposure< OtherPixelT, MaskT, VarianceT > const &rhs, const bool deep)
generalised copy constructor; defined here in the header so that the compiler can instantiate N(N-1)/...
Filter getFilter() const
Return the Exposure's filter.
Point in an unspecified spherical coordinate system.
Citizen(const std::type_info &)
Exposure(unsigned int width, unsigned int height, std::shared_ptr< geom::SkyWcs const > wcs=std::shared_ptr< geom::SkyWcs const >())
Construct an Exposure with a blank MaskedImage of specified size (default 0x0) and a SkyWcs (which ma...
std::shared_ptr< lsst::afw::detection::Psf > getPsf()
Return the Exposure's Psf object.
void setDetector(std::shared_ptr< lsst::afw::cameraGeom::Detector const > detector)
Set the Exposure's Detector information.
Reports invalid arguments.
std::shared_ptr< geom::SkyWcs const > getWcs() const
int getWidth() const
Return the number of columns in the image.
lsst::geom::Extent2I getDimensions() const
Return the Exposure's size.
std::shared_ptr< lsst::afw::detection::Psf const > getPsf() const
Return the Exposure's Psf object.
void writeFits(std::string const &fileName) const
Write an Exposure to a regular multi-extension FITS file.
Citizen is a class that should be among all LSST classes base classes, and handles basic memory manag...
void setPsf(std::shared_ptr< lsst::afw::detection::Psf const > psf)
Set the Exposure's Psf.
A collection of all the things that make an Exposure different from a MaskedImage.
float VariancePixel
default type for MaskedImage variance images
lsst::geom::Box2I getBBox(ImageOrigin const origin=PARENT) const
An integer coordinate rectangle.
std::shared_ptr< lsst::afw::cameraGeom::Detector const > getDetector() const
Return the Exposure's Detector information.
Exposure & operator=(Exposure const &)