A new method uses optics to accelerate machine-learning computations on smart speakers and other low-power connected devices