wrf.specialdec.uvmet_left_iter

wrf.specialdec.uvmet_left_iter(alg_dtype=<MagicMock id='140499238525648'>)

A decorator to handle iterating over the leftmost dimensions for the uvmet diagnostic.

For example, if a wrapped function works with three-dimensional arrays, but the variables include a 4th leftmost dimension for ‘Time’, this decorator will iterate over all times, call the 3D Fortran routine, and aggregate the results in to a 4D output array.

It is also important to note that the final output array is allocated first, and then views are passed to the wrapped function so that values do not need to get copied in to the final output array.

Parameters:

alg_dtype (np.dtype or str) – The numpy data type used in the wrapped function.

Returns:

The aggregated uvmet output array that includes all extra leftmost dimensions.

Return type:

numpy.ndarray