hipercam.spooler

Classes and methods to support reading data in multiple formats and for iterating through multiple images from a variety of sources in a standardised manner.

For instance this piece of code:

with spooler.data_source(source, resource, first) as spool:
    for mccd in spool:
        ...

creates an object ‘spool’ that then acts a source of MCCD objects. The data_source() method returns this for a variety of possible sources of data such as raw HiPERCAM and ULTRACAM files and a list of hcm files. Important methods are data_source() and get_ccd_pars(). You may also want to look at classes such as HcamListSpool if you are interested in accessing data in a specific manner.

Functions

data_source(source, resource[, first])

Returns a context manager needed to run through a set of exposures.

get_ccd_pars(source, resource)

Returns a list of tuples of CCD labels, maximum dimensions, and padding factors (label, nxmax, nymax, nxpad, nypad) for each CCD pointed at by the input parameters.

hang_about(obj, twait, tmax, total_time)

Carries out some standard actions when we loop through frames which are common to rtplot, reduce and grab.

rhcam(fname)

Reads a HiPERCAM file containing either CCD or MCCD data and returns one or the other.

Classes

HcamDiskSpool(run[, first, full])

Provides an iterable context manager to loop through frames within a raw HiPERCAM file.

HcamListSpool(lname[, cnam])

Provides an iterable context manager to loop through frames within a list of HiPERCAM .hcm files, either a file listing the files, or a Python list.

HcamServSpool(run[, first])

Provides an iterable context manager to loop through frames within a raw HiPERCAM file served from Stu’s FileServer

SpoolerBase

A common requirement is the need to loop through a stack of images.

UcamDiskSpool(run[, first])

Provides an iterable context manager to loop through frames within a raw ULTRACAM or ULTRASPEC disk file.

UcamServSpool(run[, first])

Provides an iterable context manager to loop through frames within a raw ULTRACAM or ULTRASPEC raw file served from the ATC FileServer