def convert_segmentation_mat2numpy(mat_file): np_segm = load_mat(mat_file) return np.rot90(np.fliplr(np.argmax(np_segm, axis=2)))