orthogonalize_modes_vec_np#
- ptyrad.utils.physics.orthogonalize_modes_vec_np(modes, sort=False)[source]#
Orthogonalize the modes using SVD-like procedure via eigen decomposition.
- Parameters:
modes (np.ndarray) – Input modes of shape (Nmode, Ny, Nx), complex.
sort (bool, optional) – Whether to sort modes by their intensity (norm), by default False.
- Returns:
Orthogonalized modes of the same shape as input.
- Return type:
np.ndarray