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
Main Page
Related Pages
Modules
Namespaces
Classes
Files
Examples
File List
File Members
home
lsstsw
stack
Linux64
meas_algorithms
11.0-2-gb8b8ce7
src
ImagePsf.cc
Go to the documentation of this file.
1
// -*- LSST-C++ -*-
2
/*
3
* LSST Data Management System
4
* Copyright 2008-2013 LSST Corporation.
5
*
6
* This product includes software developed by the
7
* LSST Project (http://www.lsst.org/).
8
*
9
* This program is free software: you can redistribute it and/or modify
10
* it under the terms of the GNU General Public License as published by
11
* the Free Software Foundation, either version 3 of the License, or
12
* (at your option) any later version.
13
*
14
* This program is distributed in the hope that it will be useful,
15
* but WITHOUT ANY WARRANTY; without even the implied warranty of
16
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17
* GNU General Public License for more details.
18
*
19
* You should have received a copy of the LSST License Statement and
20
* the GNU General Public License along with this program. If not,
21
* see <http://www.lsstcorp.org/LegalNotices/>.
22
*/
23
24
#include "
lsst/afw/image/MaskedImage.h
"
25
#include "
lsst/meas/algorithms/ImagePsf.h
"
26
#include "
lsst/meas/base/SdssShape.h
"
27
#include "
lsst/meas/base/ApertureFlux.h
"
28
29
namespace
lsst {
namespace
meas {
namespace
algorithms {
30
31
double
ImagePsf::doComputeApertureFlux
(
32
double
radius,
afw::geom::Point2D
const
& position,
afw::image::Color
const
& color
33
)
const
{
34
afw::image::Image<double>
const
&
image
(*
computeKernelImage
(position, color,
INTERNAL
));
35
36
afw::geom::Point2D
const
center(0.0, 0.0);
37
afw::geom::ellipses::Axes
const
axes(radius, radius);
38
base::ApertureFluxResult
result =
base::ApertureFluxAlgorithm::computeSincFlux
(
39
image,
40
afw::geom::ellipses::Ellipse
(axes, center),
41
base::ApertureFluxControl
()
42
);
43
return
result.
flux
;
44
}
45
46
afw::geom::ellipses::Quadrupole
ImagePsf::doComputeShape
(
47
afw::geom::Point2D
const
& position,
afw::image::Color
const
& color
48
)
const
{
49
PTR
(
Image
)
image
=
computeKernelImage
(position, color,
INTERNAL
);
50
return
meas::base::SdssShapeAlgorithm::computeAdaptiveMoments
(
51
*
image
,
52
afw::geom::Point2D
(0.0, 0.0)
// image has origin at the center
53
).
getShape
();
54
}
55
56
}}}
// namespace lsst::meas::algorithms
lsst::afw::geom::ellipses::Quadrupole
An ellipse core with quadrupole moments as parameters.
Definition:
Quadrupole.h:45
lsst::afw::detection::Psf::computeKernelImage
boost::shared_ptr< Image > computeKernelImage(geom::Point2D position=makeNullPoint(), image::Color color=image::Color(), ImageOwnerEnum owner=COPY) const
Return an Image of the PSF, in a form suitable for convolution.
SdssShape.h
lsst::meas::algorithms::ImagePsf::doComputeShape
virtual afw::geom::ellipses::Quadrupole doComputeShape(afw::geom::Point2D const &position, afw::image::Color const &color) const
Definition:
ImagePsf.cc:46
PTR
#define PTR(...)
Definition:
base.h:41
lsst::afw::geom::Point< double, 2 >
lsst::meas::base::ShapeResult::getShape
Shape const getShape() const
Return an afw::geom::ellipses object corresponding to xx, yy, xy.
Definition:
ShapeUtilities.cc:40
lsst::meas::base::ApertureFluxControl
Definition:
ApertureFlux.h:42
image
table::Key< table::Array< Kernel::Pixel > > image
Definition:
FixedKernel.cc:117
lsst::meas::algorithms::ImagePsf::doComputeApertureFlux
virtual double doComputeApertureFlux(double radius, afw::geom::Point2D const &position, afw::image::Color const &color) const
Definition:
ImagePsf.cc:31
lsst::meas::base::SdssShapeAlgorithm::computeAdaptiveMoments
static Result computeAdaptiveMoments(ImageT const &image, afw::geom::Point2D const &position, Control const &ctrl=Control())
lsst::afw::geom::ellipses::Ellipse
An ellipse defined by an arbitrary BaseCore and a center point.
Definition:
Ellipse.h:50
ApertureFlux.h
lsst::meas::base::FluxResult::flux
Flux flux
Measured flux in DN.
Definition:
FluxUtilities.h:38
lsst::afw::geom::ellipses::Axes
An ellipse core for the semimajor/semiminor axis and position angle parametrization (a...
Definition:
Axes.h:45
lsst::meas::base::ApertureFluxAlgorithm::computeSincFlux
static Result computeSincFlux(afw::image::Image< T > const &image, afw::geom::ellipses::Ellipse const &ellipse, Control const &ctrl=Control())
Definition:
ApertureFlux.cc:164
lsst::afw::detection::Psf::INTERNAL
Definition:
Psf.h:84
MaskedImage.h
Implementation of the Class MaskedImage.
lsst::afw::image::Color
Definition:
Color.h:28
lsst::afw::image::Image
A class to represent a 2-dimensional array of pixels.
Definition:
Image.h:415
lsst::meas::base::ApertureFluxResult
Definition:
ApertureFlux.h:248
ImagePsf.h
Generated on Thu Sep 24 2015 02:29:20 for LSSTApplications by
1.8.5