LSSTApplications
19.0.0-14-gb0260a2+72efe9b372,20.0.0+7927753e06,20.0.0+8829bf0056,20.0.0+995114c5d2,20.0.0+b6f4b2abd1,20.0.0+bddc4f4cbe,20.0.0-1-g253301a+8829bf0056,20.0.0-1-g2b7511a+0d71a2d77f,20.0.0-1-g5b95a8c+7461dd0434,20.0.0-12-g321c96ea+23efe4bbff,20.0.0-16-gfab17e72e+fdf35455f6,20.0.0-2-g0070d88+ba3ffc8f0b,20.0.0-2-g4dae9ad+ee58a624b3,20.0.0-2-g61b8584+5d3db074ba,20.0.0-2-gb780d76+d529cf1a41,20.0.0-2-ged6426c+226a441f5f,20.0.0-2-gf072044+8829bf0056,20.0.0-2-gf1f7952+ee58a624b3,20.0.0-20-geae50cf+e37fec0aee,20.0.0-25-g3dcad98+544a109665,20.0.0-25-g5eafb0f+ee58a624b3,20.0.0-27-g64178ef+f1f297b00a,20.0.0-3-g4cc78c6+e0676b0dc8,20.0.0-3-g8f21e14+4fd2c12c9a,20.0.0-3-gbd60e8c+187b78b4b8,20.0.0-3-gbecbe05+48431fa087,20.0.0-38-ge4adf513+a12e1f8e37,20.0.0-4-g97dc21a+544a109665,20.0.0-4-gb4befbc+087873070b,20.0.0-4-gf910f65+5d3db074ba,20.0.0-5-gdfe0fee+199202a608,20.0.0-5-gfbfe500+d529cf1a41,20.0.0-6-g64f541c+d529cf1a41,20.0.0-6-g9a5b7a1+a1cd37312e,20.0.0-68-ga3f3dda+5fca18c6a4,20.0.0-9-g4aef684+e18322736b,w.2020.45
LSSTDataManagementBasePackage
|
An ellipse core for the semimajor/semiminor axis and position angle parametrization (a,b,theta).
More...
#include <Axes.h>
|
std::shared_ptr< BaseCore > | _clone () const override |
| Return the size of the bounding box for the ellipse core. More...
|
|
void | _assignToQuadrupole (double &ixx, double &iyy, double &ixy) const override |
| Return the size of the bounding box for the ellipse core. More...
|
|
void | _assignFromQuadrupole (double ixx, double iyy, double ixy) override |
| Return the size of the bounding box for the ellipse core. More...
|
|
void | _assignToAxes (double &a, double &b, double &theta) const override |
| Return the size of the bounding box for the ellipse core. More...
|
|
void | _assignFromAxes (double a, double b, double theta) override |
| Return the size of the bounding box for the ellipse core. More...
|
|
Jacobian | _dAssignToQuadrupole (double &ixx, double &iyy, double &ixy) const override |
| Return the size of the bounding box for the ellipse core. More...
|
|
Jacobian | _dAssignFromQuadrupole (double ixx, double iyy, double ixy) override |
| Return the size of the bounding box for the ellipse core. More...
|
|
Jacobian | _dAssignToAxes (double &a, double &b, double &theta) const override |
| Return the size of the bounding box for the ellipse core. More...
|
|
Jacobian | _dAssignFromAxes (double a, double b, double theta) override |
| Return the size of the bounding box for the ellipse core. More...
|
|
|
Convolution | convolve (BaseCore const &other) |
| Return the size of the bounding box for the ellipse core. More...
|
|
Convolution const | convolve (BaseCore const &other) const |
| Return the size of the bounding box for the ellipse core. More...
|
|
lsst::geom::Extent2D | computeDimensions () const |
| Return the size of the bounding box for the ellipse core. More...
|
|
ParameterVector const | getParameterVector () const |
| Return the core parameters as a vector. More...
|
|
void | setParameterVector (ParameterVector const &vector) |
| Set the core parameters from a vector. More...
|
|
bool | operator== (BaseCore const &other) const |
| Compare two ellipse cores for equality. More...
|
|
bool | operator!= (BaseCore const &other) const |
| Compare two ellipse cores for inequality. More...
|
|
Jacobian | dAssign (BaseCore const &other) |
| Assign other to this and return the derivative of the conversion, d(this)/d(other). More...
|
|
template<typename Output > |
Converter< Output > | as () const |
| Convert this to the core type specified as a template parameter. More...
|
|
static void | registerSubclass (std::shared_ptr< BaseCore > const &example) |
| Return the size of the bounding box for the ellipse core. More...
|
|
static void | _assignQuadrupoleToAxes (double ixx, double iyy, double ixy, double &a, double &b, double &theta) |
| Return the size of the bounding box for the ellipse core. More...
|
|
static Jacobian | _dAssignQuadrupoleToAxes (double ixx, double iyy, double ixy, double &a, double &b, double &theta) |
| Return the size of the bounding box for the ellipse core. More...
|
|
static void | _assignAxesToQuadrupole (double a, double b, double theta, double &ixx, double &iyy, double &ixy) |
| Return the size of the bounding box for the ellipse core. More...
|
|
static Jacobian | _dAssignAxesToQuadrupole (double a, double b, double theta, double &ixx, double &iyy, double &ixy) |
| Return the size of the bounding box for the ellipse core. More...
|
|
An ellipse core for the semimajor/semiminor axis and position angle parametrization (a,b,theta).
Definition at line 47 of file Axes.h.
◆ Jacobian
Parameter Jacobian matrix type.
Definition at line 64 of file BaseCore.h.
◆ ParameterVector
Parameter vector type.
Definition at line 63 of file BaseCore.h.
◆ ParameterEnum
◆ Axes() [1/7]
lsst::afw::geom::ellipses::Axes::Axes |
( |
double |
a = 1.0 , |
|
|
double |
b = 1.0 , |
|
|
double |
theta = 0.0 , |
|
|
bool |
normalize = false |
|
) |
| |
|
inlineexplicit |
Construct from parameter values.
Definition at line 91 of file Axes.h.
92 : _vector(
a,
b, theta) {
◆ Axes() [2/7]
Construct from a parameter vector.
Definition at line 97 of file Axes.h.
◆ Axes() [3/7]
lsst::afw::geom::ellipses::Axes::Axes |
( |
Axes const & |
other | ) |
|
|
inline |
Copy constructor.
Definition at line 102 of file Axes.h.
102 : _vector(
other._vector) {}
◆ Axes() [4/7]
lsst::afw::geom::ellipses::Axes::Axes |
( |
Axes && |
other | ) |
|
|
inline |
◆ ~Axes()
lsst::afw::geom::ellipses::Axes::~Axes |
( |
| ) |
|
|
overridedefault |
◆ Axes() [5/7]
lsst::afw::geom::ellipses::Axes::Axes |
( |
BaseCore const & |
other | ) |
|
|
inline |
Converting copy constructor.
Definition at line 108 of file Axes.h.
◆ Axes() [6/7]
Converting copy constructor.
Definition at line 111 of file Axes.h.
111 { transformer.apply(*
this); }
◆ Axes() [7/7]
Converting copy constructor.
Definition at line 114 of file Axes.h.
114 { convolution.apply(*
this); }
◆ _assignAxesToQuadrupole()
void lsst::afw::geom::ellipses::BaseCore::_assignAxesToQuadrupole |
( |
double |
a, |
|
|
double |
b, |
|
|
double |
theta, |
|
|
double & |
ixx, |
|
|
double & |
iyy, |
|
|
double & |
ixy |
|
) |
| |
|
staticprotectedinherited |
Return the size of the bounding box for the ellipse core.
Definition at line 219 of file BaseCore.cc.
225 ixy = (
a -
b) * c * s;
◆ _assignFromAxes()
void lsst::afw::geom::ellipses::Axes::_assignFromAxes |
( |
double |
a, |
|
|
double |
b, |
|
|
double |
theta |
|
) |
| |
|
overrideprotectedvirtual |
◆ _assignFromQuadrupole()
void lsst::afw::geom::ellipses::Axes::_assignFromQuadrupole |
( |
double |
ixx, |
|
|
double |
iyy, |
|
|
double |
ixy |
|
) |
| |
|
overrideprotectedvirtual |
◆ _assignQuadrupoleToAxes()
void lsst::afw::geom::ellipses::BaseCore::_assignQuadrupoleToAxes |
( |
double |
ixx, |
|
|
double |
iyy, |
|
|
double |
ixy, |
|
|
double & |
a, |
|
|
double & |
b, |
|
|
double & |
theta |
|
) |
| |
|
staticprotectedinherited |
Return the size of the bounding box for the ellipse core.
Definition at line 184 of file BaseCore.cc.
186 double xx_p_yy = ixx + iyy;
187 double xx_m_yy = ixx - iyy;
188 double t =
std::sqrt(xx_m_yy * xx_m_yy + 4 * ixy * ixy);
◆ _assignToAxes()
void lsst::afw::geom::ellipses::Axes::_assignToAxes |
( |
double & |
a, |
|
|
double & |
b, |
|
|
double & |
theta |
|
) |
| const |
|
overrideprotectedvirtual |
◆ _assignToQuadrupole()
void lsst::afw::geom::ellipses::Axes::_assignToQuadrupole |
( |
double & |
ixx, |
|
|
double & |
iyy, |
|
|
double & |
ixy |
|
) |
| const |
|
overrideprotectedvirtual |
◆ _clone()
|
inlineoverrideprotectedvirtual |
◆ _dAssignAxesToQuadrupole()
BaseCore::Jacobian lsst::afw::geom::ellipses::BaseCore::_dAssignAxesToQuadrupole |
( |
double |
a, |
|
|
double |
b, |
|
|
double |
theta, |
|
|
double & |
ixx, |
|
|
double & |
iyy, |
|
|
double & |
ixy |
|
) |
| |
|
staticprotectedinherited |
Return the size of the bounding box for the ellipse core.
Definition at line 232 of file BaseCore.cc.
235 m.col(0).setConstant(2 *
a);
236 m.col(1).setConstant(2 *
b);
239 m.col(2).setConstant(
a -
b);
243 ixy = (
a -
b) * c * s;
250 m(0, 2) *= -2.0 * cs;
◆ _dAssignFromAxes()
BaseCore::Jacobian lsst::afw::geom::ellipses::Axes::_dAssignFromAxes |
( |
double |
a, |
|
|
double |
b, |
|
|
double |
theta |
|
) |
| |
|
overrideprotectedvirtual |
◆ _dAssignFromQuadrupole()
BaseCore::Jacobian lsst::afw::geom::ellipses::Axes::_dAssignFromQuadrupole |
( |
double |
ixx, |
|
|
double |
iyy, |
|
|
double |
ixy |
|
) |
| |
|
overrideprotectedvirtual |
◆ _dAssignQuadrupoleToAxes()
BaseCore::Jacobian lsst::afw::geom::ellipses::BaseCore::_dAssignQuadrupoleToAxes |
( |
double |
ixx, |
|
|
double |
iyy, |
|
|
double |
ixy, |
|
|
double & |
a, |
|
|
double & |
b, |
|
|
double & |
theta |
|
) |
| |
|
staticprotectedinherited |
Return the size of the bounding box for the ellipse core.
Definition at line 194 of file BaseCore.cc.
196 double xx_p_yy = ixx + iyy;
197 double xx_m_yy = ixx - iyy;
198 double t2 = xx_m_yy * xx_m_yy + 4.0 * ixy * ixy;
199 Eigen::Vector3d dt2(2.0 * xx_m_yy, -2.0 * xx_m_yy, 8.0 * ixy);
205 m(0, 0) = 0.25 * (1.0 + 0.5 * dt2[0] / t) /
a;
206 m(0, 1) = 0.25 * (1.0 + 0.5 * dt2[1] / t) /
a;
207 m(0, 2) = 0.25 * (0.5 * dt2[2] / t) /
a;
208 m(1, 0) = 0.25 * (1.0 - 0.5 * dt2[0] / t) /
b;
209 m(1, 1) = 0.25 * (1.0 - 0.5 * dt2[1] / t) /
b;
210 m(1, 2) = 0.25 * (-0.5 * dt2[2] / t) /
b;
212 m.row(2).setConstant(1.0 / (t * t));
◆ _dAssignToAxes()
BaseCore::Jacobian lsst::afw::geom::ellipses::Axes::_dAssignToAxes |
( |
double & |
a, |
|
|
double & |
b, |
|
|
double & |
theta |
|
) |
| const |
|
overrideprotectedvirtual |
◆ _dAssignToQuadrupole()
BaseCore::Jacobian lsst::afw::geom::ellipses::Axes::_dAssignToQuadrupole |
( |
double & |
ixx, |
|
|
double & |
iyy, |
|
|
double & |
ixy |
|
) |
| const |
|
overrideprotectedvirtual |
◆ as()
template<typename Output >
Convert this to the core type specified as a template parameter.
Definition at line 238 of file BaseCore.h.
239 return Converter<Output>(*
this);
◆ clone()
Deep copy the ellipse core.
Definition at line 61 of file Axes.h.
61 {
return std::static_pointer_cast<Axes>(
_clone()); }
◆ computeDimensions()
Return the size of the bounding box for the ellipse core.
Definition at line 130 of file BaseCore.cc.
◆ convolve() [1/2]
Return the size of the bounding box for the ellipse core.
Definition at line 93 of file Convolution.h.
94 return BaseCore::Convolution(*
this,
other);
◆ convolve() [2/2]
Return the size of the bounding box for the ellipse core.
Definition at line 97 of file Convolution.h.
98 return BaseCore::Convolution(
const_cast<BaseCore &
>(*
this),
other);
◆ dAssign()
Assign other to this and return the derivative of the conversion, d(this)/d(other).
Definition at line 169 of file BaseCore.cc.
172 return Jacobian::Identity();
178 double ixx, iyy, ixy;
◆ getA()
double const lsst::afw::geom::ellipses::Axes::getA |
( |
| ) |
const |
|
inline |
Definition at line 51 of file Axes.h.
51 {
return _vector[
A]; }
◆ getArea()
double lsst::afw::geom::ellipses::BaseCore::getArea |
( |
| ) |
const |
|
inherited |
Return the area of the ellipse core.
Definition at line 112 of file BaseCore.cc.
◆ getB()
double const lsst::afw::geom::ellipses::Axes::getB |
( |
| ) |
const |
|
inline |
Definition at line 54 of file Axes.h.
54 {
return _vector[
B]; }
◆ getDeterminantRadius()
double lsst::afw::geom::ellipses::BaseCore::getDeterminantRadius |
( |
| ) |
const |
|
inherited |
Return the radius defined as the 4th root of the determinant of the quadrupole matrix.
The determinant radius is equal to the standard radius for a circle, and its square times pi is the area of the ellipse.
Definition at line 118 of file BaseCore.cc.
◆ getGridTransform()
Return the transform that maps the ellipse to the unit circle.
The returned proxy object is implicitly convertible to lsst::geom::LinearTransform and also supports differentiation.
Definition at line 110 of file GridTransform.h.
111 return BaseCore::GridTransform(*
this);
◆ getName()
std::string lsst::afw::geom::ellipses::Axes::getName |
( |
| ) |
const |
|
overridevirtual |
◆ getParameterVector()
Return the core parameters as a vector.
Definition at line 144 of file BaseCore.cc.
◆ getTheta()
double const lsst::afw::geom::ellipses::Axes::getTheta |
( |
| ) |
const |
|
inline |
Definition at line 57 of file Axes.h.
57 {
return _vector[
THETA]; }
◆ getTraceRadius()
double lsst::afw::geom::ellipses::BaseCore::getTraceRadius |
( |
| ) |
const |
|
inherited |
Return the radius defined as the square root of one half the trace of the quadrupole matrix.
The trace radius is equal to the standard radius for a circle.
Definition at line 124 of file BaseCore.cc.
125 double ixx, iyy, ixy;
◆ grow()
void lsst::afw::geom::ellipses::BaseCore::grow |
( |
double |
buffer | ) |
|
|
inherited |
Increase the major and minor radii of the ellipse core by the given buffer.
Definition at line 96 of file BaseCore.cc.
◆ make() [1/6]
◆ make() [2/6]
◆ make() [3/6]
◆ make() [4/6]
◆ make() [5/6]
◆ make() [6/6]
◆ normalize()
void lsst::afw::geom::ellipses::Axes::normalize |
( |
| ) |
|
|
overridevirtual |
Put the parameters into a "standard form", if possible, and throw InvalidParameterError if they cannot be normalized.
Implements lsst::afw::geom::ellipses::BaseCore.
Definition at line 36 of file Axes.cc.
37 if (_vector[
A] < 0 || _vector[
B] < 0)
39 "Major and minor axes cannot be negative.");
40 if (_vector[
A] < _vector[
B]) {
42 _vector[
THETA] += M_PI_2;
44 if (_vector[
THETA] > M_PI_2 || _vector[
THETA] <= -M_PI_2) {
◆ operator!=()
bool lsst::afw::geom::ellipses::BaseCore::operator!= |
( |
BaseCore const & |
other | ) |
const |
|
inlineinherited |
Compare two ellipse cores for inequality.
Ellipses are only equal if they have the same type.
Definition at line 167 of file BaseCore.h.
◆ operator=() [1/3]
Axes& lsst::afw::geom::ellipses::Axes::operator= |
( |
Axes && |
other | ) |
|
|
inline |
Definition at line 82 of file Axes.h.
82 {
return *
this =
other; }
◆ operator=() [2/3]
Axes& lsst::afw::geom::ellipses::Axes::operator= |
( |
Axes const & |
other | ) |
|
|
inline |
Standard assignment.
Definition at line 77 of file Axes.h.
78 _vector =
other._vector;
◆ operator=() [3/3]
Axes& lsst::afw::geom::ellipses::Axes::operator= |
( |
BaseCore const & |
other | ) |
|
|
inline |
Converting assignment.
Definition at line 85 of file Axes.h.
◆ operator==()
bool lsst::afw::geom::ellipses::BaseCore::operator== |
( |
BaseCore const & |
other | ) |
const |
|
inherited |
Compare two ellipse cores for equality.
Ellipse cores are only equal if they have the same type.
Definition at line 152 of file BaseCore.cc.
◆ readParameters()
void lsst::afw::geom::ellipses::Axes::readParameters |
( |
double const * |
iter | ) |
|
|
overridevirtual |
◆ registerSubclass()
Return the size of the bounding box for the ellipse core.
Definition at line 92 of file BaseCore.cc.
93 getRegistry()[example->getName()] = example;
◆ scale()
void lsst::afw::geom::ellipses::BaseCore::scale |
( |
double |
factor | ) |
|
|
inherited |
Scale the size of the ellipse core by the given factor.
Definition at line 104 of file BaseCore.cc.
◆ setA()
void lsst::afw::geom::ellipses::Axes::setA |
( |
double |
a | ) |
|
|
inline |
◆ setB()
void lsst::afw::geom::ellipses::Axes::setB |
( |
double |
b | ) |
|
|
inline |
◆ setParameterVector()
void lsst::afw::geom::ellipses::BaseCore::setParameterVector |
( |
ParameterVector const & |
vector | ) |
|
|
inherited |
Set the core parameters from a vector.
Definition at line 150 of file BaseCore.cc.
◆ setTheta()
void lsst::afw::geom::ellipses::Axes::setTheta |
( |
double |
theta | ) |
|
|
inline |
Definition at line 58 of file Axes.h.
58 { _vector[
THETA] = theta; }
◆ transform() [1/2]
Return the transform that maps the ellipse to the unit circle.
The returned proxy object is implicitly convertible to lsst::geom::LinearTransform and also supports differentiation.
Definition at line 116 of file Transformer.h.
117 return BaseCore::Transformer(*
this,
transform);
◆ transform() [2/2]
Return the transform that maps the ellipse to the unit circle.
The returned proxy object is implicitly convertible to lsst::geom::LinearTransform and also supports differentiation.
Definition at line 120 of file Transformer.h.
◆ writeParameters()
void lsst::afw::geom::ellipses::Axes::writeParameters |
( |
double * |
iter | ) |
const |
|
overridevirtual |
The documentation for this class was generated from the following files:
- /j/snowflake/release/lsstsw/stack/cb4e2dc/Linux64/afw/20.0.0-16-gfab17e72e+fdf35455f6/include/lsst/afw/geom/ellipses/Axes.h
- /j/snowflake/release/lsstsw/stack/cb4e2dc/Linux64/afw/20.0.0-16-gfab17e72e+fdf35455f6/src/geom/ellipses/Axes.cc
virtual void _assignToQuadrupole(double &ixx, double &iyy, double &ixy) const =0
Return the size of the bounding box for the ellipse core.
constexpr double PI
The ratio of a circle's circumference to diameter.
double const getB() const
void normalize() override
Put the parameters into a "standard form", if possible, and throw InvalidParameterError if they canno...
BaseCore()=default
Return the size of the bounding box for the ellipse core.
virtual void writeParameters(double *iter) const =0
Return the size of the bounding box for the ellipse core.
static Jacobian _dAssignAxesToQuadrupole(double a, double b, double theta, double &ixx, double &iyy, double &ixy)
Return the size of the bounding box for the ellipse core.
double const getTheta() const
ParameterVector const getParameterVector() const
Return the core parameters as a vector.
bool operator==(BaseCore const &other) const
Compare two ellipse cores for equality.
virtual void _assignToAxes(double &a, double &b, double &theta) const =0
Return the size of the bounding box for the ellipse core.
double const getA() const
static Jacobian _dAssignQuadrupoleToAxes(double ixx, double iyy, double ixy, double &a, double &b, double &theta)
Return the size of the bounding box for the ellipse core.
virtual void readParameters(double const *iter)=0
Return the size of the bounding box for the ellipse core.
ItemVariant const * other
Eigen::Vector3d ParameterVector
Parameter vector type.
std::shared_ptr< BaseCore > _clone() const override
Return the size of the bounding box for the ellipse core.
Axes(double a=1.0, double b=1.0, double theta=0.0, bool normalize=false)
Construct from parameter values.
afw::table::PointKey< int > dimensions
#define LSST_EXCEPT(type,...)
Create an exception with a given type.
void setTheta(double theta)
virtual Jacobian _dAssignFromQuadrupole(double ixx, double iyy, double ixy)=0
Return the size of the bounding box for the ellipse core.
Eigen::Matrix3d Jacobian
Parameter Jacobian matrix type.
Reports invalid arguments.
static void _assignAxesToQuadrupole(double a, double b, double theta, double &ixx, double &iyy, double &ixy)
Return the size of the bounding box for the ellipse core.
virtual std::string getName() const =0
Return a string that identifies this parametrization.
Transformer transform(lsst::geom::LinearTransform const &transform)
Return the transform that maps the ellipse to the unit circle.
BaseCore & operator=(BaseCore const &other)
Set the parameters of this ellipse core from another.
virtual void _assignFromAxes(double a, double b, double theta)=0
Return the size of the bounding box for the ellipse core.
static void _assignQuadrupoleToAxes(double ixx, double iyy, double ixy, double &a, double &b, double &theta)
Return the size of the bounding box for the ellipse core.