Skip to content

Commit

Permalink
add PA and CALIB keywords
Browse files Browse the repository at this point in the history
  • Loading branch information
braingram committed Nov 4, 2024
1 parent 68116df commit e37a4ac
Show file tree
Hide file tree
Showing 3 changed files with 28 additions and 0 deletions.
20 changes: 20 additions & 0 deletions src/stdatamodels/jwst/datamodels/schemas/ami.schema.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
%YAML 1.1
---
$schema: "http://stsci.edu/schemas/fits-schema/fits-schema"
id: "http://stsci.edu/schemas/jwst_datamodel/ami.schema"
allOf:
- type: object
properties:
meta:
type: object
properties:
calibrator_object_id:
title: "Calibration object identifier"
type: string
fits_keyword: CALIB
blend_table: True
telescope_roll:
title: "[deg] Observation position angle"
type: number
fits_keyword: PA
blend_table: True
1 change: 1 addition & 0 deletions src/stdatamodels/jwst/datamodels/schemas/amioi.schema.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,3 +5,4 @@ id: "http://stsci.edu/schemas/jwst_datamodel/amioi.schema"
title: AMI OIFITS analysis data model
allOf:
- $ref: oifits.schema
- $ref: ami.schema
7 changes: 7 additions & 0 deletions src/stdatamodels/jwst/datamodels/tests/test_models.py
Original file line number Diff line number Diff line change
Expand Up @@ -573,6 +573,13 @@ def test_amioi_model_oifits_extra_columns(tmp_path, oifits_ami_model, table_name
oifits_ami_model.save(fn)


def test_amioi_model_extra_meta(tmp_path, oifits_ami_model):
oifits_ami_model.meta.calibrator_object_id = "foo"
oifits_ami_model.meta.telescope_roll = 0
fn = tmp_path / "test.fits"
oifits_ami_model.save(fn)


def test_dq_def_roundtrip(tmp_path):
"""
Open a MaskModel with a defined DQ array and dq_def that modifies the
Expand Down

0 comments on commit e37a4ac

Please sign in to comment.