[AstroPy] FITS files and column descriptions

Aldcroft, Thomas aldcroft at head.cfa.harvard.edu
Mon Nov 11 12:31:21 EST 2013


On Thu, Nov 7, 2013 at 4:20 PM, Yannick Roehlly <yannick.roehlly at lam.fr>wrote:

> Hi all,
>
> I have some remarks / questions concerning the column descriptions in
> FITS table files (and VO).
>
> 1. Long column description
>
> The FITS format requires that a column description must be 68
> characters or less. Some tools like topcat / stills allows longer
> descriptions because they use a kind of VO-table metada section in the
> FITS header. If you open such file with astropy.io.fits and save it
> again, you loose the long description. In fact, it's not an astropy
> problem as these description as not in the "real FITS" column
> descriptions in the header (TCOMxx), it is just because astropy does
> not save the "VO-table" part of the topcat file.
> Maybe it's worth raising a warning when opening such files, like "Hey,
> you may loose metadata!" because one may be surprise not to have all
> its column description.
>
> 2. astropy.table and column descriptions in FITS files
>
> When opening a FITS file with astropy.tables(with last git checkout)
> one does not have access to column descriptions. When saving an
> astropy.io.table to FITS, the column description are lost. But when
> opening a FITS file with description and saving it again to FITS, the
> column descriptions are still here. I suppose that it's because
> astropy.io.fits is under the hood.
>
> Is this because column description handling is not implemented or do I
> miss something?
>

I believe this is not implemented but should be.  I opened an issue
https://github.com/astropy/astropy/issues/1768.


>
> 3. Column descriptions in VO-Table
>
> When saving a table to VO-Table, astropy prettily indent the xml, e.g.
>
>     <DESCRIPTION>
>      IAU Name
>     </DESCRIPTION>
>
> But when reading these tables with topcat, this one add the spaces to
> the description ("     IAU Name"). Maybe astropy should write the
> description on one line.
>
> Regards,
>
> Yannick
>
> --
> Mystics always hope that science will some day overtake them.
>                 -- Booth Tarkington
> _______________________________________________
> AstroPy mailing list
> AstroPy at scipy.org
> http://mail.scipy.org/mailman/listinfo/astropy
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/astropy/attachments/20131111/baf2b49d/attachment.html>


More information about the AstroPy mailing list