In [1]:
%matplotlib inline
In [2]:
import csv
import astropy.io.fits as fits
import spectraldl.lamost as lamost
import spectraldl.ondrejov as ondrejov
import matplotlib.pyplot as plt
In [3]:
with open('data/cross-matched.csv', newline='') as f:
reader = csv.reader(f)
for ond_path, lam_path in reader:
fig, ax = plt.subplots()
with fits.open(ond_path) as ond_hdulist:
ondrejov.plot_spectrum(ond_hdulist, ax)
ax.set_title(ondrejov.get_object_name(ond_hdulist))
with fits.open(lam_path) as lam_hdulist:
lamost.plot_spectrum(lam_hdulist, ax)