Skip to content
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

Change name of dms_corner() #187

Open
bhilbert4 opened this issue Jul 28, 2021 · 3 comments
Open

Change name of dms_corner() #187

bhilbert4 opened this issue Jul 28, 2021 · 3 comments

Comments

@bhilbert4
Copy link

The name of the dms_corner attribute of a SIAF aperture is misleading. It appears that this function actually returns the OSS corner coordinates for one of the aperture corners. It would be helpful to rename the attribute to oss_corner or something similar.

The Mirage package contains a function (written by Johannes Sahlmann) to return the DMS coordinates of the aperture corners. Feel free to steal it and use it for the dms_corner attribute if that's convenient.

https://github.com/spacetelescope/mirage/blob/master/mirage/utils/siaf_interface.py#L223

@mgennaro
Copy link
Contributor

mgennaro commented Jul 28, 2021

I second this: I wrotedms_corner and I realized later it was a bit of a misnomer. This method of the aperture class does indeed return the value of the OSS "ColCorner, RowCorner" for a given aperture, and these can be directly compared to the corresponding values in the subarray.xml files.

@mgennaro
Copy link
Contributor

The actual DMS corners should already be available in pysiaf under the 'sci' coordinate system, so I don't think we need to add that.

@bhilbert4
Copy link
Author

The sci coordinate system is based on the subarray itself though. e.g. For SUB320, the coordinates go from 0 to 319. What I think of as DMS corners are the coordinates in the full frame coordinate system, with the detector in the DMS orientation. So on the NIRCam A1 detector, the lower left corner of the SUB320 subarray would be (x, y) = (1728, 1728), and the upper right corner is (x, y) = (2048, 2048). I don't see any methods in pysiaf currently to calculate these values. This is what the function in Mirage calculates.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants