sup3r.utilities.utilities.invert_uv

invert_uv(u, v, lat_lon)[source]

Transform u and v back to windspeed and winddirection

Parameters:
  • u (np.ndarray) – 3D array of high res U data (spatial_1, spatial_2, temporal)

  • v (np.ndarray) – 3D array of high res V data (spatial_1, spatial_2, temporal)

  • lat_lon (np.ndarray) – 3D array of lat lon (spatial_1, spatial_2, 2) Last dimension has lat / lon in that order

Returns:

  • ws (np.ndarray) – 3D array of high res windspeed data (spatial_1, spatial_2, temporal)

  • wd (np.ndarray) – 3D array of high res winddirection data. Angle is in degrees and measured relative to the south_north direction. (spatial_1, spatial_2, temporal)