Gracedb should parse FITS files
Description of feature request
Add some parsing of FITS files included in VOEvents into gracedb. This could be done at the time a voevent is created, or later by a cronjob. There are several outcomes that people have suggested for this:
- Create PNG of 2-D skymaps
- Create PNG of 3-D skymaps
- Create PNG of p-astro info
- Ingest distance info into schema of each voevent
- Could display PNG of skymaps with predictable and reliable filename
- Could enhance views of gracedb events to show these PNGs in a structured way
- Could include distance info in tables listing sets of events, so that people could sort or filter based on this property
Currently, the PNG files are not uploaded with predictable names, and so are not useful. This would allow PNG files to be more reliable and useful in views. Adding distance info to schema would allow people to search and sort by distance.
- Distance information includes 2 numbers, so represents a significant change to the schema for VOEvents
- If this ingestion is done at the time a new VOEvent is created, could slow down the process of sending out GCNs, which is a serious drawback. For this reason, may be better to create the VOEvent in the database without this, and then 'back-fill' with a cronjob or similar.
If it were me, I would:
- Add a distance and distance error field to the VOEvent schema. These fields would be 'null' at the time of VoEvent creation, and would not appear in the VoEvent XML files (as now).
- Set up a cronjob that runs every 10 minutes or so, and does the following:
- Gets a list of all VOEvents where the distance column is 'null'
- For each of these, generate PNG images of skymaps, and save to disk in a predictable location
- Read out distance information from FITS header, and ingest into database.