Utility functions

Utility functions#

Module util provides a set of useful helpers which are currently not attributable to the other modules

aspect

Compute an aspect ratio that equalizes physical axis lengths.

from_to

Return a list of timesteps from <tstart> to <tend> of length <tdelta>

filter_window_polar

Apply a filter of an approximated square window of half size fsize on a given polar image img.

filter_window_cartesian

Apply a filter of square window size fsize on a given cartesian image img.

find_bbox_indices

Find min/max-indices for NxMx2 array coords using bbox-values.

get_raster_origin

Return raster origin

half_power_radius

Half-power radius.

calculate_polynomial

Calculate Polynomial

core_dims

Determine core dimensions for use with xarray.apply_ufunc.

crop

Crop a 2D DataArray to the spatial extent of another DataArray, optionally extending the crop by a given number of grid cells.

derivate

Calculates derivative of data using window of length winlen.

despeckle

Remove floating pixels in between NaNs in a multidimensional array.

import_optional

Allowing for lazy loading of optional wradlib modules or dependencies.

cross_section_ppi

Cut a cross-section from PPI volume scans

UtilMethods

wradlib xarray SubAccessor methods for Util.