MG-GPO & RCDS-S

GP-guided and safety-constrained online optimization on the live SPEAR3 ring.

Two online optimizers for SLAC's SPEAR3 storage ring, where measurements are slow and noisy and the machine drifts while you tune it. MG-GPO screens evolutionary candidates with a Gaussian-process surrogate so only promising settings reach the machine; RCDS-S adds a probabilistic safety model so tuning can follow a drifting optimum without crossing an operator-set threshold. Both ran on the live ring: MLST 2020 (co-first author) and PRAB 2022 (first author).

Why

Online tuning is sequential decision-making against an expensive, noisy black box: an injection-efficiency point takes about 17 seconds, a generation of thirty about 8.5 minutes, and swarm or genetic optimizers waste many of those. Drift is the second problem: performance decays over a long user run, and conventional optimizers propose settings too poor to run outside machine-study shifts.

MG-GPO: a GP filter on an evolutionary search

Each generation amplifies the current non-dominated set with PSO-style flocking, polynomial mutation and SBX crossover into 300–1,200 candidates per thirty-point generation on the machine. One Gaussian process per objective scores each candidate by the lower confidence bound μ − κσ, and non-dominated sorting with crowding distance picks the thirty to measure; κ shrinks by a fixed ratio per generation (κ₀ = 2, ρ = 0.9). The GP only ranks what the operators propose, so the overhead stays under 8 seconds per generation against 8.5 minutes of measurement.

MG-GPO flow: the previous generation is amplified by flocking, mutation and crossover into candidates, a GP model built from the archive scores them, and the selected set becomes the next generation
Figure 1. One MG-GPO generation. Figure adapted from Zhang, Song & Huang, MLST, 2020.

RCDS-S: safe tuning under drift

RCDS-S keeps the conjugate-direction outer loop of RCDS and makes the line search safety-aware. The objective is assumed Lipschitz, so each observation bounds the expected value nearby; noise and drift, modelled as a Gaussian random walk whose variance grows with time, turn that bound into the probability that a point is still below the threshold. Along each direction it samples only where that probability clears a set level, taking the farthest such point; if nothing qualifies it relaxes the level in steps, then abandons the direction. Its Lipschitz constant and drift rate come from prior scans; too small risks violations, too large loses the drifting optimum.

Results

Negated beam loss rate versus evaluation number for MG-GPO and PSO on SPEAR3; the MG-GPO best-so-far line reaches −1.66 while PSO stops at −1.48
Figure 2. Loss-rate tuning with 13 skew quadrupoles at 500 mA, MG-GPO vs PSO. Figure adapted from Zhang, Song & Huang, MLST, 2020.
Negated injection efficiency versus evaluation number for MG-GPO and PSO, both starting from the flat sextupole solution
Figure 3. Injection-efficiency tuning with 8 chromaticity-preserving sextupole knobs. Figure adapted from Zhang, Song & Huang, MLST, 2020.
Top: objective versus evaluation number for RCDS-S, RCDS and the untuned drifting system with a 50 µm safety threshold; RCDS-S stays below the line while RCDS spikes above it. Bottom: the modulated kicker K1 and the tuned kickers K2 and K3 following it
Figure 4. RCDS-S kicker-bump matching on SPEAR3 with a 50 µm threshold. Figure adapted from Zhang, Song & Huang, PRAB, 2022.

What I did. MG-GPO was conceived by Xiaobiao Huang, who wrote the original Matlab code; I co-developed it, led the online experiments on SPEAR3, wrote the ring's Python online-optimization toolkit (spear3-opt-pkg) and maintain the public MG-GPO repository. MLST 2020 is co-first-authored with Minghao Song, equal contribution. RCDS-S I led and first-authored, with Minghao Song and Xiaobiao Huang.

Objectives are as defined in the papers (negated loss rate normalized to 500 mA; negated injection efficiency, arbitrary units). The RCDS-S runs were machine-study tests, not routine operation. MG-GPO's GP step ran in Python's GPy via Teeport.