lsst.afw  20.0.0-11-g7b7d0ee7e+614f89f815
Classes | Public Member Functions | Friends | List of all members
lsst::afw::detection::FootprintMergeList Class Referencefinal

List of Merged Footprints. More...

#include <FootprintMerge.h>

Public Member Functions

 FootprintMergeList (afw::table::Schema &sourceSchema, std::vector< std::string > const &filterList, afw::table::Schema const &initialPeakSchema)
 Initialize the merge with a custom initial peak schema. More...
 
 FootprintMergeList (afw::table::Schema &sourceSchema, std::vector< std::string > const &filterList)
 Initialize the merge with the default peak schema. More...
 
 ~FootprintMergeList ()
 
 FootprintMergeList (FootprintMergeList const &)
 
 FootprintMergeList (FootprintMergeList &&)
 
FootprintMergeListoperator= (FootprintMergeList const &)
 
FootprintMergeListoperator= (FootprintMergeList &&)
 
afw::table::Schema getPeakSchema () const
 Return the schema for PeakRecords in the merged footprints. More...
 
void addCatalog (std::shared_ptr< afw::table::SourceTable > sourceTable, afw::table::SourceCatalog const &inputCat, std::string const &filter, float minNewPeakDist=-1., bool doMerge=true, float maxSamePeakDist=-1.)
 Add objects from a SourceCatalog in the specified filter. More...
 
void clearCatalog ()
 Clear entries in the current vector. More...
 
void getFinalSources (afw::table::SourceCatalog &outputCat)
 Get SourceCatalog with entries that contain the final Footprint and SourceRecord for each entry. More...
 

Friends

class FootprintMerge
 

Detailed Description

List of Merged Footprints.

Stores a vector of FootprintMerges and SourceRecords that contain the union of different footprints and which filters it was detected in. Individual Footprints from a SourceCatalog can be added to the vector (note that any SourceRecords with parent!=0 will be skipped). If a Footprint overlaps an existing FootprintMerge, the Footprint will be added to it. If not, then a new FootprintMerge will be created and added to the vector.

The search algorithm uses a brute force approach over the current list. This should be fine if we are operating on smallish number of objects, such as at the tract level.

Definition at line 56 of file FootprintMerge.h.

Constructor & Destructor Documentation

◆ FootprintMergeList() [1/4]

lsst::afw::detection::FootprintMergeList::FootprintMergeList ( afw::table::Schema sourceSchema,
std::vector< std::string > const &  filterList,
afw::table::Schema const &  initialPeakSchema 
)

Initialize the merge with a custom initial peak schema.

Parameters
[in,out]sourceSchemaInput schema for SourceRecords to be merged, modified on return to include 'merge_footprint_<filter>' Flag fields that will indicate the origin of the source.
[in]filterListSequence of filter names to be used in Flag fields.
[in]initialPeakSchemaInput schema of PeakRecords in Footprints to be merged.

The output schema for PeakRecords will include additional 'merge_peak_<filter>' Flag fields that indicate the origin of peaks. This can be accessed by getPeakSchema().

Definition at line 206 of file FootprintMerge.cc.

◆ FootprintMergeList() [2/4]

lsst::afw::detection::FootprintMergeList::FootprintMergeList ( afw::table::Schema sourceSchema,
std::vector< std::string > const &  filterList 
)

Initialize the merge with the default peak schema.

Parameters
[in,out]sourceSchemaInput schema for SourceRecords to be merged, modified on return to include 'merge_footprint_<filter>' Flag fields that will indicate the origin of the source.
[in]filterListSequence of filter names to be used in Flag fields.

The output schema for PeakRecords will include additional 'merge_peak_<filter>' Flag fields that indicate the origin of peaks. This can be accessed by getPeakSchema().

Definition at line 213 of file FootprintMerge.cc.

◆ ~FootprintMergeList()

lsst::afw::detection::FootprintMergeList::~FootprintMergeList ( )
default

◆ FootprintMergeList() [3/4]

lsst::afw::detection::FootprintMergeList::FootprintMergeList ( FootprintMergeList const &  )
default

◆ FootprintMergeList() [4/4]

lsst::afw::detection::FootprintMergeList::FootprintMergeList ( FootprintMergeList &&  )
default

Member Function Documentation

◆ addCatalog()

void lsst::afw::detection::FootprintMergeList::addCatalog ( std::shared_ptr< afw::table::SourceTable sourceTable,
afw::table::SourceCatalog const &  inputCat,
std::string const &  filter,
float  minNewPeakDist = -1.,
bool  doMerge = true,
float  maxSamePeakDist = -1. 
)

Add objects from a SourceCatalog in the specified filter.

Iterate over all objects that have not been deblendend and search for an overlapping FootprintMerge in _mergeList. If it overlaps, then it will be added to it, otherwise it will create a new one. If minNewPeakDist < 0, then new peaks will not be added to existing footprints. If minNewPeakDist >= 0, then new peaks will be added that are farther away than minNewPeakDist to the nearest existing peak.

The SourceTable is used to create new SourceRecords that store the filter information.

Definition at line 241 of file FootprintMerge.cc.

◆ clearCatalog()

void lsst::afw::detection::FootprintMergeList::clearCatalog ( )
inline

Clear entries in the current vector.

Definition at line 113 of file FootprintMerge.h.

◆ getFinalSources()

void lsst::afw::detection::FootprintMergeList::getFinalSources ( afw::table::SourceCatalog outputCat)

Get SourceCatalog with entries that contain the final Footprint and SourceRecord for each entry.

The resulting Footprints will be normalized, meaning that there peaks are sorted, and areas are calculated.

Definition at line 301 of file FootprintMerge.cc.

◆ getPeakSchema()

afw::table::Schema lsst::afw::detection::FootprintMergeList::getPeakSchema ( ) const
inline

Return the schema for PeakRecords in the merged footprints.

Definition at line 93 of file FootprintMerge.h.

◆ operator=() [1/2]

FootprintMergeList & lsst::afw::detection::FootprintMergeList::operator= ( FootprintMergeList &&  )
default

◆ operator=() [2/2]

FootprintMergeList & lsst::afw::detection::FootprintMergeList::operator= ( FootprintMergeList const &  )
default

Friends And Related Function Documentation

◆ FootprintMerge

friend class FootprintMerge
friend

Definition at line 134 of file FootprintMerge.h.


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