lsst.ip.diffim  14.0-6-gf4bc96c+17
Public Types | Public Member Functions | Private Types | Private Attributes | List of all members
lsst::ip::diffim::detail::AssessSpatialKernelVisitor< PixelT > Class Template Reference

Asseses the quality of a candidate given a spatial kernel and background model. More...

#include <AssessSpatialKernelVisitor.h>

Inheritance diagram for lsst::ip::diffim::detail::AssessSpatialKernelVisitor< PixelT >:
lsst::afw::math::CandidateVisitor

Public Types

typedef std::shared_ptr< AssessSpatialKernelVisitor< PixelT > > Ptr
 

Public Member Functions

 AssessSpatialKernelVisitor (std::shared_ptr< lsst::afw::math::LinearCombinationKernel > spatialKernel, lsst::afw::math::Kernel::SpatialFunctionPtr spatialBackground, lsst::pex::policy::Policy const &policy)
 
virtual ~AssessSpatialKernelVisitor ()
 
void reset ()
 
int getNGood ()
 
int getNRejected ()
 
int getNProcessed ()
 
void processCandidate (lsst::afw::math::SpatialCellCandidate *candidate)
 

Private Types

typedef lsst::afw::image::MaskedImage< PixelTMaskedImageT
 

Private Attributes

std::shared_ptr< lsst::afw::math::LinearCombinationKernel_spatialKernel
 Spatial kernel function. More...
 
lsst::afw::math::Kernel::SpatialFunctionPtr _spatialBackground
 Spatial background function. More...
 
lsst::pex::policy::Policy _policy
 Policy controlling behavior. More...
 
ImageStatistics< PixelT_imstats
 To calculate statistics of difference image. More...
 
int _nGood
 Number of good candidates remaining. More...
 
int _nRejected
 Number of candidates rejected during processCandidate() More...
 
int _nProcessed
 Number of candidates processed during processCandidate() More...
 
bool _useCoreStats
 Extracted from policy. More...
 
int _coreRadius
 Extracted from policy. More...
 

Detailed Description

template<typename PixelT>
class lsst::ip::diffim::detail::AssessSpatialKernelVisitor< PixelT >

Asseses the quality of a candidate given a spatial kernel and background model.

detail::AssessSpatialKernelVisitor<PixelT> spatialKernelAssessor(spatialKernel,
spatialBackground,
policy);
spatialKernelAssessor.reset();
kernelCells.visitCandidates(&spatialKernelAssessor, nStarPerCell);
nRejected = spatialKernelAssessor.getNRejected();
Note
Evaluates the spatial kernel and spatial background at the location of each candidate, and computes the resulting difference image. Sets candidate as afwMath::SpatialCellCandidate::GOOD/BAD if requested by the Policy.

Definition at line 26 of file AssessSpatialKernelVisitor.h.

Member Typedef Documentation

◆ MaskedImageT

Definition at line 27 of file AssessSpatialKernelVisitor.h.

◆ Ptr

Definition at line 29 of file AssessSpatialKernelVisitor.h.

Constructor & Destructor Documentation

◆ AssessSpatialKernelVisitor()

Parameters
spatialKernelSpatially varying kernel
spatialBackgroundSpatially varying background
policyPolicy file

Definition at line 54 of file AssessSpatialKernelVisitor.cc.

◆ ~AssessSpatialKernelVisitor()

template<typename PixelT >
virtual lsst::ip::diffim::detail::AssessSpatialKernelVisitor< PixelT >::~AssessSpatialKernelVisitor ( )
inlinevirtual

Definition at line 36 of file AssessSpatialKernelVisitor.h.

Member Function Documentation

◆ getNGood()

template<typename PixelT >
int lsst::ip::diffim::detail::AssessSpatialKernelVisitor< PixelT >::getNGood ( )
inline

Definition at line 40 of file AssessSpatialKernelVisitor.h.

◆ getNProcessed()

template<typename PixelT >
int lsst::ip::diffim::detail::AssessSpatialKernelVisitor< PixelT >::getNProcessed ( )
inline

Definition at line 42 of file AssessSpatialKernelVisitor.h.

◆ getNRejected()

template<typename PixelT >
int lsst::ip::diffim::detail::AssessSpatialKernelVisitor< PixelT >::getNRejected ( )
inline

Definition at line 41 of file AssessSpatialKernelVisitor.h.

◆ processCandidate()

template<typename PixelT >
void lsst::ip::diffim::detail::AssessSpatialKernelVisitor< PixelT >::processCandidate ( lsst::afw::math::SpatialCellCandidate candidate)
virtual

Reimplemented from lsst::afw::math::CandidateVisitor.

Definition at line 72 of file AssessSpatialKernelVisitor.cc.

◆ reset()

template<typename PixelT >
void lsst::ip::diffim::detail::AssessSpatialKernelVisitor< PixelT >::reset ( )
inlinevirtual

Reimplemented from lsst::afw::math::CandidateVisitor.

Definition at line 38 of file AssessSpatialKernelVisitor.h.

Member Data Documentation

◆ _coreRadius

template<typename PixelT >
int lsst::ip::diffim::detail::AssessSpatialKernelVisitor< PixelT >::_coreRadius
private

Extracted from policy.

Definition at line 55 of file AssessSpatialKernelVisitor.h.

◆ _imstats

template<typename PixelT >
ImageStatistics<PixelT> lsst::ip::diffim::detail::AssessSpatialKernelVisitor< PixelT >::_imstats
private

To calculate statistics of difference image.

Definition at line 49 of file AssessSpatialKernelVisitor.h.

◆ _nGood

template<typename PixelT >
int lsst::ip::diffim::detail::AssessSpatialKernelVisitor< PixelT >::_nGood
private

Number of good candidates remaining.

Definition at line 50 of file AssessSpatialKernelVisitor.h.

◆ _nProcessed

template<typename PixelT >
int lsst::ip::diffim::detail::AssessSpatialKernelVisitor< PixelT >::_nProcessed
private

Number of candidates processed during processCandidate()

Definition at line 52 of file AssessSpatialKernelVisitor.h.

◆ _nRejected

template<typename PixelT >
int lsst::ip::diffim::detail::AssessSpatialKernelVisitor< PixelT >::_nRejected
private

Number of candidates rejected during processCandidate()

Definition at line 51 of file AssessSpatialKernelVisitor.h.

◆ _policy

Policy controlling behavior.

Definition at line 48 of file AssessSpatialKernelVisitor.h.

◆ _spatialBackground

Spatial background function.

Definition at line 47 of file AssessSpatialKernelVisitor.h.

◆ _spatialKernel

Spatial kernel function.

Definition at line 46 of file AssessSpatialKernelVisitor.h.

◆ _useCoreStats

template<typename PixelT >
bool lsst::ip::diffim::detail::AssessSpatialKernelVisitor< PixelT >::_useCoreStats
private

Extracted from policy.

Definition at line 54 of file AssessSpatialKernelVisitor.h.


The documentation for this class was generated from the following files: