English

Pty-Chi: A PyTorch-based modern ptychographic data analysis package

Optics 2025-10-27 v1 Mathematical Software Numerical Analysis Numerical Analysis Data Analysis, Statistics and Probability

Abstract

Ptychography has become an indispensable tool for high-resolution, non-destructive imaging using coherent light sources. The processing of ptychographic data critically depends on robust, efficient, and flexible computational reconstruction software. We introduce Pty-Chi, an open-source ptychographic reconstruction package built on PyTorch that unifies state-of-the-art analytical algorithms with automatic differentiation methods. Pty-Chi provides a comprehensive suite of reconstruction algorithms while supporting advanced experimental parameter corrections such as orthogonal probe relaxation and multislice modeling. Leveraging PyTorch as the computational backend ensures vendor-agnostic GPU acceleration, multi-device parallelization, and seamless access to modern optimizers. An object-oriented, modular design makes Pty-Chi highly extendable, enabling researchers to prototype new imaging models, integrate machine learning approaches, or build entirely new workflows on top of its core components. We demonstrate Pty-Chi's capabilities through challenging case studies that involve limited coherence, low overlap, and unstable illumination during scanning, which highlight its accuracy, versatility, and extensibility. With community-driven development and open contribution, Pty-Chi offers a modern, maintainable platform for advancing computational ptychography and for enabling innovative imaging algorithms at synchrotron facilities and beyond.

Keywords

Cite

@article{arxiv.2510.20929,
  title  = {Pty-Chi: A PyTorch-based modern ptychographic data analysis package},
  author = {Ming Du and Hanna Ruth and Steven Henke and Yi Jiang and Viktor Nikitin and Ashish Tripathi and Junjing Deng and Jeffrey Klug and Peco Myint and Tao Zhou and Nicholas Schwarz and Mathew Cherukara and Alec Sandy and Stefan Vogt},
  journal= {arXiv preprint arXiv:2510.20929},
  year   = {2025}
}
R2 v1 2026-07-01T07:02:53.958Z