Spectroscopy learning: A machine learning method for study diatomic vibrational spectra including dissociation behavior