windspharm interfaces¶
windspharm
uses different interfaces to work with different kinds of input data.
Descriptions of each interface are below, and are summarised in the following table:
Interface |
Description |
---|---|
iris |
Data contained in an |
xarray |
Data contained in an |
standard |
Other data, stored in a |
Iris interface¶
The iris interface works with Cube
objects, which are the data containers used by the iris data analysis package.
The meta-data, including coordinate dimensions, associated with iris Cube objects is understood by the windspharm.iris.VectorWind
interface.
The outputs of windspharm.iris.VectorWind
methods are also contained in Cube
objects, meaning they can be used with tools in the iris package, and easily written to a file.
xarray interface¶
The xarray interface works with DataArray
objects.
The coordinate metadata of DataArray
is interpreted by the windspharm.xarray.VectorWind
interface, and the outputs of the windspharm.xarray.VectorWind
methods are contained in DataArray
objects allowing their use with othe tools from the xarray
package.
standard interface¶
The standard interface works with numpy
arrays, which makes the standard interface the general purpose interface. Any data that can be stored in a numpy.ndarray
can be analysed with the windspharm.standard.VectorWind
interface.