Closed kadrlica closed 3 years ago
I did some timing for an issue on healpy
and found that fitsio is significantly faster (~4x) for loadinghealpy
formatted, gzipped files:
>>> %timeit hp.read_map('tmp.fits.gz',dtype=int,verbose=False)
1 loops, best of 3: 32.7 s per loop
>>> %timeit pyfits.open('tmp.fits.gz')[1].data['I'].ravel()
1 loops, best of 3: 20.6 s per loop
>>> %timeit fitsio.read('tmp.fits.gz',ext=1)['I'].ravel()
1 loops, best of 3: 7.98 s per loop
I've implemented a fitsio
version of read_map
in 353581abb62c3c8fc056750f2562a774a8d99fbf.
With the exception of the scratch
directory, I think this migration is complete. I'll double check and get this into v1.8.0
.
Closed by #94
I've found
fitsio
to be superior topyfits
. In addition, astropy has taken over pyfits, which is now accessed asastropy.io.fits
. I'd like to switch tofitsio
, or abstract the interface to the fits reader so the user can use whatever is available on their system (fitsio
>astropy.io.fits
>pyfits
).