soxspipe.commonutils.filenamer

Given a FITS object, use the SOXS file-naming scheme to return a filename to be used to save the FITS object to disk

Author

David Young

Date Created

March 9, 2021

Module Contents

Functions

filenamer

Given a FITS object, use the SOXS file-naming scheme to return a filename to be used to save the FITS object to disk

API

soxspipe.commonutils.filenamer.filenamer(log, frame, keywordLookup=False, detectorLookup=False, settings=False)[source][source]

Given a FITS object, use the SOXS file-naming scheme to return a filename to be used to save the FITS object to disk

Key Arguments:

  • log – logger

  • frame – the CCDData object frame

  • keywordLookup – the keyword lookup dictionary (needed if settings not provided). Default False

  • detectorLookup – the detector parameters (needed if settings not provided). Default False

  • settings – the soxspipe settings dictionary (needed if keywordLookup and detectorLookup not provided). Default False

Return:

  • filename – stanardised name to for the input frame

frame = CCDData.read(filepath, hdu=0, unit=u.electron, hdu_uncertainty='ERRS',
        du_mask='QUAL', hdu_flags='FLAGS', key_uncertainty_type='UTYPE')

from soxspipe.commonutils import filenamer
filename = filenamer(
    log=log,
    frame=frame,
    settings=settings
)