Any suggestions on how to convert a .fits file (or table) to a csv? I tried to and the code was running for over 12 hours. I currently used pandas and read the table and tried to save as csv:
dr_file = get_pkg_data_filename('/users/...data.fits')
events = Table.read(dr_file, hdu=1)
df = pd.DataFrame(events)
df.to_csv('data.csv')