lsst.afw  21.0.0-10-g68cce58c5+c7d3cce47e
Public Member Functions | List of all members
lsst::afw::math::WarpingControl Class Reference

Parameters to control convolution. More...

#include <warpExposure.h>

Public Member Functions

 WarpingControl (std::string const &warpingKernelName, std::string const &maskWarpingKernelName="", int cacheSize=0, int interpLength=0, lsst::afw::image::MaskPixel growFullMask=0)
 Construct a WarpingControl object. More...
 
virtual ~WarpingControl ()
 
int getCacheSize () const
 get the cache size for the interpolation kernel(s) More...
 
void setCacheSize (int cacheSize)
 set the cache size for the interpolation kernel(s) More...
 
int getInterpLength () const
 get the interpolation length (pixels) More...
 
void setInterpLength (int interpLength)
 set the interpolation length More...
 
std::shared_ptr< SeparableKernelgetWarpingKernel () const
 get the warping kernel More...
 
void setWarpingKernelName (std::string const &warpingKernelName)
 set the warping kernel by name More...
 
void setWarpingKernel (SeparableKernel const &warpingKernel)
 set the warping kernel More...
 
std::shared_ptr< SeparableKernelgetMaskWarpingKernel () const
 get the mask warping kernel More...
 
bool hasMaskWarpingKernel () const
 return true if there is a mask kernel More...
 
void setMaskWarpingKernelName (std::string const &maskWarpingKernelName)
 set or clear the mask warping kernel by name More...
 
void setMaskWarpingKernel (SeparableKernel const &maskWarpingKernel)
 set the mask warping kernel More...
 
lsst::afw::image::MaskPixel getGrowFullMask () const
 get mask bits to grow to full width of image/variance kernel More...
 
void setGrowFullMask (lsst::afw::image::MaskPixel growFullMask)
 set mask bits to grow to full width of image/variance kernel More...
 

Detailed Description

Parameters to control convolution.

Note
padValue is not member of this class to avoid making this a templated class.

Definition at line 250 of file warpExposure.h.

Constructor & Destructor Documentation

◆ WarpingControl()

lsst::afw::math::WarpingControl::WarpingControl ( std::string const &  warpingKernelName,
std::string const &  maskWarpingKernelName = "",
int  cacheSize = 0,
int  interpLength = 0,
lsst::afw::image::MaskPixel  growFullMask = 0 
)
inlineexplicit

Construct a WarpingControl object.

Exceptions
pex::exceptions::InvalidParameterErrorif the warping kernel is smaller than the mask warping kernel.
Parameters
warpingKernelNamename of warping kernel; used as the argument to makeWarpingKernel
maskWarpingKernelNamename of warping kernel used for the mask plane; if "" then the regular warping kernel is used. Intended so one can use a bilinear kernel or other compact kernel for the mask plane to avoid smearing mask bits too far. The theory is that bad pixels are already interpolated over, so we don't need to worry about bad values spreading very far.
cacheSizecache size for warping kernel; no cache if 0 (used as the argument to the warping kernels' computeCache method)
interpLengthdistance over which the WCS can be linearly interpolated
growFullMaskmask bits to grow to full width of image/variance kernel

Definition at line 258 of file warpExposure.h.

◆ ~WarpingControl()

virtual lsst::afw::math::WarpingControl::~WarpingControl ( )
inlinevirtual

Definition at line 280 of file warpExposure.h.

Member Function Documentation

◆ getCacheSize()

int lsst::afw::math::WarpingControl::getCacheSize ( ) const
inline

get the cache size for the interpolation kernel(s)

Definition at line 285 of file warpExposure.h.

◆ getGrowFullMask()

lsst::afw::image::MaskPixel lsst::afw::math::WarpingControl::getGrowFullMask ( ) const
inline

get mask bits to grow to full width of image/variance kernel

Definition at line 365 of file warpExposure.h.

◆ getInterpLength()

int lsst::afw::math::WarpingControl::getInterpLength ( ) const
inline

get the interpolation length (pixels)

Definition at line 303 of file warpExposure.h.

◆ getMaskWarpingKernel()

std::shared_ptr< SeparableKernel > lsst::afw::math::WarpingControl::getMaskWarpingKernel ( ) const

get the mask warping kernel

Definition at line 200 of file warpExposure.cc.

◆ getWarpingKernel()

std::shared_ptr< SeparableKernel > lsst::afw::math::WarpingControl::getWarpingKernel ( ) const

get the warping kernel

Definition at line 179 of file warpExposure.cc.

◆ hasMaskWarpingKernel()

bool lsst::afw::math::WarpingControl::hasMaskWarpingKernel ( ) const
inline

return true if there is a mask kernel

Definition at line 345 of file warpExposure.h.

◆ setCacheSize()

void lsst::afw::math::WarpingControl::setCacheSize ( int  cacheSize)
inline

set the cache size for the interpolation kernel(s)

A value of 0 disables the cache for maximum accuracy. 10,000 typically results in a warping error of a fraction of a count. 100,000 typically results in a warping error of less than 0.01 count. Note the new cache is not computed until getWarpingKernel or getMaskWarpingKernel is called.

Parameters
cacheSizecache size

Definition at line 295 of file warpExposure.h.

◆ setGrowFullMask()

void lsst::afw::math::WarpingControl::setGrowFullMask ( lsst::afw::image::MaskPixel  growFullMask)
inline

set mask bits to grow to full width of image/variance kernel

Parameters
growFullMaskmask bits to grow to full width of image/variance kernel

Definition at line 370 of file warpExposure.h.

◆ setInterpLength()

void lsst::afw::math::WarpingControl::setInterpLength ( int  interpLength)
inline

set the interpolation length

Interpolation length is the distance over which the WCS can be linearly interpolated, in pixels:

  • 0 means no interpolation and uses an optimized branch of the code
  • 1 also performs no interpolation but it runs the interpolation code branch (and so is only intended for unit tests)
Parameters
interpLengthinterpolation length (pixels)

Definition at line 313 of file warpExposure.h.

◆ setMaskWarpingKernel()

void lsst::afw::math::WarpingControl::setMaskWarpingKernel ( SeparableKernel const &  maskWarpingKernel)

set the mask warping kernel

Note
To clear the mask warping kernel use setMaskWarpingKernelName("").
Parameters
maskWarpingKernelmask warping kernel

Definition at line 218 of file warpExposure.cc.

◆ setMaskWarpingKernelName()

void lsst::afw::math::WarpingControl::setMaskWarpingKernelName ( std::string const &  maskWarpingKernelName)

set or clear the mask warping kernel by name

Parameters
maskWarpingKernelNamename of mask warping kernel; use "" to clear the kernel

Definition at line 209 of file warpExposure.cc.

◆ setWarpingKernel()

void lsst::afw::math::WarpingControl::setWarpingKernel ( SeparableKernel const &  warpingKernel)

set the warping kernel

Exceptions
lsst::pex::exceptions::InvalidParameterErrorif new kernel pointer is empty.
Parameters
warpingKernelwarping kernel

Definition at line 191 of file warpExposure.cc.

◆ setWarpingKernelName()

void lsst::afw::math::WarpingControl::setWarpingKernelName ( std::string const &  warpingKernelName)

set the warping kernel by name

Parameters
warpingKernelNamename of warping kernel

Definition at line 186 of file warpExposure.cc.


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