  We propose a new cellular automaton (CA), the Sweep Rule, which generalizes
Toom's rule to any locally Euclidean lattice. We use the Sweep Rule to design a
local decoder for the toric code in $d\geq 3$ dimensions, the Sweep Decoder,
and rigorously establish a lower bound on its performance. We also numerically
estimate the Sweep Decoder threshold for the three-dimensional toric code on
the cubic and body-centered cubic lattices for phenomenological phase-flip
noise. Our results lead to new CA decoders with provable error-correction
thresholds for other topological quantum codes including the color code.
