mxlib
c++ tools for analyzing astronomical data and other tasks by Jared R. Males. [git repo]
imageFilters.hpp File Reference

Image filters (smoothing, radial profiles, etc.) More...

Image filters (smoothing, radial profiles, etc.)

Author
Jared R. Males (jared.nosp@m.male.nosp@m.s@gma.nosp@m.il.c.nosp@m.om)

Definition in file imageFilters.hpp.

Go to the source code of this file.

Classes

struct  mx::improc::gaussKernel< _arrayT, _kernW >
 Symetric Gaussian smoothing kernel. More...
 
struct  mx::improc::azBoxKernel< _arrayT, _kernW >
 Azimuthally variable boxcare kernel. More...
 

Namespaces

 mx
 The mxlib c++ namespace.
 

Functions

template<typename imageOutT , typename imageInT , typename kernelT >
void mx::improc::filterImage (imageOutT &fim, imageInT im, kernelT kernel, int maxr=0)
 Filter an image with a mean kernel. More...
 
template<typename imageTout , typename imageTin >
int mx::improc::meanSmooth (imageTout &imOut, const imageTin &imIn, int meanFullWidth, bool rejectMinMax=false)
 Smooth an image using the mean in a rectangular box, optionally rejecting the highest and lowest values. More...
 
template<typename imageTout , typename imageTin >
int mx::improc::meanSmooth (imageTout &imOut, int &xMax, int &yMax, typename imageTout::Scalar &pMax, const imageTin &imIn, int meanFullWidth, bool rejectMinMax=false)
 Smooth an image using the mean in a rectangular box, optionally rejecting the highest and lowest values. Determines the location and value of the highest pixel. More...
 
template<typename imageTout , typename imageTin >
int mx::improc::medianSmooth (imageTout &imOut, int &xMax, int &yMax, typename imageTout::Scalar &pMax, const imageTin &imIn, int medianFullWidth)
 Smooth an image using the median in a rectangular box. Also Determines the location and value of the highest pixel in the smoothed image. More...
 
template<typename imageTout , typename imageTin >
int mx::improc::medianSmooth (imageTout &imOut, const imageTin &imIn, int medianFullWidth)
 Smooth an image using the median in a rectangular box.
More...
 
template<typename eigenImT >
void mx::improc::rowEdgeMedSubtract (eigenImT &im, int ncols)
 
template<typename eigenImT >
void mx::improc::colEdgeMedSubtract (eigenImT &im, int nrows)
 
template<typename vecT , typename eigenImT1 , typename eigenImT2 , typename eigenImT3 >
void mx::improc::radprof (vecT &rad, vecT &prof, const eigenImT1 &im, const eigenImT2 &radim, const eigenImT3 *mask, bool mean=false, typename eigenImT1::Scalar minr=0)
 Calculate the the radial profile. More...
 
template<typename vecT , typename eigenImT1 , typename eigenImT2 >
void mx::improc::radprof (vecT &rad, vecT &prof, const eigenImT1 &im, const eigenImT2 &mask, bool mean=false)
 Calculate the the radial profile. More...
 
template<typename vecT , typename eigenImT1 >
void mx::improc::radprof (vecT &rad, vecT &prof, const eigenImT1 &im, bool mean=false, double dr=1)
 Calculate the the radial profile. More...
 
template<typename radprofT , typename eigenImT1 , typename eigenImT2 , typename eigenImT3 >
void mx::improc::radprofim (radprofT &radprofIm, eigenImT1 &im, const eigenImT2 &rad, const eigenImT3 *mask, bool subtract, bool mean=false)
 Form a radial profile image, and optionally subtract it from the input. More...
 
template<typename radprofT , typename eigenImT >
void mx::improc::radprofim (radprofT &radprof, eigenImT &im, bool subtract=false, bool mean=false)
 Form a radial profile image, and optionally subtract it from the input. More...
 
template<typename eigenImT , typename eigenImT1 , typename eigenImT2 , typename eigenImT3 >
void mx::improc::stddevImage (eigenImT &stdIm, const eigenImT1 &im, const eigenImT2 &rad, const eigenImT3 &mask, typename eigenImT::Scalar minRad, typename eigenImT::Scalar maxRad, bool divide)
 Form a standard deviation image, and optionally divide the input by it to form a S/N map. More...
 
template<typename eigenImT , typename eigenImT1 , typename eigenImT2 >
void mx::improc::stddevImage (eigenImT &stdIm, const eigenImT1 &im, const eigenImT2 &mask, typename eigenImT::Scalar minRad, typename eigenImT::Scalar maxRad, bool divide=false)
 Form a standard deviation image, and optionally divide the input by it to form a S/N map. More...
 
template<typename eigenCubeT , typename eigenCubeT1 , typename eigenImT >
void mx::improc::stddevImageCube (eigenCubeT &stdImc, const eigenCubeT1 &imc, const eigenImT &mask, typename eigenImT::Scalar minRad, typename eigenImT::Scalar maxRad, bool divide=false)
 Form a standard deviation image for each imamge in a cube, and optionally divide the input by it forming a S/N map cube. More...
 

Function Documentation

◆ colEdgeMedSubtract()

template<typename eigenImT >
void mx::improc::colEdgeMedSubtract ( eigenImT &  im,
int  nrows 
)
Parameters
imThe image to filter
nrowsThe number of rows on each side of the image to use as the reference

Definition at line 760 of file imageFilters.hpp.

References mx::improc::colEdgeMedSubtract().

Referenced by mx::improc::colEdgeMedSubtract().

◆ rowEdgeMedSubtract()

template<typename eigenImT >
void mx::improc::rowEdgeMedSubtract ( eigenImT &  im,
int  ncols 
)
Parameters
imThe image to filter
ncolsThe number of columns on each side of the image to use as the reference

Definition at line 733 of file imageFilters.hpp.

References mx::improc::rowEdgeMedSubtract().

Referenced by mx::improc::rowEdgeMedSubtract().