Analyzing Thermal Spectra with Machine Learning