hispecdrp.datamodels.hispec_config

Classes

HISPECConfig()

class HISPECConfig[source]

Bases: object

DETECTOR_SIZE = (4096, 4160)
echelle_orders = {'BSPEC': {'order_end': 148, 'order_start': 110}, 'RSPEC': {'order_end': 97, 'order_start': 60}}
classmethod get_instrument_alias(model=None, spectrograph=None)[source]
classmethod get_metadata_schema()[source]
classmethod get_order_list(spectrograph)[source]

Return the list of echelle order numbers for a spectrograph (single source of truth). Used by benchmarks and trace finding so order count and indices match model meta.

instrument_aliases = {'BSPEC': 'HB', 'RSPEC': 'HR'}
instrument_name = 'HISPEC'
lfc_params = {'LFC-B': {'delta_nu': 20000000000.0, 'nu0': 5220000000.0}, 'LFC-R': {'delta_nu': 16000000000.0, 'nu0': 192185284352589.47}}
metadata_schema_filename = 'hispec_metadata_schema.yaml'
num_fibers = 3
classmethod set_meta_defaults(model)[source]

Apply defaults dynamically. These will continue to evolve as the DRP is developed.

Returns:

meta_schema (dict) – The metadata schema dictionary.

classmethod sync_echelle_orders_for_spectrograph(model, spectrograph)[source]

Set meta.spectrograph, meta.order_start, and meta.order_end from echelle_orders for the given spectrograph.

Use this when constructing or reloading simulated data so echelle order labels match get_order_list() and primitives that rely on make_order_vec() (e.g. spectral extraction, stellar RV), including after FITS headers carried stale ORDERST/ORDEREND from an older run.