Skip to content

Commit

Permalink
JP-2106: Update keyword schema enum lists (#6081)
Browse files Browse the repository at this point in the history
* JP-2106: Update keyword schema enum lists

* Add change log entry and remove errant quote marks

* Update set_telescope_pointing for new attribute name
  • Loading branch information
hbushouse authored May 27, 2021
1 parent b77df8a commit f934522
Show file tree
Hide file tree
Showing 3 changed files with 29 additions and 8 deletions.
5 changes: 5 additions & 0 deletions CHANGES.rst
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,11 @@ combine_1d

- Added SRCTYPE to COMBINE1D output extension headers, propagated from
EXTRACT1D inputs [#6079]

datamodels
----------

- Updated enum lists for ENGQLPTG and PATTTYPE keywords [#6081]

general
-------
Expand Down
26 changes: 21 additions & 5 deletions jwst/datamodels/schemas/core.schema.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -246,10 +246,12 @@ properties:
enum: [OK, SUSPECT]
fits_keyword: ENG_QUAL
blend_table: True
pointing_engdb_quality:
engdb_pointing_quality:
title: Quality of pointing information from EngDB
type: string
enum: [CALCULATED, PLANNED]
enum: [CALCULATED_FULLVA, CALCULATED_FULL,
CALCULATED_GSCMD, CALCULATED_GSCMD_V3PAGS,
CALCULATED_ORIGINAL, PLANNED]
fits_keyword: ENGQLPTG
blend_table: True
type:
Expand Down Expand Up @@ -1014,8 +1016,12 @@ properties:
title: Primary dither pattern type
type: string
enum:
# FGS in parallel with NIRCam and NIRISS
[FULL, FULLBOX, INTRAMODULE, INTRAMODULEBOX, INTRAMODULEX,
INTRASCA, SUBARRAY_DITHER, WFSC, AMI, IMAGING, MIMF, WFSS,

# MIRI coron
[5-POINT-SMALL-GRID, 9-POINT-SMALL-GRID,
5-POINT-SMALL-GRID, 9-POINT-SMALL-GRID,

# MIRI imaging
CYCLING, REULEAUX, SPARSE-CYCLING,
Expand Down Expand Up @@ -1077,13 +1083,23 @@ properties:
NIS_NRC_4L, NIS_NRC_4M, NIS_NRC_4S,
NIS_NRC_9L, NIS_NRC_9M, NIS_NRC_9S,

# NIRSpec FS, IFU, and MOS
# NIRISS with MIRI in parallel
NIS-MIR056-2, NIS-MIR056-3,
NIS-MIR077-3, NIS-MIR077-9,
NIS-MIR100-2, NIS-MIR100-3, NIS-MIR100-4,
NIS-MIR128-2, NIS-MIR128-3, NIS-MIR128-4, NIS-MIR128-9,
NIS-MIR150-2, NIS-MIR150-3, NIS-MIR150-4, NIS-MIR150-9,
NIS-MIR180-2, NIS-MIR180-3, NIS-MIR180-4, NIS-MIR180-9,
NIS-MIR210-2, NIS-MIR210-3, NIS-MIR210-4, NIS-MIR210-9,
NIS-MIR255-2, NIS-MIR255-3, NIS-MIR255-4, NIS-MIR255-9,

# NIRSpec FS and MOS
2-POINT-NOD, 3-POINT-NOD, 5-POINT-NOD,
2-POINT-WITH-NIRCAM-SIZE1, 2-POINT-WITH-NIRCAM-SIZE2, 2-POINT-WITH-NIRCAM-SIZE3,
3-POINT-WITH-NIRCAM-SIZE1, 3-POINT-WITH-NIRCAM-SIZE2, 3-POINT-WITH-NIRCAM-SIZE3,

# NIRSpec IFU
4-POINT-NOD, 4-POINT-DITHER, CYCLING, SPARSE-CYCLING,
2-POINT-NOD, 4-POINT-NOD, 4-POINT-DITHER, CYCLING, SPARSE-CYCLING,

# Misc
N/A, NONE, ANY]
Expand Down
6 changes: 3 additions & 3 deletions jwst/lib/set_telescope_pointing.py
Original file line number Diff line number Diff line change
Expand Up @@ -464,12 +464,12 @@ def update_wcs_from_telem(
'\nException is {}'.format(exception)
)
logger.info("Setting ENGQLPTG keyword to PLANNED")
model.meta.visit.pointing_engdb_quality = "PLANNED"
model.meta.visit.engdb_pointing_quality = "PLANNED"
else:
# compute relevant WCS information
logger.info('Successful read of engineering quaternions:')
logger.info('\tPointing = {}'.format(pointing))
model.meta.visit.pointing_engdb_quality = "CALCULATED"
model.meta.visit.engdb_pointing_quality = "CALCULATED"
try:
wcsinfo, vinfo = calc_wcs(pointing, siaf, **transform_kwargs)
logger.info("Setting ENGQLPTG keyword to CALCULATED")
Expand All @@ -483,7 +483,7 @@ def update_wcs_from_telem(
raise
else:
logger.info("Setting ENGQLPTG keyword to PLANNED")
model.meta.visit.pointing_engdb_quality = "PLANNED"
model.meta.visit.engdb_pointing_quality = "PLANNED"
logger.info('Aperture WCS info: {}'.format(wcsinfo))
logger.info('V1 WCS info: {}'.format(vinfo))

Expand Down

0 comments on commit f934522

Please sign in to comment.