Control, Calibration and Drift
A digital chip, once fabricated, simply works: a transistor that was a switch on Monday is a
switch on Friday. A photonic processor enjoys no such peace. Its computational state lives in
thousands of analog phases, and everything moves them. Silicon's refractive
index shifts with temperature at dn/dT \approx 1.86 \times 10^{-4}\,\mathrm{K}^{-1}
— a blessing when you want a
thermo-optic
phase shifter, a curse the rest of the time, because a phase shifter is also an
exquisitely sensitive thermometer. The air conditioning cycles, a neighbouring core wakes up, a
heater two rows over changes duty cycle — and your carefully programmed unitary wanders off.
This lesson is about the unglamorous machinery that keeps an analog computer being the
computer you programmed: monitors, dithers, lock-in detection, feedback loops, and a calibration
problem that turns out to be a textbook
ill-posed
inverse problem. It ends with an awkward bill: the electrical power spent
holding still can exceed the power spent computing.
How fast things fall apart
Work the number once and you will never trust a bare mesh again. A waveguide section of length
L drifting by \Delta T picks up a phase
error
\Delta\varphi \;=\; \frac{2\pi}{\lambda}\,\frac{dn}{dT}\,L\,\Delta T
\;\approx\; 75 \ \mathrm{mrad\ per\ kelvin}
for L = 100\ \mu\mathrm{m} at
\lambda = 1550 nm. Now recall what precision demands. Programming a
weight to B bits means holding its phase to roughly
\pi/2^{B}: about 49 mrad for 6 bits, 12 mrad for 8 bits. Twelve
milliradians is 0.16 kelvin — on a die dissipating watts, next to lasers and
drivers, inside a rack whose inlet air swings by degrees. Passive stability is hopeless; every
phase must be actively supervised. And the enemy is not only the environment:
thermal crosstalk means each heater warms its neighbours, so commanding one
phase perturbs a whole neighbourhood — the mesh's control knobs are not independent, they are
coupled through the silicon itself. (Slower villains lurk behind temperature: mechanical stress
relaxation, humidity, and charge trapping that makes some phase shifters wander over days.)
Dither and lock-in: how to see a phase
You cannot correct what you cannot measure, and no detector reads phase directly. The standard
trick has three parts. First, monitor photodiodes: tiny tap couplers bleed off
~1% of the light at chosen points so the controller can watch powers without disturbing the
signal path. Second, a dither: wiggle the phase under control by a small
\delta\sin\omega t (a few millirad, at some kilohertz). The monitored
power responds as
P(\varphi_0 + \delta\sin\omega t) \;\approx\; P(\varphi_0)
\;+\; P'(\varphi_0)\,\delta\sin\omega t \;+\; \tfrac{1}{4}P''(\varphi_0)\,\delta^2(1-\cos 2\omega t),
so the component at the dither frequency has amplitude proportional to the slope
P'(\varphi_0) — a signed error signal that says not just "you're
off" but which way. Third, lock-in detection: multiply the detector
output by \sin\omega t and low-pass filter, which surgically
extracts that one component while rejecting the DC drift and 1/f
noise that swamp any naive measurement. Feed the recovered slope into an integrator driving the
heater and the loop parks itself where the error vanishes — at a fringe extremum, where
P' = 0 and only the 2\omega harmonic
remains. Give each of the mesh's phases its own dither frequency and one shared photodiode can
supervise dozens of them simultaneously, each loop deaf to the others' tones.
Note the trade baked into the slider: a bigger dither gives a stronger, cleaner error signal —
and a bigger deliberate wobble on your computation. Production systems run the dither just above
the noise floor and average longer instead.
Calibration is an inverse problem
Feedback holds a phase where you told it to go; calibration is the harder art of
learning what "where" means. The chip you receive from the fab is not the chip you designed:
every phase shifter has a fabrication offset, every heater its own efficiency, and the crosstalk
matrix couples them all. Formally, you observe output powers
P = f(\theta_{\text{cmd}};\, \theta_{\text{offset}}, C) for probe
inputs and command vectors \theta_{\text{cmd}}, and must infer the
offsets and the crosstalk matrix C. This is an inverse problem with
all the pathologies the
ill-posedness
lesson warned about: the map from parameters to observations is many-to-one
(interferometric powers are blind to global phases; distinct offset patterns produce nearly
identical outputs), and measurement noise gets amplified wherever sensitivity is low — precisely
at the fringe extrema where the loops like to sit. The practical playbook is regularisation by
structure: calibrate element by element (routing light through one MZI at a time, sweeping its
phase, fitting its fringe), then correct pairwise crosstalk, then close global feedback to mop
up the residual — rather than inverting one heroic, ill-conditioned model of the whole chip.
Self-configuring meshes push further still, arranging the mesh to calibrate itself layer by
layer from its own monitor readings, an idea developed in the
mesh-programming
lesson.
The bill for holding still
Now the systems punchline. A thermo-optic phase shifter needs
P_\pi \approx 10\text{–}20 mW to hold a π shift, and holding is
continuous — this is not switching energy, it is standing power. A Clements mesh for
N = 64 has N(N-1)/2 = 2016 MZIs and
N(N-1) = 4032 phase shifters. At an average of even 5 mW each, the
mesh burns 20 watts doing nothing — before a single MAC, before the laser,
before any converter. Against the mesh's
2N^2 f \approx 41 TOPS at 5 GHz, tuning alone caps the system at
about 2 TOPS/W: a respectable digital accelerator's figure, spent entirely on keeping the
analog computer honest. This single line item motivates a small industry of alternatives —
undercut and suspended heaters (milliwatts, but slower), MEMS and NOEMS actuators (nanowatts of
hold power), and non-volatile
phase-change
weights that hold their state with the power off. Whenever you evaluate a photonic
accelerator claim, ask for the tuning power first: it is the least advertised number and,
remarkably often, the largest.
The dither-and-demodulate trick is far older than photonics. Robert Dicke formalised the lock-in
amplifier in the 1940s (characteristically, he claimed the idea was already folklore), and it
has been the instrument behind half of experimental physics ever since: it is how you hear a
nanovolt whisper under a volt of hum, provided the whisper agrees to sing at a frequency of
your choosing. Gravitational-wave interferometers hold kilometre-scale Michelsons on a dark
fringe with exactly the machinery of this lesson — modulation sidebands, demodulated error
signals, feedback to actuators — just with quieter electronics and much more expensive mirrors.
A photonic mesh supervising 4 000 phases with frequency-multiplexed dithers is running 4 000
tiny lock-in amplifiers at once; the technique scales because multiplication and low-pass
filtering are cheap in the digital controller. The analog computer, it turns out, is chaperoned
everywhere by a digital one — a theme the
next
lesson elevates into a design principle.
A tempting mental model: calibration is a factory step, like trimming a quartz watch — do it
once, burn the table to flash, done. For a photonic mesh this is false on three timescales.
Seconds to minutes: thermal transients from the workload itself (yesterday's matrix warmed the
left half of the mesh; today's doesn't). Hours to days: ambient drift, laser wavelength drift
and stress relaxation. Weeks to months: aging, charge trapping, and slow damage around active
regions. A lookup table is a snapshot of a moving target; production systems therefore layer
defences — factory characterisation for the offsets, continuous low-bandwidth feedback for the
drift, and periodic recalibration for the slow decay — and budget engineering effort
accordingly. The rule of thumb from people who have shipped analog silicon: you do not ship the
device, you ship the control loop. When a startup's demo works beautifully on the
bench in January and the product slips to December, drift is very often the untold story.