Photonic Generation of Sub-Terahertz Noises and Its Application to Spectroscopy Measurement