prtools.mesh#

mesh(shape, shift=(0, 0), angle=0, indexing='ij')[source]#

Generate a standard mesh.

Parameters:
  • shape (array_like) – Size of output in pixels (nrows, ncols)

  • shift ((2,) array_like, optional) – Coordinate translation from center of containing array. Default is (0, 0). Shift is applied according to the specified indexing scheme.

  • angle (float, optional) – Mesh rotation in degrees. When indexing = 'xy' the rotation is measured from the +x axis toward the +y axis. When indexing = 'ij' the rotation is measured from the +i axis toward the +j axis. Note that rotations occur about the shifted center if shift is nonzero. Default is 0.

  • indexing ({'ij', 'xy'}, optional) – Matrix (‘ij’, default) or Cartesian (‘xy’) indexing of mesh.

Return type:

list of ndarrays