24 # if !defined(LSST_MEAS_EXTENSIONS_PSFEX_PSFEX_H)
25 #define LSST_MEAS_EXTENSIONS_PSFEX_PSFEX_H 1
27 #include "lsst/meas/algorithms/ImagePsf.h"
28 #include "lsst/meas/extensions/psfex/psf.hh"
30 namespace lsst {
namespace meas {
namespace extensions {
namespace psfex {
38 class PsfexPsf :
public lsst::afw::table::io::PersistableFacade<PsfexPsf>,
39 public lsst::meas::algorithms::ImagePsf {
46 lsst::meas::extensions::psfex::Psf
const& psf,
47 lsst::afw::geom::Point2D
const &
averagePosition=lsst::afw::geom::Point2D()
53 virtual PTR(lsst::afw::detection::Psf)
clone() const;
60 PTR(lsst::afw::math::LinearCombinationKernel
const)
62 lsst::afw::geom::Point2D(std::numeric_limits<
double>::quiet_NaN())) const;
67 void write(lsst::afw::table::io::OutputArchiveHandle & handle)
const;
69 lsst::afw::geom::Point2D _averagePosition;
73 std::vector<int>
_size;
74 std::vector<float>
_comp;
75 std::vector<std::pair<double, double> > _context;
76 mutable PTR(lsst::afw::math::LinearCombinationKernel) _kernel;
82 virtual PTR(lsst::afw::detection::Psf::Image) _doComputeImage(
83 lsst::afw::geom::Point2D const & position,
84 lsst::afw::image::Color const& color,
85 lsst::afw::geom::Point2D const& center
89 virtual PTR(lsst::afw::detection::Psf::Image) doComputeKernelImage(
90 lsst::afw::geom::Point2D const & position,
91 lsst::afw::image::Color const& color
95 virtual PTR(lsst::afw::detection::Psf::Image) doComputeImage(
96 lsst::afw::geom::Point2D const & position,
97 lsst::afw::image::Color const& color
101 virtual lsst::afw::geom::Box2I doComputeBBox(
102 lsst::afw::geom::Point2D const & position,
103 lsst::afw::image::Color const & color
109 lsst::afw::geom::Box2I _doComputeBBox(
110 lsst::afw::geom::Point2D const & position,
111 lsst::afw::geom::Point2D const & center
115 virtual std::
string getPersistenceName() const;
117 virtual std::
string getPythonModule() const;
122 #endif // !LSST_MEAS_EXTENSIONS_PSFEX_PSFEX_H
virtual boost::shared_ptr< lsst::afw::detection::Psf > clone() const
Polymorphic deep copy; should usually be unnecessary as Psfs are immutable.x.
virtual lsst::afw::geom::Point2D getAveragePosition() const
Return average position of stars; used as default position.
Represent a PSF as a linear combination of PSFEX (== Karhunen-Loeve) basis functions.
boost::shared_ptr< lsst::afw::math::LinearCombinationKernel const > getKernel(lsst::afw::geom::Point2D=lsst::afw::geom::Point2D(std::numeric_limits< double >::quiet_NaN())) const
Return the PSF's basis functions as a spatially-invariant LinearCombinationKernel with unit weights...
void write(lsst::afw::table::io::OutputArchiveHandle &handle) const
table::Key< table::Array< int > > _size
table::Key< table::Array< float > > _comp
virtual bool isPersistable() const
Is this object persistable?
table::Key< float > _pixstep
table::PointKey< double > averagePosition