-
-
Notifications
You must be signed in to change notification settings - Fork 46
Added proposal to modify ds9 to work with ASDF files. #495
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
perrygreenfield
wants to merge
3
commits into
astropy:main
Choose a base branch
from
perrygreenfield:prop1
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,73 @@ | ||
| ### Title Making DS9 more accessible to ASDF and Python | ||
|
|
||
| ### Project Team | ||
|
|
||
| - Perry Greenfield: Approximately 27 years of scientific python programming | ||
| experience; 50 years of astronomical data reduction experience, 40 years at | ||
| STScI (now retired), former Branch Lead of Science Software Branch; | ||
| involved in all major Python data analysis and calibration projects at | ||
| STScI. Part of the original organizing of astropy. Involved in the creation | ||
| of ASDF (Advanced Scientific Data Format) | ||
|
|
||
| ### Project Description | ||
| The Advanced Scientific Data Format (ASDF) was | ||
| developed to address shortcomings of the FITS format, like serializing | ||
| complex WCS transformations or dealing with newer types of | ||
| instrumentation (IFS, MSA), that FITS is effectively incapable of | ||
| handling (Thomas, B., Jenness. T. et al. (2015)). A Python library was | ||
| developed to implement the standard. | ||
|
|
||
| Currently astropy makes use of ASDF for serialization of a number of objects, | ||
| models, tables and coordinate frames as examples. To help wider adoption of | ||
| ASDF by the community, and thus the serialization of astropy objects, it is | ||
| important that astronomers have a convenient way of displaying images within | ||
| their most used image display tool, namely ds9. Unfortunately STScI is | ||
| unwilling to provide such support. I am proposing to add such support to ds9, | ||
| as well as making integration of general python tools more easily accessible | ||
| from ds9 than they currently are. | ||
|
|
||
| The integration will proceed in steps. | ||
|
|
||
| 1. ds9 provides a means of execution of python code, albeit in a somewhat | ||
| awkward manner. Some years past I have developed such a facility for | ||
| displaying ASDF images in ds9, though it was never carried through to being | ||
| released due to a lack of support from STScI. This first step is to make this | ||
| capability available. | ||
|
|
||
| 2. The second step is to make the instrinsic ds9 GUI | ||
| naturally accept ASDF files as easeily as it uses FITS files. This initially | ||
| does not require changes to the internals of ds9, particularly with regard | ||
| to its user interface. This is because there are mechanisms for ds9 to | ||
| dynamically load new GUI elements from TCL extensions provided by others. | ||
| (See https://ui.adsabs.harvard.edu/abs/2005ASPC..347..114C/abstract for | ||
| an overview; in addition, the following repository contains examples of | ||
| how this is done. The hope is that with the successful addition of the | ||
| enhancements, the ds9 development team will find it easy to fold these | ||
| into the ds9 codebase. | ||
|
|
||
| 3. Expand the ds9 interface to allow introspection | ||
| within an ASDF file showing where images are located so they can be selected | ||
| with the cursor. Initially does not need internal changes to ds9. | ||
|
|
||
| 4. The previous steps can be generalized to allow a | ||
| mechanism to extend the ds9 interface to handle access to other python | ||
| tools. Likewise probably does not require internal changes to ds9 | ||
|
|
||
| 5. ds9 currently only understands FITS WCS information. I plan to | ||
| modify it to also work with the python GWCS library. Note the previous steps | ||
| bypass this by approximating the GWCS with a SIP fit to the GWCS model). | ||
| There is a subtlety that must be dealt with that affects performance since it | ||
| will likely be necessary to change the event handling when using GWCS to make | ||
| it perform acceptably. | ||
|
|
||
| This proposal intends | ||
| to limit the work to the funds requested. I expect that the first 3 steps | ||
| should be achieved; those beyond depend on the difficutly of 2 and 3. | ||
| Item 5 is considered a stretch goal and requires integration into ds9. | ||
|
|
||
| ### Approximate Budget I am requesting budget in the range of $18,000 to $22,000 to perform this work | ||
| (approximately 133 hours at $150/hr) | ||
|
|
||
| ### Period of Performance The work will be completed within a year | ||
| (2026-01-01 to 2026-12-31) | ||
|
|
||
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Does this make use of pyds9? Or is it different?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@hamogu I have not reached out to the development team (I recall a little ways back that there questions about support, so it is good to hear that is not a problem). It was suggested basically the day before the proposal deadline so I did not have time to do that. I must have been under the mistaken impression Bill Joye had retired (or did and then was roped back in?). I will contact him about this proposal. As mentioned the first task is independent of any needed changes to ds9, but the subsequent ones do require changes.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@astrofrog the original implementation of the first step did not use pyds9, but that was long enough ago that I don't recall the reasons. It may be usable now. I have to check into that.