def test_array_orientation_consistency_tilt():
''' The pupil array should be shaped as arr[x,y], as should the psf and MTF.
A linear phase error in the pupil along y should cause a motion of the
PSF in y. Specifically, for a positive-signed phase, that should cause
a shift in the +y direction.
'''
samples = 128
p = Seidel(W111=1, samples=samples)
ps = PSF.from_pupil(p, 1)
idx_y, idx_x = np.unravel_index(ps.data.argmax(), ps.data.shape) # row-major y, x
assert idx_x == ps.center_x
assert idx_y > ps.center_y
评论列表
文章目录