pyinterp.core.geodetic.RTree.window_function¶
- RTree.window_function(self: pyinterp.core.geodetic.RTree, lon: numpy.ndarray[numpy.float64[m, 1]], lat: numpy.ndarray[numpy.float64[m, 1]], radius: float = None, k: int = 9, wf: pyinterp.core.WindowFunction = <WindowFunction.Hamming: 5>, arg: Optional[float] = None, within: bool = True, num_threads: int = 0) tuple ¶
Interpolation of the value at the requested position by window function.
- Parameters:
lon – The longitude of the points, in degrees, to be interpolated.
lat – The latitude of the points, in degrees, to be interpolated.
radius – The maximum radius of the search (m). Default to the largest value that can be represented on a float.
k – The number of nearest neighbors to be used for calculating the interpolated value. Defaults to
9
.wf – The window function to be used. Defaults to
pyinterp.core.WindowFunction.Hamming
.arg – The optional argument of the window function. Defaults to
None
.within – If true, the method ensures that the neighbors found are located around the point of interest. Defaults to
true
.num_threads – The number of threads to use for the computation. If 0 all CPUs are used. If 1 is given, no parallel computing code is used at all, which is useful for debugging. Defaults to
0
.
- Returns:
The interpolated value and the number of neighbors used for the calculation.