LSST Applications g0265f82a02+0e5473021a,g02d81e74bb+bd2ed33bd6,g1470d8bcf6+de7501a2e0,g14a832a312+ff425fae3c,g2079a07aa2+86d27d4dc4,g2305ad1205+91a32aca49,g295015adf3+762506a1ad,g2bbee38e9b+0e5473021a,g337abbeb29+0e5473021a,g3ddfee87b4+c34e8be1fa,g487adcacf7+5fae3daba8,g50ff169b8f+96c6868917,g52b1c1532d+585e252eca,g591dd9f2cf+ea1711114f,g5a732f18d5+53520f316c,g64a986408d+bd2ed33bd6,g858d7b2824+bd2ed33bd6,g8a8a8dda67+585e252eca,g99cad8db69+016a06b37a,g9ddcbc5298+9a081db1e4,ga1e77700b3+15fc3df1f7,ga8c6da7877+ef4e3a5875,gb0e22166c9+60f28cb32d,gb6a65358fc+0e5473021a,gba4ed39666+c2a2e4ac27,gbb8dafda3b+09e12c87ab,gc120e1dc64+bc2e06c061,gc28159a63d+0e5473021a,gcf0d15dbbd+c34e8be1fa,gdaeeff99f8+f9a426f77a,ge6526c86ff+508d0e0a30,ge79ae78c31+0e5473021a,gee10cc3b42+585e252eca,gf18bd8381d+8d59551888,gf1cff7945b+bd2ed33bd6,w.2024.16
LSST Data Management Base Package
Loading...
Searching...
No Matches
Public Types | Public Member Functions | Static Public Member Functions | List of all members
lsst::afw::math::SpatialCellImageCandidate Class Referenceabstract

Base class for candidate objects in a SpatialCell that are able to return an Image of some sort (e.g. More...

#include <SpatialCell.h>

Inheritance diagram for lsst::afw::math::SpatialCellImageCandidate:
lsst::afw::math::SpatialCellCandidate lsst::ip::diffim::KernelCandidate< _PixelT > lsst::meas::algorithms::PsfCandidate< PixelT >

Public Types

enum  Status { BAD = 0 , GOOD = 1 , UNKNOWN = 2 }
 

Public Member Functions

 SpatialCellImageCandidate (float const xCenter, float const yCenter)
 ctor
 
 SpatialCellImageCandidate (SpatialCellImageCandidate const &)=default
 
 SpatialCellImageCandidate (SpatialCellImageCandidate &&)=default
 
 ~SpatialCellImageCandidate () override=default
 
double getChi2 () const
 Return the candidate's chi^2.
 
void setChi2 (double chi2)
 Set the candidate's chi^2.
 
float getXCenter () const
 Return the object's column-centre.
 
float getYCenter () const
 Return the object's row-centre.
 
virtual bool instantiate ()
 Do anything needed to make this candidate usable.
 
virtual double getCandidateRating () const =0
 Return candidate's rating.
 
virtual void setCandidateRating (double)
 Set the candidate's rating.
 
int getId () const
 Return the candidate's unique ID.
 
Status getStatus () const
 Return the candidate's status.
 
void setStatus (Status status)
 Set the candidate's status.
 
virtual bool isBad () const
 Is this candidate unacceptable?
 

Static Public Member Functions

static void setWidth (int width)
 Set the width of the image that getImage should return.
 
static int getWidth ()
 Return the width of the image that getImage should return.
 
static void setHeight (int height)
 Set the height of the image that getImage should return.
 
static int getHeight ()
 Return the height of the image that getImage should return.
 

Detailed Description

Base class for candidate objects in a SpatialCell that are able to return an Image of some sort (e.g.

a PSF or a DIA kernel)

Definition at line 124 of file SpatialCell.h.

Member Enumeration Documentation

◆ Status

Enumerator
BAD 
GOOD 
UNKNOWN 

Definition at line 72 of file SpatialCell.h.

Constructor & Destructor Documentation

◆ SpatialCellImageCandidate() [1/3]

lsst::afw::math::SpatialCellImageCandidate::SpatialCellImageCandidate ( float const xCenter,
float const yCenter )
inline

ctor

Parameters
xCenterThe object's column-centre
yCenterThe object's row-centre

Definition at line 127 of file SpatialCell.h.

130 : SpatialCellCandidate(xCenter, yCenter), _chi2(std::numeric_limits<double>::max()) {}
SpatialCellCandidate(float const xCenter, float const yCenter)
Definition SpatialCell.h:74

◆ SpatialCellImageCandidate() [2/3]

lsst::afw::math::SpatialCellImageCandidate::SpatialCellImageCandidate ( SpatialCellImageCandidate const & )
default

◆ SpatialCellImageCandidate() [3/3]

lsst::afw::math::SpatialCellImageCandidate::SpatialCellImageCandidate ( SpatialCellImageCandidate && )
default

◆ ~SpatialCellImageCandidate()

lsst::afw::math::SpatialCellImageCandidate::~SpatialCellImageCandidate ( )
overridedefault

Member Function Documentation

◆ getCandidateRating()

virtual double lsst::afw::math::SpatialCellCandidate::getCandidateRating ( ) const
pure virtualinherited

◆ getChi2()

double lsst::afw::math::SpatialCellImageCandidate::getChi2 ( ) const
inline

Return the candidate's chi^2.

Definition at line 146 of file SpatialCell.h.

146{ return _chi2; }

◆ getHeight()

static int lsst::afw::math::SpatialCellImageCandidate::getHeight ( )
inlinestatic

Return the height of the image that getImage should return.

Definition at line 143 of file SpatialCell.h.

143{ return _height; }

◆ getId()

int lsst::afw::math::SpatialCellCandidate::getId ( ) const
inlineinherited

Return the candidate's unique ID.

Definition at line 102 of file SpatialCell.h.

102{ return _id; }

◆ getStatus()

Status lsst::afw::math::SpatialCellCandidate::getStatus ( ) const
inlineinherited

Return the candidate's status.

Definition at line 104 of file SpatialCell.h.

104{ return _status; }

◆ getWidth()

static int lsst::afw::math::SpatialCellImageCandidate::getWidth ( )
inlinestatic

Return the width of the image that getImage should return.

Definition at line 138 of file SpatialCell.h.

138{ return _width; }

◆ getXCenter()

float lsst::afw::math::SpatialCellCandidate::getXCenter ( ) const
inlineinherited

Return the object's column-centre.

Definition at line 88 of file SpatialCell.h.

88{ return _xCenter; }

◆ getYCenter()

float lsst::afw::math::SpatialCellCandidate::getYCenter ( ) const
inlineinherited

Return the object's row-centre.

Definition at line 91 of file SpatialCell.h.

91{ return _yCenter; }

◆ instantiate()

virtual bool lsst::afw::math::SpatialCellCandidate::instantiate ( )
inlinevirtualinherited

Do anything needed to make this candidate usable.

Definition at line 94 of file SpatialCell.h.

94{ return true; }

◆ isBad()

virtual bool lsst::afw::math::SpatialCellCandidate::isBad ( ) const
inlinevirtualinherited

Is this candidate unacceptable?

Definition at line 108 of file SpatialCell.h.

108{ return (_status == BAD); }

◆ setCandidateRating()

virtual void lsst::afw::math::SpatialCellCandidate::setCandidateRating ( double )
inlinevirtualinherited

Set the candidate's rating.

Definition at line 99 of file SpatialCell.h.

99{}

◆ setChi2()

void lsst::afw::math::SpatialCellImageCandidate::setChi2 ( double chi2)
inline

Set the candidate's chi^2.

Definition at line 148 of file SpatialCell.h.

148{ _chi2 = chi2; }

◆ setHeight()

static void lsst::afw::math::SpatialCellImageCandidate::setHeight ( int height)
inlinestatic

Set the height of the image that getImage should return.

Definition at line 141 of file SpatialCell.h.

141{ _height = height; }

◆ setStatus()

void lsst::afw::math::SpatialCellCandidate::setStatus ( Status status)
inherited

Set the candidate's status.

Definition at line 52 of file SpatialCell.cc.

52 {
53 switch (status) {
54 case GOOD:
55 case UNKNOWN:
56 _status = status;
57 return;
58 case BAD:
59 _status = status;
60 return;
61 }
62
64 (boost::format("Saw unknown status %d") % status).str());
65}
#define LSST_EXCEPT(type,...)
Create an exception with a given type.
Definition Exception.h:48
Reports invalid arguments.
Definition Runtime.h:66

◆ setWidth()

static void lsst::afw::math::SpatialCellImageCandidate::setWidth ( int width)
inlinestatic

Set the width of the image that getImage should return.

Definition at line 136 of file SpatialCell.h.

136{ _width = width; }

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