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

Add WCS to schemas #351

Merged
merged 11 commits into from
Jan 22, 2024
Merged
Show file tree
Hide file tree
Changes from 10 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions CHANGES.rst
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@

- Remove the unused ``variance-1.0.0`` schema. [#344]

- Add wcs tag to wfi_image and wfi_mosaic schemas. [#351]

0.18.0 (2023-11-06)
-------------------

Expand Down
5 changes: 5 additions & 0 deletions src/rad/resources/schemas/wfi_image-1.0.0.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,11 @@ properties:
- $ref: common-1.0.0
- type: object
properties:
wcs:
title: WCS object
anyOf:
- tag: tag:stsci.edu:gwcs/wcs-*
- type: "null"
Comment on lines +21 to +23
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why is this null? It is not a required field by the object.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for pointing this out. It needs to be a required field.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should it still be null, or do we always expect a gwcs object in the end?

photometry:
tag: asdf://stsci.edu/datamodels/roman/tags/photometry-1.0.0
source_detection:
Expand Down
5 changes: 5 additions & 0 deletions src/rad/resources/schemas/wfi_mosaic-1.0.0.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,11 @@ properties:
tag: asdf://stsci.edu/datamodels/roman/tags/photometry-1.0.0
resample:
tag: asdf://stsci.edu/datamodels/roman/tags/resample-1.0.0
wcs:
title: WCS object
anyOf:
- tag: tag:stsci.edu:gwcs/wcs-*
- type: "null"
required: [photometry]
data:
title: Science data, excluding border reference pixels.
Expand Down
4 changes: 4 additions & 0 deletions tests/test_schemas.py
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,10 @@ def valid_tag_uris(manifest):
"tag:stsci.edu:asdf/unit/quantity-1.1.0",
"tag:stsci.edu:asdf/unit/unit-1.0.0",
"tag:astropy.org:astropy/units/unit-1.0.0",
"tag:stsci.edu:gwcs/wcs-1.0.0",
"tag:stsci.edu:gwcs/wcs-1.1.0",
"tag:stsci.edu:gwcs/wcs-1.2.0",
"tag:stsci.edu:gwcs/wcs-*",
]
)
return uris
Expand Down