Closed mb010 closed 1 year ago
SpectralCube
s can be read from a variety of different file types, some of which do not support memory-mapped operations (CASA image, CLASS).
It would technically be possible to do as you ask for FITS files specifically, but I don't think it's advisable - most users don't need that feature and might be surprised by it.
I would recommend just using hdu = fits.open('file.fits', mode='update')
and writing the output of SpectralCube
operations into that. If there are use cases that aren't well-supported by this approach, let us know.
I'm trying to write statistical properties on a pixelwise level on a large stokes spectral cube. I would like to do this by simplying writting over the data in a write mode opened file. However, I cannot seem to find any option for this in the
StokesSpectralCube
class even though there is one in theSpectralCube
class. A simplemode
option would be ideal, or is there a reason this was not implemented that I am ignorant to?