I am currently attempting to read data from a large data FITS format data file using astropy.io.fits for Python 3.4. While I can successfully open the file using the memmapper mode, I cannot access the data within the file. Here is my code
from astropy.io import fits
hdu_list = fits.open('large_file.fit', memmapper=True)
table = hdu_list[1].data
On the second line table = hdu_list[1].data
I then get OSError: [WinError 8] Not enough storage is available to process this command
My thinking is that when assigning the data to the variable table
, the attempt is made to read the entire file, causing the storage error. Is there any work around, or a method to simply read in each line of the table data at a time?