Automated typing of Keck/MOSFIRE frames
Version History
Version |
Author |
Date |
|
---|---|---|---|
1.0 |
Debora Pelliccia |
24 Oct 2021 |
1.6.1.dev |
1.1 |
Debora Pelliccia |
12 Jul 2021 |
1.9.2.dev |
Basics
The general procedure used to assign frames a given type is described here: Frame Types.
MOSFIRE frame typing
The primary typing of MOSFIRE frames is performed by
pypeit.spectrographs.keck_mosfire.KeckMOSFIRESpectrograph.check_frame_type()
.
This function checks the values of various header keywords against a
set of criteria used to classify the frame type. The header cards
required for the frame-typing and their associated keyword (when available)
in the PypeItMetaData
object are:
Header Key
fitstbl
key
TRUITIME
exptime
FLATSPEC
lampstat01
PWSTATA7
No key
PWSTATA8
No key
OBJECT
object
FILTER
filter1
No key
idname
MASKNAME
decker
idname
is defined using a combination of header keys, including PWSTATA7
and PWSTATA8
(see below).
The criteria used to select each frame type are as follows:
Frame |
|
|
|
|
|
|
|
|
---|---|---|---|---|---|---|---|---|
|
|
|
|
|
|
|
|
Not used |
|
|
|
|
|
|
|
|
Not used |
|
|
Not used |
|
Not used |
Not used |
|
Not used |
Not used |
|
|
Not used |
|
|
|
|
Not used |
Not used |
|
|
Not used |
|
|
|
|
Not used |
Not used |
|
|
Not used |
|
|
|
|
Not used |
Not used |
|
|
Not used |
|
|
|
|
|
Not used |
|
|
Not used |
|
|
|
|
Not used |
Not used |
|
|
Not used |
|
|
|
|
|
|
|
|
Not used |
|
|
|
|
Not used |
Not used |
|
|
Not used |
|
|
|
|
|
|
Note that, by default, the exposure time (TRUITIME
) is only used
to distinguish between science
and standard
frames; the criteria
for TRUITIME
can be changed using the exprng
parameter in the PypeIt Reduction File; see also Frame Types.
Importantly, note that a MOSFIRE frame is never given a pinhole
type. Also note that the criteria used to select arc
and tilt
frames are identical. The same is true for pixelflat
, trace
,
and illumflat
frames.
Testing
- PYPEIT-MOSFIRE
Requirement PM-4 states: “As a user, I want the pipeline to automatically classify my calibrations.”
PypeIt
meets this requirement as demonstrated by the test at
${PYPEIT_DEV}/unit_tests/test_frametype.py
. To run the test:
cd ${PYPEIT_DEV}/unit_tests
pytest test_frametype.py::test_mosfire -W ignore
The test requires that you have downloaded the PypeIt
PypeIt Development Suite and defined the PYPEIT_DEV
environmental
variable that points to the relevant directory. The algorithm of the
test is as follows:
Find all the directories in the PypeIt Development Suite where a selected sample of Keck MOSFIRE data is.
For each directory (i.e., instrument setup):
Make sure there is a “by-hand” version of the pypeit file for this setup where a human (one of the pypeit developers) has ensured the frame types are correct.
Effectively run pypeit_setup on each of the instrument setups to construct a new pypeit file with the automatically generated frame types.
Read both the by-hand and automatically generated frame types from these two pypeit files and check that they are identical.
Because this test is now included in the PypeIt
Unit Tests (GitHub CI), this frame-typing check is performed by the
developers for every new version of the code.