ZOSPy
Actively maintainedA Python wrapper for the Zemax OpticStudio API, enabling reproducible optical ray-tracing simulations.

About
ZOSPy wraps the Ansys (Zemax) OpticStudio API in a more pythonic, well-documented interface, hiding the often verbose .NET-based ZOS-API behind readable, autocompletable function calls. This allows researchers to script and share optical ray-tracing simulations as ordinary Python code or Jupyter notebooks, instead of relying on manual, hard-to-reproduce interaction with the OpticStudio GUI.
Beyond the core API wrapper, ZOSPy bundles ready-made functions for common OpticStudio analyses, solvers and API constants, together with autocomplete support and a unit-test suite that guards against regressions when OpticStudio itself is updated. The package is developed by the MReye group with funding from an NWO Open Science grant, and is used internally for ray-tracing studies of intraocular lens design and ocular radiotherapy planning. It is also supported by many contributors outside our group, spanning multiple fields including optics research and astronomy.
Main Contributors
Publications that use this software
- Nguyen, Wilde, Uhlmann, Smith, Kusch-Wieser, Zanrè, Schwiedrzik and Csúcs
(2026), doi: 10.64898/2026.02.24.707711 - Zhu, Wang and Zhang
Fifth International Computational Imaging Conference (CITA 2025) (2026), doi: 10.1117/12.3093653 - Haasjes, Vu and Beenakker
Medical Physics (2025), doi: 10.1002/mp.17576 - Kneepkens, Vught, Polling, Klaver, Tideman and Beenakker
American Journal of Ophthalmology (2025), doi: 10.1016/j.ajo.2025.06.013 - Parant, Paquet-Mercier, Marquet and Thibault
Optica Imaging Congress 2025 (3D, DH, COSI, IS, pcAOP,RadIT) (2025), doi: 10.1364/DH.2025.DW4A.3 - Vught, Haasjes and Beenakker
Journal of Open Source Software (2024), doi: 10.21105/joss.05756 - Pors, Haasjes, Vught, Hoes, Luyten, Rijn, Vu, Rasch, Horeweg and Beenakker
Investigative Opthalmology & Visual Science (2024), doi: 10.1167/iovs.65.1.43 - Vught, Luyten and Beenakker
Journal of Cataract & Refractive Surgery (2023), doi: 10.1097/j.jcrs.0000000000001299 - Vught, Que, Luyten and Beenakker
Journal of Cataract & Refractive Surgery (2022), doi: 10.1097/j.jcrs.0000000000001054