BkgIDWInterpolator#
- class photutils.background.BkgIDWInterpolator(*, leafsize=10, n_neighbors=10, power=1.0, regularization=0.0)[source]#
Bases:
objectDeprecated since version 3.0: BkgIDWInterpolator is deprecated and will be removed in a version 4.0.
Class to generate a full-sized background and background RMS images from lower-resolution mesh images using inverse-distance weighting (IDW) interpolation (
ShepardIDWInterpolator).This class must be used in concert with the
Background2Dclass.- Parameters:
- leafsizefloat, optional
The number of points at which the k-d tree algorithm switches over to brute-force.
leafsizemust be positive. Seescipy.spatial.cKDTreefor further information.- n_neighborsint, optional
The maximum number of nearest neighbors to use during the interpolation.
- powerfloat, optional
The power of the inverse distance used for the interpolation weights.
- regularizationfloat, optional
The regularization parameter. It may be used to control the smoothness of the interpolator.
Deprecated since version 3.0: BkgIDWInterpolator is deprecated and will be removed in a version 4.0.
Methods Summary
__call__(data, **kwargs)Resize the 2D mesh array.
Methods Documentation
- __call__(data, **kwargs)[source]#
Resize the 2D mesh array.
- Parameters:
- data2D
ndarray The low-resolution 2D mesh array.
- **kwargsdict
Additional keyword arguments passed to the interpolator.
- data2D
- Returns:
- result2D
ndarray The resized background or background RMS image.
- result2D
Notes
If
datais anQuantity, units are stripped before interpolation. Unit re-assignment is the caller’s responsibility.