transform_vectors

Equi7Grid_projection.transform_vectors(src_proj, x, y, u, v)

Transform the given vector components, with coordinates in the given source coordinate system (src_proj), to this coordinate system. The vector components must be given relative to the source projection’s coordinate reference system (grid eastward and grid northward).

Parameters:
  • src_proj – The CRS.Projection that represents the coordinate system the vectors are defined in.

  • x – The x coordinates of the vectors in the source projection.

  • y – The y coordinates of the vectors in the source projection.

  • u – The grid-eastward components of the vectors.

  • v – The grid-northward components of the vectors.

Note

x, y, u and v may be 1 or 2 dimensional, but must all have matching shapes.

Returns:

ut, vt

Return type:

The transformed vector components.

Note

The algorithm used to transform vectors is an approximation rather than an exact transform, but the accuracy should be good enough for visualization purposes.