FermiSummerSchool/fermi-summer-school

Importing pyfits

Closed this issue · 1 comments

When you run the import pyfits line, you get the following error:

/home/astrosoft/sciencetools/x86_64-unknown-linux-gnu-libc2.12/lib/python2.7/site-packages/pyfits/init.py:22: PyFITSDeprecationWarning: PyFITS is deprecated, please use astropy.io.fits
PyFITSDeprecationWarning) # noqa

It's non-fatal, everything still works, but we should warn the users so that they know that. I encountered this in the Data_Exploration_P8 notebook, but I assume this will apply in lots of places.

Or you change the line to import astropy.io.fits as pyfits to avoid it all together. This at least worked for this notebook.

Since we haven't replaced pyfits with astropy in the science tools yet (but are planning to), I'd rather leave it as import pyfits for the school. This way the students know what to expect.