slmsuite.holography.analysis.get_orientation_transformation

get_orientation_transformation(rot='0', fliplr=False, flipud=False)[source]

Compile a transformation lambda from simple rotates and flips.

Useful to turn an image to an orientation which is user-friendly. Used by Camera and subclasses.

Parameters
  • rot (str OR int) – Rotates returned image by the corresponding degrees in ["90", "180", "270"] or numpy.rot90() code in [1, 2, 3]. Defaults to no rotation otherwise.

  • fliplr (bool) – Flips returned image left right.

  • flipud (bool) – Flips returned image up down.

Returns

Compiled image transformation.

Return type

function (array_like) -> numpy.ndarray