Double beam near-infrared spectrometer for compensation of background water absorption and instrumental drift in intensity