prysm v0.19#

This release focuses on increasing the capability of prysm for multi-plane diffraction modeling and includes other improvements to quality of life.

New Features#

API Fluency#

  • astype() function for converting between the various object types. This can be used to dip into another type momentarily for one of its methods, e.g. chaining p = Pupil() p.astype(Interferogram).crop(...).astype(Pupil).

Propagation#

In this release, prysm has gained increased capability for performing propagations outside of the pupil-to-image case. The API has also been revised for reduced verbosity and better clarity. The old API is provided with deprecations to ease transition. A demo showing more than two order of magnitude performance improvement is available Polychromatic Propagations.

Aliases with deprecation warnings:

  • prop_pupil_plane_to_psf_plane() -> focus()

  • prop_pupil_plane_to_psf_plane_units() -> focus_units()

Thin Film Calculation and Refractive Indices#

Prysm can now do basic multi-layer thin film calculations and compute a few related values.

I/O#

Prysm can now parse MTF vs Field files from Trioptics MTF-Lab v5 software. The previous parser is compatible with v4 and is untouched.

Note that the existing functions without mtflab_v5 suffixes now issue warnings that their behavior will change in v0.20. At that time, they will sense whether the file is from v4 or v5 and dispatch appropriately.

Documentation#

The docstrings of the ZCacheMN class were expanded. These should aid developers in understanding the code.

Bug fixes#

  • save() now flips the array before writing, rendering images in the expected orientation.

  • from_pupil() now passes the incoherent and norm arguments to the propagation engine

  • the Pupil constructor no longer ignores the phase parameter

  • the Pupil constructor no longer ignores the transmission parameter

  • Wavefront no longer errors on construction

  • zernikefit() no longer causes a memory leak

  • n_m_to_fringe() no longer begins counting fringe indices at 0 and does not mis-order azimuthal orders when radial order >14.

Removed Deprecations#

  • MTF.exact_tan has been removed and was marked for removal in v0.18

  • MTF.exact_sag has been removed and was marked for removal in v0.18

  • MTF.tan has been removed and was marked for removal in v0.18

  • MTF.sag has been removed and was marked for removal in v0.18

  • RichData.slice_x has been removed and was marked for removal in v0.18

  • RichData.slice_y has been removed and was marked for removal in v0.18

  • the base kwarg which controlled whether indices start at 0 or 1 has been removed from the Zernike classes and was marked for removal in v0.19

Test Coverage#

  • The integration between travis and coveralls has been fixed

  • the test suite now provides over 80% coverage and includes over 500 tests