[AstroPy] Saving Cutout2D image to FITS

Thomas Boch thomas.boch at astro.unistra.fr
Tue Mar 13 17:37:09 EDT 2018

Hi Ivan,

the Cutout2D object has attributes /data/ and /wcs/ which can be used to 
create an astropy.io.fits.PrimaryHDU instance that can then be written 
to a file.



Le 13/03/2018 à 22:27, Ivan Valtchanov a écrit :
> Hi all,
> I've been trying to useastropy.nddata Cutout2D to crop a large image. 
> I don't see how to save the cutout result to a FITS file. 
> cutout.writeto('image.fits') does not work and in the API I cannot 
> find a method in the Cutout2D class that saves the result to a FITS file.
> is there a way to do it?
> Thanks,
> Ivan Valtchanov
> _______________________________________________
> AstroPy mailing list
> AstroPy at python.org
> https://mail.python.org/mailman/listinfo/astropy

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/astropy/attachments/20180313/62f4d865/attachment.html>

More information about the AstroPy mailing list