apero_precheck

Contents

1. Description

SHORTNAME: PRECHECK

The precheck recipe allows the user to check the current raw data stored in the DRS_DATA_RAW directory. These checks are split into two parts a file check and a object check. The checks are based on a supplied run-ini-file which controls which recipes are and are not being used for a specific apero_processing run.

The file checks are as follows:

  1. The number of calibrations in each observation-directory and whether this meets the minimum number of calibrations required for the sequence defined in the run-ini-file. A list of observation-directories that will cause problems due to missing calibrations is printed during the precheck recipe run.

    Note

    Note if the observation-directory is sorted by observation night this will correctly flag if there are nights without calibrations within +/- the required time frame (controlled by MAX_CALIB_DTIME) but will not be able to assess whether calibrations pass quality control during processing.

  2. The number of science and telluric files found (note if the run-in-file has USE_ENGINEERING = False any observation-directory without science files will be ignored by the apero_processing recipe. The list of engineering observation-directories is also printed during the precheck recipe run.

The object check is done as follows:

  1. The object database is checked for all valid entries (and any ignore entries)

  2. All unique object names in raw files are checked against the object database object names (and associated aliases of each object name)

  3. Any object name not in the current database and not in the current ignore list are printed for the user to decide whether object must be added to the database or left to use the header values

Note

Objects are only required in the database for accurate BERV calculations, as such only objects required precision radial velocity must be in the database, however we recommend all objects be added.

2. Schematic

No schematic set

3. Usage

apero_precheck.py {runfile}[STRING] {options}
{runfile}[STRING] // [STRING] The run file to use in reprocessing

4. Optional Arguments

--obs_dir[STRING] // PROCESS_OBS_DIR_HELP
--exclude_obs_dirs[STRING] // PROCESS_EXCLUDE_OBS_DIRS_HELP
--include_obs_dirs[STRING] // PROCESS_INCLUDE_OBS_DIRS_HELP
--no_file_check // Don’t check the number of files on disk and don’t flag these errors
--no_obj_check // Don’t check object database with current set of raw files and don’t flag these errors

5. Special Arguments

--xhelp[STRING] // Extended help menu (with all advanced arguments)
--debug[STRING] // Activates debug mode (Advanced mode [INTEGER] value must be an integer greater than 0, setting the debug level)
--listing[STRING] // Lists the night name directories in the input directory if used without a 'directory' argument or lists the files in the given 'directory' (if defined). Only lists up to 15 files/directories
--listingall[STRING] // Lists ALL the night name directories in the input directory if used without a 'directory' argument or lists the files in the given 'directory' (if defined)
--version[STRING] // Displays the current version of this recipe.
--info[STRING] // Displays the short version of the help menu
--program[STRING] // [STRING] The name of the program to display and use (mostly for logging purpose) log becomes date | {THIS STRING} | Message
--recipe_kind[STRING] // [STRING] The recipe kind for this recipe run (normally only used in apero_processing.py)
--parallel[STRING] // [BOOL] If True this is a run in parellel - disable some features (normally only used in apero_processing.py)
--shortname[STRING] // [STRING] Set a shortname for a recipe to distinguish it from other runs - this is mainly for use with apero processing but will appear in the log database
--idebug[STRING] // [BOOLEAN] If True always returns to ipython (or python) at end (via ipdb or pdb)
--ref[STRING] // If set then recipe is a reference recipe (e.g. reference recipes write to calibration database as reference calibrations)
--crunfile[STRING] // Set a run file to override default arguments
--quiet[STRING] // Run recipe without start up text
--nosave // Do not save any outputs (debug/information run). Note some recipes require other recipesto be run. Only use --nosave after previous recipe runs have been run successfully at least once.
--force_indir[STRING] // [STRING] Force the default input directory (Normally set by recipe)
--force_outdir[STRING] // [STRING] Force the default output directory (Normally set by recipe)

6. Output directory

DRS_DATA_REDUC // Default: "red" directory

7. Output files

N/A

8. Debug plots

No debug plots.

9. Summary plots

No summary plots.