23 #ifndef LSST_AFW_DETECTION_Psf_h_INCLUDED
24 #define LSST_AFW_DETECTION_Psf_h_INCLUDED
29 #include "boost/shared_ptr.hpp"
37 namespace lsst {
namespace afw {
namespace detection {
72 return geom::Point2D(std::numeric_limits<double>::quiet_NaN());
75 typedef boost::shared_ptr<Psf>
Ptr;
150 geom::
Point2D position=makeNullPoint(),
167 geom::
Point2D position=makeNullPoint(),
184 geom::
Point2D position=makeNullPoint(),
199 geom::
Point2D position=makeNullPoint(),
210 geom::
Point2D position=makeNullPoint(),
248 geom::
Point2D const & position,
249 std::
string const & warpAlgorithm = "lanczos5",
250 unsigned int warpBuffer = 5
261 explicit
Psf(
bool isFixed=false);
274 geom::
Point2D const & position,
image::Color const& color
277 geom::
Point2D const & position,
image::Color const & color
280 double radius, geom::
Point2D const & position,
image::Color const & color
283 geom::
Point2D const & position,
image::Color const & color
300 #endif // !LSST_AFW_DETECTION_Psf_h_INCLUDED
virtual geom::Point2D getAveragePosition() const
Return the average position of the stars used to construct the Psf.
geom::ellipses::Quadrupole computeShape(geom::Point2D position=makeNullPoint(), image::Color color=image::Color()) const
Compute the ellipse corresponding to the second moments of the Psf.
Declare the Kernel class and subclasses.
boost::shared_ptr< math::Kernel const > getLocalKernel(geom::Point2D position=makeNullPoint(), image::Color color=image::Color()) const
Return a FixedKernel corresponding to the Psf image at the given point.
geom::Point2D _cachedKernelImagePosition
image::Color getAverageColor() const
Return the average Color of the stars used to construct the Psf.
boost::shared_ptr< Image > _cachedKernelImage
static geom::Point2D makeNullPoint()
boost::shared_ptr< Image > computeKernelImage(geom::Point2D position=makeNullPoint(), image::Color color=image::Color(), ImageOwnerEnum owner=COPY) const
Return an Image of the PSF, in a form suitable for convolution.
ImageOwnerEnum
Enum passed to computeImage and computeKernelImage to determine image ownership.
geom::Point2D _cachedImagePosition
boost::shared_ptr< Psf > Ptr
Definitions and inlines for Quadrupole.
table::Key< table::Array< Kernel::Pixel > > image
A base class for objects that can be persisted via afw::table::io Archive classes.
static boost::shared_ptr< Image > recenterKernelImage(boost::shared_ptr< Image > im, geom::Point2D const &position, std::string const &warpAlgorithm="lanczos5", unsigned int warpBuffer=5)
virtual boost::shared_ptr< Image > doComputeKernelImage(geom::Point2D const &position, image::Color const &color) const =0
boost::shared_ptr< Image > _cachedImage
image::Color _cachedImageColor
math::Kernel::Pixel Pixel
Pixel type of Image returned by computeImage.
virtual boost::shared_ptr< Psf > clone() const =0
Polymorphic deep-copy.
double computePeak(geom::Point2D position=makeNullPoint(), image::Color color=image::Color()) const
Return the peak value of the PSF image.
#define LSST_PERSIST_FORMATTER(formatter...)
boost::shared_ptr< const Psf > ConstPtr
double computeApertureFlux(double radius, geom::Point2D position=makeNullPoint(), image::Color color=image::Color()) const
Compute the "flux" of the Psf model within a circular aperture of the given radius.
boost::shared_ptr< Image > computeImage(geom::Point2D position=makeNullPoint(), image::Color color=image::Color(), ImageOwnerEnum owner=COPY) const
Return an Image of the PSF, in a form that can be compared directly with star images.
Point< double, 2 > Point2D
Capture the colour of an object.
Base class for all persistable classes.
virtual geom::ellipses::Quadrupole doComputeShape(geom::Point2D const &position, image::Color const &color) const =0
Citizen is a class that should be among all LSST classes base classes, and handles basic memory manag...
virtual double doComputeApertureFlux(double radius, geom::Point2D const &position, image::Color const &color) const =0
A polymorphic base class for representing an image's Point Spread Function.
A CRTP facade class for subclasses of Persistable.
image::Image< Pixel > Image
Image type returned by computeImage.
virtual boost::shared_ptr< Image > doComputeImage(geom::Point2D const &position, image::Color const &color) const
image::Color _cachedKernelImageColor
The image will be copied before returning; caller will own it.