LSSTApplications  1.1.2+25,10.0+13,10.0+132,10.0+133,10.0+224,10.0+41,10.0+8,10.0-1-g0f53050+14,10.0-1-g4b7b172+19,10.0-1-g61a5bae+98,10.0-1-g7408a83+3,10.0-1-gc1e0f5a+19,10.0-1-gdb4482e+14,10.0-11-g3947115+2,10.0-12-g8719d8b+2,10.0-15-ga3f480f+1,10.0-2-g4f67435,10.0-2-gcb4bc6c+26,10.0-28-gf7f57a9+1,10.0-3-g1bbe32c+14,10.0-3-g5b46d21,10.0-4-g027f45f+5,10.0-4-g86f66b5+2,10.0-4-gc4fccf3+24,10.0-40-g4349866+2,10.0-5-g766159b,10.0-5-gca2295e+25,10.0-6-g462a451+1
LSSTDataManagementBasePackage
attributes.h
Go to the documentation of this file.
1 // -*- lsst-c++ -*-
2 
3 /*
4  * LSST Data Management System
5  * Copyright 2012 LSST Corporation.
6  *
7  * This product includes software developed by the
8  * LSST Project (http://www.lsst.org/).
9  *
10  * This program is free software: you can redistribute it and/or modify
11  * it under the terms of the GNU General Public License as published by
12  * the Free Software Foundation, either version 3 of the License, or
13  * (at your option) any later version.
14  *
15  * This program is distributed in the hope that it will be useful,
16  * but WITHOUT ANY WARRANTY; without even the implied warranty of
17  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18  * GNU General Public License for more details.
19  *
20  * You should have received a copy of the LSST License Statement and
21  * the GNU General Public License along with this program. If not,
22  * see <http://www.lsstcorp.org/LegalNotices/>.
23  */
24 
29 #ifndef LSST_AP_CLUSTER_ATTRIBUTES_H
30 #define LSST_AP_CLUSTER_ATTRIBUTES_H
31 
32 #include <vector>
33 
34 #include "../match/ExposureInfo.h"
36 #include "SourceCluster.h"
37 
38 
39 namespace lsst { namespace ap { namespace cluster {
40 
47 public:
49 
51  boost::shared_ptr<lsst::afw::table::SourceRecord> const & source,
52  boost::shared_ptr<lsst::ap::match::ExposureInfo> const & exposure,
53  lsst::afw::geom::AffineTransform const & transform);
54 
56 
57  boost::shared_ptr<lsst::afw::table::SourceRecord> const getSource() const {
58  return _source;
59  }
60  boost::shared_ptr<lsst::ap::match::ExposureInfo> const getExposureInfo() const {
61  return _exposure;
62  }
64  return _transform;
65  }
66 
67 private:
68  boost::shared_ptr<lsst::afw::table::SourceRecord> _source;
69  boost::shared_ptr<lsst::ap::match::ExposureInfo> _exposure;
71 };
72 
73 
107 boost::shared_ptr<std::vector<SourceAndExposure> > const computeBasicAttributes(
109  lsst::afw::table::SourceCatalog const & sources,
110  lsst::ap::match::ExposureInfoMap const & exposures,
111  std::string const & exposurePrefix
112 );
113 
139 void computeFluxMean(
141  std::vector<SourceAndExposure> const & sources,
142  std::string const & fluxDef,
143  std::vector<lsst::afw::table::Key<lsst::afw::table::Flag > > const & skipFlags,
144  double fluxScale
145 );
146 
175 void computeShapeMean(
177  std::vector<SourceAndExposure> const & sources,
178  std::string const & shapeDef,
179  std::vector<lsst::afw::table::Key<lsst::afw::table::Flag > > const & skipFlags
180 );
181 
182 }}} // namespace lsst::ap::cluster
183 
184 #endif // LSST_AP_CLUSTER_ATTRIBUTES_H
185 
boost::shared_ptr< lsst::ap::match::ExposureInfo > _exposure
Definition: attributes.h:69
boost::shared_ptr< lsst::afw::table::SourceRecord > const getSource() const
Definition: attributes.h:57
Source processing control.
boost::shared_ptr< std::vector< SourceAndExposure > > const computeBasicAttributes(SourceClusterRecord &cluster, SourceCatalog const &sources, ExposureInfoMap const &exposures, std::string const &exposurePrefix)
Definition: attributes.cc:334
std::vector< SourceCatalog > const cluster(SourceCatalog const &sources, ClusteringControl const &control)
Definition: clustering.cc:578
lsst::afw::geom::AffineTransform const & getTransform() const
Definition: attributes.h:63
void computeShapeMean(SourceClusterRecord &cluster, std::vector< SourceAndExposure > const &sources, std::string const &shapeDef, std::vector< lsst::afw::table::Key< lsst::afw::table::Flag > > const &skipFlags)
Definition: attributes.cc:535
Record class that contains measurement averages on clusters of single exposure sources.
Definition: SourceCluster.h:98
void computeFluxMean(SourceClusterRecord &cluster, std::vector< SourceAndExposure > const &sources, std::string const &fluxDef, std::vector< Key< Flag > > const &skipFlags, double fluxScale)
Definition: attributes.cc:439
Table and record classes for source cluster attributes.
boost::shared_ptr< lsst::ap::match::ExposureInfo > const getExposureInfo() const
Definition: attributes.h:60
Custom catalog class for record/table subclasses that are guaranteed to have an ID, and should generally be sorted by that ID.
Definition: fwd.h:55
An affine coordinate transformation consisting of a linear transformation and an offset.
lsst::afw::geom::AffineTransform _transform
Definition: attributes.h:70
boost::shared_ptr< lsst::afw::table::SourceRecord > _source
Definition: attributes.h:68
A class used as a handle to a particular field in a table.
Definition: fwd.h:44