optorch: An Open-Source PyTorch Framework for Diffractive Deep Neural Networks

optorch is an open-source Python framework for simulating, training, and deploying Diffractive Deep Neural Networks (D2NNs). Unlike conventional neural networks that rely on electronic matrix multiplication, optical neural networks compute through the physical diffraction of light, enabling ultra-low-latency and energy-efficient AI inference. Built on the Angular Spectrum Method, optorch provides fully differentiable light propagation simulation in a PyTorch-native workflow. A 3-layer D2NN trained with optorch achieves 89.79% MNIST test accuracy using only 2,352 learnable parameters, training in approximately 2 minutes on a standard CPU — within 2% of the original 2018 MIT Science paper while using 340× fewer parameters. optorch is the first pip-installable, PyTorch-native open-source framework for optical neural networks. GitHub: optorch on GitHub

Authors

Publication Details

Journal
Zenodo (CERN European Organization for Nuclear Research)
Published
2026-05-22
DOI
https://doi.org/10.5281/zenodo.20344997
Primary Topic
Neural Networks and Reservoir Computing
Type
preprint
Controls
|||
ALL TIME
JAN
FEB
MAR
APR
MAY
JUN
JUL
AUG
SEP
OCT
preprint

optorch: An Open-Source PyTorch Framework for Diffractive Deep Neural Networks

Hrishikesh Rajulu
Zenodo (CERN European Organization for Nuclear Research)
Neural Networks and Reservoir Computing
preprint

optorch: An Open-Source PyTorch Framework for Diffractive Deep Neural Networks

Hrishikesh Rajulu
preprint en

Abstract

optorch is an open-source Python framework for simulating, training, and deploying Diffractive Deep Neural Networks (D2NNs). Unlike conventional neural networks that rely on electronic matrix multiplication, optical neural networks compute through the physical diffraction of light, enabling ultra-low-latency and energy-efficient AI inference. Built on the Angular Spectrum Method, optorch provides fully differentiable light propagation simulation in a PyTorch-native workflow. A 3-layer D2NN trained with optorch achieves 89.79% MNIST test accuracy using only 2,352 learnable parameters, training in approximately 2 minutes on a standard CPU — within 2% of the original 2018 MIT Science paper while using 340× fewer parameters. optorch is the first pip-installable, PyTorch-native open-source framework for optical neural networks. GitHub: optorch on GitHub

Zenodo (CERN European Organization for Nuclear Research)
Affordable and clean energy
Neural Networks and Reservoir Computing
AI Navigator

Ask Laika to Summarize, Analyze, and Connect papers live on the map.

Summarize Papers & Methodologies

Extract key findings, datasets, and comparative methods across publications.

Benchmark Rankings & Visual Analytics

Rank top research institutions, authors, funders, topics, and journals by Field-Weighted Citation Impact (FWCI) and paper volume with instant charts.

Connect Distant Disciplines

Bridge topological clusters on the map to find hidden collaborative intersections.