SofiaCamera

class sofia_redux.scan.custom.sofia.channels.camera.SofiaCamera(name=None, parent=None, info=None, size=0)[source]

Bases: SingleColorArrangement

Initialize camera channels.

The Camera class extends the Channels class by including additional handling of the channels with respect to their field of view such as rotation with respect to a reference, correlated sky gradient modalities, and how to read and apply the hardware file containing channel data.

Parameters:
namestr, optional

The name for the channels.

parentobject, optional

The owner of the channels such as a Reduction, Scan or Integration.

infosofia_redux.scan.info.info.Info, optional

The channel information.

sizeint, optional

The number of stored channels.

Methods Summary

read_data(hdul)

Read a FITS HDU list to populate channel data.

read_pixel_data(filename)

Read the pixel data file.

read_rcp(filename)

Read and apply the RCP file information to channels (pixels).

Methods Documentation

abstract read_data(hdul)[source]

Read a FITS HDU list to populate channel data.

Parameters:
hdulfits.HDUList
Returns:
None
read_pixel_data(filename)[source]

Read the pixel data file.

If the instrument integration time is greater than zero, will set weighting accordingly. Otherwise, standard weights are used.

Parameters:
filenamestr

Path to the pixel data file.

Returns:
None
read_rcp(filename)[source]

Read and apply the RCP file information to channels (pixels).

The RCP information is read and applied from a given file. The RCP file should contain comma-separated values in one of following column formats:

CHANNEL_INDEX, X_POSITION(arcsec), Y_POSITION(arcsec) CHANNEL_INDEX, GAIN, X_POSITION(arcsec), Y_POSITION(arcsec) CHANNEL_INDEX, GAIN, COUPLING, X_POSITION(arcsec), Y_POSITION(arcsec)

All pixels not contained in the RCP file are flagged as BLIND, and will only be unflagged if a GAIN column is available in the file. The channel coupling will be set to GAIN/COUPLING or GAIN/channel.gain depending on the column format, or ignored if not available. X and Y positions are also set at this stage.

If no RCP information is available (no file), these attributes should be set via other methods.

Parameters:
filenamestr

Path to the RCP file.

Returns:
None