lsst.obs.decam gff490e6085+238a0b469f
Loading...
Searching...
No Matches
Public Member Functions | Public Attributes | Protected Member Functions | Static Protected Attributes | List of all members
lsst.obs.decam.ingest.DecamParseTask Class Reference
Inheritance diagram for lsst.obs.decam.ingest.DecamParseTask:

Public Member Functions

def __init__ (self, *args, **kwargs)
 
def buildExpnumMapper (self, basepath)
 
def getInfo (self, filename, filetype="raw")
 
def getDestination (self, butler, info, filename, filetype="raw")
 

Public Attributes

 expnumMapper
 
 instcalPrefix
 
 dqmaskPrefix
 
 wtmapPrefix
 

Protected Member Functions

def _listdir (self, path, prefix)
 

Static Protected Attributes

DecamTranslator _translatorClass = DecamTranslator
 

Detailed Description

Parse an image filename to get the required information to
put the file in the correct location and populate the registry.

Member Function Documentation

◆ buildExpnumMapper()

def lsst.obs.decam.ingest.DecamParseTask.buildExpnumMapper (   self,
  basepath 
)
Extract exposure numbers from filenames to set self.expnumMapper

Parameters
----------
basepath : `str`
    Location on disk of instcal, dqmask, and wtmap subdirectories.

◆ getDestination()

def lsst.obs.decam.ingest.DecamParseTask.getDestination (   self,
  butler,
  info,
  filename,
  filetype = "raw" 
)
Get destination for the file

Parameters
----------
butler : `lsst.daf.persistence.Butler`
    Data butler.
info : data ID
    File properties, used as dataId for the butler.
filename : `str`
    Input filename.

Returns
-------
raw : `str`
    Destination filename.

◆ getInfo()

def lsst.obs.decam.ingest.DecamParseTask.getInfo (   self,
  filename,
  filetype = "raw" 
)
Get metadata header info from multi-extension FITS decam image file.

The science pixels, mask, and weight (inverse variance) are
stored in separate files each with a unique name but with a
common unique identifier EXPNUM in the FITS header.  We have
to aggregate the 3 filenames for a given EXPNUM and return
this information along with that returned by the base class.

Parameters
----------
filename : `str`
    Image file to retrieve info from.
filetype : `str`
    One of "raw" or "instcal".

Returns
-------
phuInfo : `dict`
    Primary header unit info.
infoList : `list` of `dict`
    Info for the other HDUs.

Notes
-----
For filetype="instcal", we expect a directory structure that looks
like the following:

.. code-block:: none

    dqmask/
    instcal/
    wtmap/

The user creates the registry by running:

.. code-block:: none

    ingestImagesDecam.py outputRepository --filetype=instcal --mode=link instcal/*fits

The documentation for this class was generated from the following file: