windkit.spatial.reproject

windkit.spatial.reproject(obj, to_crs, copy=True)[source]

Reprojects WindKit object a new CRS without changing the data.

If the input is a xarray.Dataset or xarray.DataArray with a ‘cuboid’ spatial structure, the spatial structure will be changed to ‘point’, since the coordiates of the new dataset will no longer be regularly spaced.

Parameters:
Returns:

WindKit object with new projection

Return type:

geopandas.GeoDataFrame, xarray.DataArray,xarray.Dataset, or BBox

See also

warp

Notes

This script reprojects the coordinates of the data, and potentially reshapes the data from 2D to 1D in geographic space. This is done so that none of the data is interpolated, but rather the coordinates are just changed to match those of the new projection.