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

Verify need for v3yangle, vparity in L3 pipeline #1167

Closed
schlafly opened this issue Mar 28, 2024 · 6 comments
Closed

Verify need for v3yangle, vparity in L3 pipeline #1167

schlafly opened this issue Mar 28, 2024 · 6 comments

Comments

@schlafly
Copy link
Collaborator

The exposure level pipeline doesn't presently use the v3yangle or vparity keywords, though it may need to in the future when setting the telescope pointing. The mosaicing pipeline does use these keywords, however, and it's not obvious to me that it needs to; the WCS object contains all the information that should be needed. We should investigate whether these keywords are actually required.

@stscijgbot-rstdms
Copy link
Collaborator

This issue is tracked on JIRA as RCAL-834.

@stscijgbot-rstdms
Copy link
Collaborator

Comment by Jonathan Eisenhamer on JIRA:

The sole place where the wcsinfo is used is in stcal.alignment.util._generate_tranform

This routine creates an astropy.Model of scale/rotation for the output wcs.

A couple of approaches can be taken:

Modification of stcal: _generate_tranform could be modified to calculate such values from the existing refmodel wcs. This could cause issues with jwst compatibility.

romancal-specific: The transform can be pre-calculated in romancal's make_output_wcs. Passing the transform in through the wcs_from_footprints call, would avoid the need for _generate_tranform to use the wcsinfo block. The advantage here is that this is a romancal-specific change only, making use of existing api.

Unless otherwise dictate, Jonathan Eisenhamer will take the romancal-specific path.

@schlafly
Copy link
Collaborator Author

Could you check whether JWST actually uses this? I think our goal is for eventually Webb++ to start using stcal.alignment, but currently I think Roman is the only user. i.e., I think that if we think the _generate_transform API isn't right, we have flexibility to change it.

@nden
Copy link
Collaborator

nden commented May 16, 2024

These are used to determine the roll angle roll_ref , computed in set_telescope_pointing.

@schlafly
Copy link
Collaborator Author

Sorry, I haven't tracked the full path, but looking at this briefly, _generate_transform is ~recomputing the WCS object we already have, and accepts a transform argument that we could imagine supplying it to avoid that path?

@stscijgbot-rstdms
Copy link
Collaborator

Comment by Jonathan Eisenhamer on JIRA:

After discussions with Eddie Schlafly , this issue is being closed without further work modulo the following:

  • The default output WCS uses the roll, parity, and v3yangle from the first input WCS. This isn't great but absent direction (which will provided for the skycells) isn't horrible.
  • To make this insensitive to the wcsinfo, the WCS can be used directly to compute the angles, scales, and parities. But since this is only computing the choice of WCS there is no real bug here.
  • A better job computing the output shape can be implemented in the future if needed.

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

No branches or pull requests

3 participants