Active learning for photonics
Authors
Ryan Lopez, Charlotte Loh, Rumen Dangovski, Marin Soljačić
Abstract
Active learning for photonic crystals explores the integration of analytic approximate Bayesian last layer neural networks (LL-BNNs) with uncertainty-driven sample selection to accelerate photonic band gap prediction. We employ an analytic LL-BNN formulation, corresponding to the infinite Monte Carlo sample limit, to obtain uncertainty estimates that are strongly correlated with the true predictive error on unlabeled candidate structures. These uncertainty scores drive an active learning strategy that prioritizes the most informative simulations during training. Applied to the task of predicting band gap sizes in two-dimensional, two-tone photonic crystals, our approach achieves up to a 2.6x reduction in required training data compared to a random sampling baseline while maintaining predictive accuracy. The efficiency gains arise from concentrating computational resources on high uncertainty regions of the design space rather than sampling uniformly. Given the substantial cost of full band structure simulations, especially in three dimensions, this data efficiency enables rapid and scalable surrogate modeling. Our results suggest that analytic LL-BNN based active learning can substantially accelerate topological optimization and inverse design workflows for photonic crystals, and more broadly, offers a general framework for data efficient regression across scientific machine learning domains.
Concepts
The Big Picture
Imagine finding the best recipe in a cookbook with 11,000 entries, but each one takes eight hours to test. You could sample at random, or you could start with a small batch, figure out which flavors are hardest to predict, and test only those next. That’s essentially what a team of MIT physicists and engineers did for photonic crystals, cutting the number of expensive simulations needed to train an accurate predictive model by a factor of 2.6.
Photonic crystals are engineered materials with precisely repeating microscopic structures that control how light moves through them. They block certain colors of light while allowing others to pass. That forbidden zone for specific wavelengths is called a band gap, and its size determines what a photonic crystal can do. Computing the band gap for any given design requires a rigorous simulation, slow and expensive, especially in three dimensions. Testing thousands of candidates this way just isn’t feasible.
Ryan Lopez, Charlotte Loh, Rumen Dangovski, and Marin Soljačić at MIT went after this bottleneck directly. They built a machine-learning framework that learns which simulations to run rather than running them all.
Key Insight: By adding a layer that measures prediction confidence to a neural network, this approach matches the prediction accuracy of a fully trained model using 2.6 times less simulation data than random sampling, shrinking the computational cost of photonic crystal design.
How It Works
The core idea is active learning: a model iteratively decides what data it needs next rather than passively consuming a fixed dataset. Standard machine learning is like studying with a randomly shuffled deck of flashcards. Active learning is the student who sets aside everything they already know and drills on what stumps them.
The team’s implementation works in cycles. They start with a small set of labeled photonic crystal structures where the full simulation has been run and the band gap is known. A neural network trains on those examples, then predicts band gaps for thousands of unlabeled candidates it hasn’t seen. The question at each step: which candidates should be simulated next?
That’s where the approximate Bayesian last layer (LL-BNN) comes in. In a standard neural network, the final layer produces a single number. One prediction, no caveats. The LL-BNN makes that final layer probabilistic: instead of fixed connection strengths, each weight is described by a range of plausible values with a learned center and spread. The network goes from outputting a number to outputting a probability distribution, a prediction with an associated confidence.
What makes this practical is that the Bayesian uncertainty computation has a closed-form solution. Standard Bayesian neural networks need dozens or hundreds of random samples to estimate uncertainty, which is expensive and noisy. The team sidesteps this by taking the mathematical limit as the number of Monte Carlo samples goes to infinity, arriving at a closed-form expression for the predictive variance. Uncertainty scores then come from a single forward pass and a few matrix multiplications. No sampling required.
The workflow proceeds as follows:
- Initialize with a small set of randomly labeled photonic crystal structures
- Train the neural network (backbone + Bayesian last layer) jointly on the current labeled set
- Evaluate all unlabeled candidates using the analytic variance formula, one pass per candidate
- Select the highest-uncertainty structures for new band-gap simulations
- Add those newly labeled points to the training set and repeat
The network takes 2D dielectric-constant maps of photonic crystal unit cells as input and passes them through a deep neural network backbone. Symmetry operations (reflections and rotations) augment the training data so the model can generalize from limited examples. The Bayesian last layer then converts the backbone’s learned features into a predictive distribution over band gap size.

Why It Matters
The immediate payoff is computational. Full band structure simulations for 2D photonic crystals are already non-trivial; in 3D, they get much worse. A 2.6x reduction in required training data isn’t a minor tweak. It could mean the difference between a surrogate model that’s practical to build and one that isn’t. That kind of efficiency opens up much larger design spaces, including 3D geometries that would otherwise be out of reach.
The analytic LL-BNN framework also has legs beyond photonics. Scientific machine learning hits the same bottleneck constantly: simulations are costly, experiments take time, and labels are scarce. The same approach could apply to materials discovery, molecular property prediction, or potential-energy surface sampling. Anywhere that generating a training label costs real compute or lab time, uncertainty-guided sampling can help.
Open questions remain. The current work focuses on 2D photonic crystals with two material components; scaling to 3D structures and multi-material designs would test whether the framework holds up under added complexity. The interaction between batch size and efficiency also deserves attention, since optimal batch sizing likely depends on problem geometry.
Bottom Line: Active learning with analytic Bayesian uncertainty cuts the simulation burden for photonic crystal design by more than half. The framework is general: any scientific modeling problem where simulations are expensive and labels are scarce could benefit from the same approach.
IAIFI Research Highlights
This work combines Bayesian machine learning with photonic crystal physics, using neural uncertainty estimates to guide expensive electromagnetic simulations and connecting AI methodology directly to a fundamental problem in light-matter interaction.
The analytic last-layer Bayesian formulation achieves closed-form uncertainty quantification at a fraction of the cost of Monte Carlo-based methods, making principled Bayesian deep learning more practical for regression tasks in science and engineering.
By enabling data-efficient surrogate models for photonic band gap prediction, this approach speeds up inverse design workflows for engineered optical materials that manipulate the interaction between light and structured matter.
Future work targeting 3D photonic crystals and multi-component material systems could expand the framework's reach; the full paper ([arXiv:2601.16287](https://arxiv.org/abs/2601.16287)) is available from the MIT Physics and EECS departments.
Original Paper Details
Active learning for photonics
2601.16287
Ryan Lopez, Charlotte Loh, Rumen Dangovski, Marin Soljačić
Active learning for photonic crystals explores the integration of analytic approximate Bayesian last layer neural networks (LL-BNNs) with uncertainty-driven sample selection to accelerate photonic band gap prediction. We employ an analytic LL-BNN formulation, corresponding to the infinite Monte Carlo sample limit, to obtain uncertainty estimates that are strongly correlated with the true predictive error on unlabeled candidate structures. These uncertainty scores drive an active learning strategy that prioritizes the most informative simulations during training. Applied to the task of predicting band gap sizes in two-dimensional, two-tone photonic crystals, our approach achieves up to a 2.6x reduction in required training data compared to a random sampling baseline while maintaining predictive accuracy. The efficiency gains arise from concentrating computational resources on high uncertainty regions of the design space rather than sampling uniformly. Given the substantial cost of full band structure simulations, especially in three dimensions, this data efficiency enables rapid and scalable surrogate modeling. Our results suggest that analytic LL-BNN based active learning can substantially accelerate topological optimization and inverse design workflows for photonic crystals, and more broadly, offers a general framework for data efficient regression across scientific machine learning domains.