LSST Applications  21.0.0-172-gfb10e10a+18fedfabac,22.0.0+297cba6710,22.0.0+80564b0ff1,22.0.0+8d77f4f51a,22.0.0+a28f4c53b1,22.0.0+dcf3732eb2,22.0.1-1-g7d6de66+2a20fdde0d,22.0.1-1-g8e32f31+297cba6710,22.0.1-1-geca5380+7fa3b7d9b6,22.0.1-12-g44dc1dc+2a20fdde0d,22.0.1-15-g6a90155+515f58c32b,22.0.1-16-g9282f48+790f5f2caa,22.0.1-2-g92698f7+dcf3732eb2,22.0.1-2-ga9b0f51+7fa3b7d9b6,22.0.1-2-gd1925c9+bf4f0e694f,22.0.1-24-g1ad7a390+a9625a72a8,22.0.1-25-g5bf6245+3ad8ecd50b,22.0.1-25-gb120d7b+8b5510f75f,22.0.1-27-g97737f7+2a20fdde0d,22.0.1-32-gf62ce7b1+aa4237961e,22.0.1-4-g0b3f228+2a20fdde0d,22.0.1-4-g243d05b+871c1b8305,22.0.1-4-g3a563be+32dcf1063f,22.0.1-4-g44f2e3d+9e4ab0f4fa,22.0.1-42-gca6935d93+ba5e5ca3eb,22.0.1-5-g15c806e+85460ae5f3,22.0.1-5-g58711c4+611d128589,22.0.1-5-g75bb458+99c117b92f,22.0.1-6-g1c63a23+7fa3b7d9b6,22.0.1-6-g50866e6+84ff5a128b,22.0.1-6-g8d3140d+720564cf76,22.0.1-6-gd805d02+cc5644f571,22.0.1-8-ge5750ce+85460ae5f3,master-g6e05de7fdc+babf819c66,master-g99da0e417a+8d77f4f51a,w.2021.48
LSST Data Management Base Package
Public Member Functions | Public Attributes | List of all members
lsst::afw::geom::SipApproximation::Grid Struct Reference

Public Member Functions

 Grid (lsst::geom::Extent2I const &shape_, SipApproximation const &parent)
 

Public Attributes

lsst::geom::Extent2I const shape
 
std::vector< lsst::geom::Point2Ddpix1
 
std::vector< lsst::geom::Point2Dsiwc
 
std::vector< lsst::geom::Point2Ddpix2
 

Detailed Description

Definition at line 108 of file SipApproximation.cc.

Constructor & Destructor Documentation

◆ Grid()

lsst::afw::geom::SipApproximation::Grid::Grid ( lsst::geom::Extent2I const &  shape_,
SipApproximation const &  parent 
)

Definition at line 159 of file SipApproximation.cc.

159  :
160  shape(shape_),
161  dpix1(makeGrid(parent._bbox, shape)),
162  siwc(parent._pixelToIwc->applyForward(dpix1))
163 {
164  // Apply the CRPIX offset to make pix1 into dpix1 (in-place)
165  std::for_each(dpix1.begin(), dpix1.end(), [&parent](lsst::geom::Point2D & p){ p -= parent._crpix; });
166 
167  if (parent._useInverse) {
168  // Set from the given inverse of the given pixels-to-iwc transform
169  // Note that at this point, siwc is still just iwc, because the scaling by cdInv is later.
170  dpix2 = parent._pixelToIwc->applyInverse(siwc);
171  // Apply the CRPIX offset to make pix1 into dpix2 (in-place)
172  std::for_each(dpix2.begin(), dpix2.end(), [&parent](lsst::geom::Point2D & p){ p -= parent._crpix; });
173  } else {
174  // Just make dpix2 = dpix1, and hence fit to the true inverse of pixels-to-iwc.
175  dpix2 = dpix1;
176  }
177 
178  // Apply the CD^{-1} transform to siwc
179  std::for_each(siwc.begin(), siwc.end(), [&parent](lsst::geom::Point2D & p){ p = parent._cdInv(p); });
180 }
T for_each(T... args)
std::vector< lsst::geom::Point2D > dpix1
std::vector< lsst::geom::Point2D > dpix2
std::vector< lsst::geom::Point2D > siwc

Member Data Documentation

◆ dpix1

std::vector<lsst::geom::Point2D> lsst::afw::geom::SipApproximation::Grid::dpix1

Definition at line 114 of file SipApproximation.cc.

◆ dpix2

std::vector<lsst::geom::Point2D> lsst::afw::geom::SipApproximation::Grid::dpix2

Definition at line 116 of file SipApproximation.cc.

◆ shape

lsst::geom::Extent2I const lsst::afw::geom::SipApproximation::Grid::shape

Definition at line 113 of file SipApproximation.cc.

◆ siwc

std::vector<lsst::geom::Point2D> lsst::afw::geom::SipApproximation::Grid::siwc

Definition at line 115 of file SipApproximation.cc.


The documentation for this struct was generated from the following file: