Deep learning in quantum optics and spectroscopy