24 #if !defined(LSST_MEAS_ALGORITHMS_COADDPSF_H)
25 #define LSST_MEAS_ALGORITHMS_COADDPSF_H
28 #include "lsst/base.h"
30 #include "lsst/afw/image/Wcs.h"
31 #include "lsst/afw/table/Exposure.h"
32 #include "lsst/afw/table/types.h"
33 #include "lsst/afw/geom/Box.h"
34 #include "lsst/afw/geom/polygon/Polygon.h"
35 #include "lsst/afw/math/warpExposure.h"
37 namespace lsst {
namespace meas {
namespace algorithms {
64 afw::table::ExposureCatalog
const & catalog,
66 std::string
const & weightFieldName =
"weight",
72 virtual PTR(afw::detection::Psf)
clone()
const;
83 PTR(afw::image::Wcs
const)
getCoaddWcs() {
return _coaddWcs; }
95 CONST_PTR(afw::detection::Psf)
getPsf(
int index);
104 CONST_PTR(afw::image::Wcs)
getWcs(
int index);
122 afw::table::RecordId
getId(
int index);
131 afw::geom::Box2I
getBBox(
int index);
159 afw::geom::Point2D const & ccdXY,
160 afw::image::Color const & color
164 afw::geom::Point2D const & position,
165 afw::image::Color const & color
175 virtual
void write(OutputArchiveHandle & handle) const;
179 afw::table::ExposureCatalog const & catalog,
180 PTR(afw::image::Wcs const) coaddWcs,
188 afw::table::ExposureCatalog _catalog;
189 CONST_PTR(afw::image::Wcs) _coaddWcs;
190 afw::table::Key<
double> _weightKey;
191 afw::geom::Point2D _averagePosition;
192 std::
string _warpingKernelName;
193 CONST_PTR(afw::math::WarpingControl) _warpingControl;
virtual bool isPersistable() const
Return true if the CoaddPsf persistable (always true).
afw::geom::Box2I getBBox(int index)
Get the bounding box (in component image Pixel coordinates) of the component image at index...
double getWeight(int index)
Get the weight of the component image at index.
boost::shared_ptr< afw::image::Wcs const > getWcs(int index)
Get the Wcs of the component image at index.
CoaddPsf(afw::table::ExposureCatalog const &catalog, afw::image::Wcs const &coaddWcs, std::string const &weightFieldName="weight", std::string const &warpingKernelName="lanczos3", int cacheSize=10000)
Main constructors for CoaddPsf.
boost::shared_ptr< afw::detection::Psf::Image > doComputeKernelImage(afw::geom::Point2D const &ccdXY, afw::image::Color const &color) const
tbl::Key< int > cacheSize
boost::shared_ptr< afw::image::Wcs const > getCoaddWcs()
Return the Wcs of the coadd (defines the coordinate system of the Psf).
afw::table::RecordId getId(int index)
Get the exposure ID of the component image at index.
virtual std::string getPersistenceName() const
CoaddPsf is the Psf derived to be used for non-PSF-matched Coadd images.
int getComponentCount() const
Return the number of component Psfs in this CoaddPsf.
tbl::Key< std::string > warpingKernelName
virtual afw::geom::Box2I doComputeBBox(afw::geom::Point2D const &position, afw::image::Color const &color) const
An intermediate base class for Psfs that use an image representation.
virtual void write(OutputArchiveHandle &handle) const
tbl::PointKey< double > averagePosition
virtual std::string getPythonModule() const
virtual afw::geom::Point2D getAveragePosition() const
Return the average of the positions of the stars that went into this Psf.
boost::shared_ptr< afw::detection::Psf const > getPsf(int index)
Get the Psf of the component image at index.
boost::shared_ptr< afw::geom::polygon::Polygon const > getValidPolygon(int index)
Get the validPolygon (in component image Pixel coordinates) of the component image at index...
virtual boost::shared_ptr< afw::detection::Psf > clone() const
Polymorphic deep copy. Usually unnecessary, as Psfs are immutable.