LSSTApplications  10.0+286,10.0+36,10.0+46,10.0-2-g4f67435,10.1+152,10.1+37,11.0,11.0+1,11.0-1-g47edd16,11.0-1-g60db491,11.0-1-g7418c06,11.0-2-g04d2804,11.0-2-g68503cd,11.0-2-g818369d,11.0-2-gb8b8ce7
LSSTDataManagementBasePackage
AssessSpatialKernelVisitor.h
Go to the documentation of this file.
1 // -*- lsst-c++ -*-
12 #ifndef LSST_IP_DIFFIM_ASSESSSPATIALKERNELVISITOR_H
13 #define LSST_IP_DIFFIM_ASSESSSPATIALKERNELVISITOR_H
14 
15 #include "lsst/afw/math.h"
16 #include "lsst/afw/image.h"
17 #include "lsst/ip/diffim.h"
18 #include "lsst/pex/policy/Policy.h"
19 
20 namespace lsst {
21 namespace ip {
22 namespace diffim {
23 namespace detail {
24 
25  template<typename PixelT>
28  public:
29  typedef boost::shared_ptr<AssessSpatialKernelVisitor<PixelT> > Ptr;
30 
34  lsst::pex::policy::Policy const& policy
35  );
37 
38  void reset() {_nGood = 0; _nRejected = 0; _nProcessed = 0;}
39 
40  int getNGood() {return _nGood;}
41  int getNRejected() {return _nRejected;}
42  int getNProcessed() {return _nProcessed;}
44 
45  private:
50  int _nGood;
51  int _nRejected;
53 
56  };
57 
58  template<typename PixelT>
59  boost::shared_ptr<AssessSpatialKernelVisitor<PixelT> >
63  lsst::pex::policy::Policy const& policy
64  ) {
65 
67  new AssessSpatialKernelVisitor<PixelT>(spatialKernel, spatialBackground, policy)
68  );
69  }
70 
71 }}}} // end of namespace lsst::ip::diffim::detail
72 
73 #endif
An include file to include the public header files for lsst::afw::math.
boost::shared_ptr< lsst::afw::math::Function2< double > > SpatialFunctionPtr
Definition: Kernel.h:143
An include file to include the header files for lsst::ip::diffim.
int _nProcessed
Number of candidates processed during processCandidate()
boost::shared_ptr< AssessSpatialKernelVisitor< PixelT > > Ptr
Asseses the quality of a candidate given a spatial kernel and background model.
AssessSpatialKernelVisitor(lsst::afw::math::LinearCombinationKernel::Ptr spatialKernel, lsst::afw::math::Kernel::SpatialFunctionPtr spatialBackground, lsst::pex::policy::Policy const &policy)
a container for holding hierarchical configuration data in memory.
Definition: Policy.h:169
boost::shared_ptr< LinearCombinationKernel > Ptr
Definition: Kernel.h:818
An include file to include the header files for lsst::afw::image.
boost::shared_ptr< AssessSpatialKernelVisitor< PixelT > > makeAssessSpatialKernelVisitor(lsst::afw::math::LinearCombinationKernel::Ptr spatialKernel, lsst::afw::math::Kernel::SpatialFunctionPtr spatialBackground, lsst::pex::policy::Policy const &policy)
int _nRejected
Number of candidates rejected during processCandidate()
A class to manipulate images, masks, and variance as a single object.
Definition: MaskedImage.h:77
lsst::afw::math::LinearCombinationKernel::Ptr _spatialKernel
Spatial kernel function.
ImageStatistics< PixelT > _imstats
To calculate statistics of difference image.
Class to calculate difference image statistics.
lsst::afw::math::Kernel::SpatialFunctionPtr _spatialBackground
Spatial background function.
void processCandidate(lsst::afw::math::SpatialCellCandidate *candidate)
lsst::pex::policy::Policy _policy
Policy controlling behavior.