Changed pyfits module to astropy.io.fits