Skip to content

Commit

Permalink
JP-3445: Exclude NINTS=1 from SOSS TSO3 associations (#8359)
Browse files Browse the repository at this point in the history
  • Loading branch information
hbushouse authored Mar 15, 2024
1 parent d787bea commit 77c4966
Show file tree
Hide file tree
Showing 3 changed files with 38 additions and 0 deletions.
3 changes: 3 additions & 0 deletions CHANGES.rst
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,9 @@ associations

- Isolate candidate processing into their own pools [#8227]

- Update the level-3 rules for "tso3" associations so that NIRISS SOSS
exposures with NINTS=1 are excluded. [#8359]

background
----------

Expand Down
18 changes: 18 additions & 0 deletions jwst/associations/lib/rules_level3.py
Original file line number Diff line number Diff line change
Expand Up @@ -903,6 +903,24 @@ def __init__(self, *args, **kwargs):
]),
],
reduce=Constraint.notany
),
# Don't allow NIRISS SOSS with NINTS=1 in tso3
Constraint(
[
Constraint([
DMSAttrConstraint(
name='exp_type',
sources=['exp_type'],
value = ('nis_soss')
),
DMSAttrConstraint(
name='nints',
sources=['nints'],
value = ('1')
),
]),
],
reduce=Constraint.notany
)
])

Expand Down
17 changes: 17 additions & 0 deletions jwst/associations/tests/data/pool_034_tso_nints_one.csv
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
# NIRISS SOSS observation that includes an extra "dummy" exposure with NINTS=1
#
# Based on PID 3596
FILENAME|OBS_ID|PROGRAM|OBS_NUM|VISIT|VISIT_ID|VISITGRP|VISITYPE|SEQ_ID|ACT_ID|EXPOSURE|EXP_TYPE|NEXPOSUR|EXPCOUNT|INSTRUME|DETECTOR|CHANNEL|TARGETID|TARGPROP|TARGNAME|TARGTYPE|TEMPLATE|PNTGTYPE|PNTG_SEQ|TARGORDN|EXPSPCIN|DITHPTIN|MOSTILNO|MODULE|FILTER|PUPIL|DITHERID|PATTTYPE|PATTSTRT|NUMDTHPT|PATTSIZE|SUBPXPTS|PATT_NUM|SUBPIXEL|APERNAME|SDP_VER|SUBARRAY|GRATING|FXD_SLIT|BAND|GWA_XTIL|GWA_YTIL|ASN_CANDIDATE|EXPOSERR|IS_PSF|IS_IMPRT|BKGDTARG|TSOVISIT|MSASTATE|MSAMETFL|OPMODE|LAMP|SPEC_NUM|SPAT_NUM|DMS_NOTE|EXSEGTOT|NINTS
#
# Initialize ACID. This is done with a dummy exposure that will not match any association
set acid|OBS_ID|PROGRAM|OBS_NUM|VISIT|VISIT_ID|VISITGRP|VISITYPE|SEQ_ID|ACT_ID|EXPOSURE|EXP_TYPE|NEXPOSUR|EXPCOUNT|INSTRUME|DETECTOR|CHANNEL|TARGETID|TARGPROP|TARGNAME|TARGTYPE|TEMPLATE|PNTGTYPE|PNTG_SEQ|TARGORDN|EXPSPCIN|DITHPTIN|MOSTILNO|MODULE|FILTER|PUPIL|DITHERID|PATTTYPE|PATTSTRT|NUMDTHPT|PATTSIZE|SUBPXPTS|PATT_NUM|SUBPIXEL|APERNAME|SDP_VER|SUBARRAY|GRATING|FXD_SLIT|BAND|GWA_XTIL|GWA_YTIL|@!next(acid)|EXPOSERR|IS_PSF|IS_IMPRT|BKGDTARG|TSOVISIT|MSASTATE|MSAMETFL|OPMODE|LAMP|SPEC_NUM|SPAT_NUM|DMS_NOTE|EXSEGTOT|NINTS
#
@!fmt_fname(next(expnum))|jw03596001001_02101_00001-seg001_nis_uncal.fits|V03596001001P0000000002101|3596|@!next(obsnum)|1|03596001001|2|PRIME_TARGETED_FIXED|1|01|1|NIS_TACQ|7|1|NIRISS|NIS|NULL|1|V-DR-TAU|V* DR Tau|FIXED|NIRISS Single-Object Slitless Spectroscopy|TARGET_ACQUISITION|1|0|0|0|0|NULL|F480M|NRM|NULL|NONE|NULL|1|NULL|NULL|0|NULL|NIS_SOSSTA|2023_3b|SUBTASOSS|NULL|NULL|NULL|NULL|NULL|@!fmt_cand([(obsnum.value, 'OBSERVATION'), ('c1000', 'GROUP')])|NULL|NULL|NULL|F|T|NULL|NULL|NULL|NONE|NULL|NULL|NULL|1|1
@!fmt_fname(next(expnum))|jw03596001001_02101_00002-seg001_nis_uncal.fits|V03596001001P0000000002101|3596|@!obsnum.value|1|03596001001|2|PRIME_TARGETED_FIXED|1|01|2|NIS_TACQ|7|1|NIRISS|NIS|NULL|1|V-DR-TAU|V* DR Tau|FIXED|NIRISS Single-Object Slitless Spectroscopy|TARGET_ACQUISITION|1|0|0|0|0|NULL|F480M|NRM|NULL|NONE|NULL|1|NULL|NULL|0|NULL|NIS_SOSSTA|2023_3b|SUBTASOSS|NULL|NULL|NULL|NULL|NULL|@!fmt_cand([(obsnum.value, 'OBSERVATION'), ('c1000', 'GROUP')])|NULL|NULL|NULL|F|T|NULL|NULL|NULL|NONE|NULL|NULL|NULL|1|1
@!fmt_fname(next(expnum))|jw03596001001_02101_00003-seg001_nis_uncal.fits|V03596001001P0000000002101|3596|@!obsnum.value|1|03596001001|2|PRIME_TARGETED_FIXED|1|01|3|NIS_TACQ|7|1|NIRISS|NIS|NULL|1|V-DR-TAU|V* DR Tau|FIXED|NIRISS Single-Object Slitless Spectroscopy|TARGET_ACQUISITION|1|0|0|0|0|NULL|F480M|NRM|NULL|NONE|NULL|1|NULL|NULL|0|NULL|NIS_SOSSTA|2023_3b|SUBTASOSS|NULL|NULL|NULL|NULL|NULL|@!fmt_cand([(obsnum.value, 'OBSERVATION'), ('c1000', 'GROUP')])|NULL|NULL|NULL|F|T|NULL|NULL|NULL|NONE|NULL|NULL|NULL|1|1
@!fmt_fname(next(expnum))|jw03596001001_02101_00004-seg001_nis_uncal.fits|V03596001001P0000000002101|3596|@!obsnum.value|1|03596001001|2|PRIME_TARGETED_FIXED|1|01|4|NIS_TACONFIRM|7|1|NIRISS|NIS|NULL|1|V-DR-TAU|V* DR Tau|FIXED|NIRISS Single-Object Slitless Spectroscopy|TARGET_ACQUISITION|1|0|0|0|0|NULL|F480M|NRM|NULL|NONE|NULL|1|NULL|NULL|0|NULL|NIS_SOSSTA|2023_3b|SUBTASOSS|NULL|NULL|NULL|NULL|NULL|@!fmt_cand([(obsnum.value, 'OBSERVATION'), ('c1000', 'GROUP')])|NULL|NULL|NULL|F|T|NULL|NULL|NULL|NONE|NULL|NULL|NULL|1|1
@!fmt_fname(next(expnum))|jw03596001001_03101_00001-seg001_nis_uncal.fits|V03596001001P0000000003101|3596|@!obsnum.value|1|03596001001|3|PRIME_TARGETED_FIXED|1|01|1|NIS_SOSS|7|5|NIRISS|NIS|NULL|1|V-DR-TAU|V* DR Tau|FIXED|NIRISS Single-Object Slitless Spectroscopy|SCIENCE|2|1|1|1|1|NULL|CLEAR|GR700XD|NULL|NULL|NULL|1|NULL|NULL|1|NULL|NIS_SUBSTRIP96|2023_3b|SUBSTRIP96|NULL|NULL|NULL|NULL|NULL|@!fmt_cand([(obsnum.value, 'OBSERVATION'), ('c1000', 'GROUP')])|NULL|NULL|NULL|F|T|NULL|NULL|NULL|NONE|NULL|NULL|NULL|1|1
@!fmt_fname(next(expnum))|jw03596001001_03102_00001-seg001_nis_uncal.fits|V03596001001P0000000003102|3596|@!obsnum.value|1|03596001001|3|PRIME_TARGETED_FIXED|1|02|1|NIS_SOSS|7|6|NIRISS|NIS|NULL|1|V-DR-TAU|V* DR Tau|FIXED|NIRISS Single-Object Slitless Spectroscopy|SCIENCE|3|1|2|1|1|NULL|CLEAR|GR700XD|NULL|NULL|NULL|1|NULL|NULL|1|NULL|NIS_SUBSTRIP96|2023_3b|SUBSTRIP96|NULL|NULL|NULL|NULL|NULL|@!fmt_cand([(obsnum.value, 'OBSERVATION'), ('c1000', 'GROUP')])|NULL|NULL|NULL|F|T|NULL|NULL|NULL|NONE|NULL|NULL|NULL|3|1350
@!fmt_fname(next(expnum))|jw03596001001_03102_00001-seg002_nis_uncal.fits|V03596001001P0000000003102|3596|@!obsnum.value|1|03596001001|3|PRIME_TARGETED_FIXED|1|02|1|NIS_SOSS|7|6|NIRISS|NIS|NULL|1|V-DR-TAU|V* DR Tau|FIXED|NIRISS Single-Object Slitless Spectroscopy|SCIENCE|3|1|2|1|1|NULL|CLEAR|GR700XD|NULL|NULL|NULL|1|NULL|NULL|1|NULL|NIS_SUBSTRIP96|2023_3b|SUBSTRIP96|NULL|NULL|NULL|NULL|NULL|@!fmt_cand([(obsnum.value, 'OBSERVATION'), ('c1000', 'GROUP')])|NULL|NULL|NULL|F|T|NULL|NULL|NULL|NONE|NULL|NULL|NULL|3|1350
@!fmt_fname(next(expnum))|jw03596001001_03102_00001-seg003_nis_uncal.fits|V03596001001P0000000003102|3596|@!obsnum.value|1|03596001001|3|PRIME_TARGETED_FIXED|1|02|1|NIS_SOSS|7|6|NIRISS|NIS|NULL|1|V-DR-TAU|V* DR Tau|FIXED|NIRISS Single-Object Slitless Spectroscopy|SCIENCE|3|1|2|1|1|NULL|CLEAR|GR700XD|NULL|NULL|NULL|1|NULL|NULL|1|NULL|NIS_SUBSTRIP96|2023_3b|SUBSTRIP96|NULL|NULL|NULL|NULL|NULL|@!fmt_cand([(obsnum.value, 'OBSERVATION'), ('c1000', 'GROUP')])|NULL|NULL|NULL|F|T|NULL|NULL|NULL|NONE|NULL|NULL|NULL|3|1350
@!fmt_fname(next(expnum))|jw03596001001_03103_00001-seg001_nis_uncal.fits|V03596001001P0000000003103|3596|@!obsnum.value|1|03596001001|3|PRIME_TARGETED_FIXED|1|03|1|NIS_SOSS|7|7|NIRISS|NIS|NULL|1|V-DR-TAU|V* DR Tau|FIXED|NIRISS Single-Object Slitless Spectroscopy|SCIENCE|4|1|3|1|1|NULL|F277W|GR700XD|NULL|NULL|NULL|1|NULL|NULL|1|NULL|NIS_SUBSTRIP96|2023_3b|SUBSTRIP96|NULL|NULL|NULL|NULL|NULL|@!fmt_cand([(obsnum.value, 'OBSERVATION'), ('c1000', 'GROUP')])|NULL|NULL|NULL|F|T|NULL|NULL|NULL|NONE|NULL|NULL|NULL|1|2

0 comments on commit 77c4966

Please sign in to comment.