Detector#

final class lsst.images.cameras.Detector(attributes: DetectorAttributes, amplifiers: Iterable[Amplifier], frames: CameraFrameSet, visit: int | None = None)#

Bases: object

Information about a detector in a camera.

Attributes Summary

amplifiers

The amplifiers of this detectors (list [Amplifier]).

bbox

Bounding box of the detector's science data region after amplifier assembly (Box).

frame

The coordinate system of this detector's trimmed, assembled pixel grid (DetectorFrame).

id

ID of the detector (int).

instrument

The name of the instrument this detector belongs to (str).

name

Name of the detector (str).

orientation

Nominal position and rotation of the detector (Orientation).

physical_type

Vendor name or technology type for this detector (str).

pixel_size

Nominal size of a pixel (assumed square) in focal plane coordinate units (float).

serial

Serial number for the detector (str).

to_field_angle

The transform from pixels to field angle coordinates (Transform [DetectorFrame, FieldAngleFrame]).

to_focal_plane

The transform from pixels to focal-plane coordinates (Transform [DetectorFrame, FocalPlaneFrame]).

type

Enumerated type of the detector (DetectorType).

visit

The ID of the visit this detector is associated with (int or None).

Methods Summary

copy()

Copy the detector.

from_legacy(legacy_detector, *, instrument)

Convert from a legacy lsst.afw.cameraGeom.Detector instance.

serialize(archive[, save_frames])

Serialize this detector to an archive.

to_legacy(*[, is_raw_assembled])

Convert to a legacy lsst.afw.cameraGeom.Detector instance.

Attributes Documentation

amplifiers#

The amplifiers of this detectors (list [Amplifier]).

bbox#

Bounding box of the detector’s science data region after amplifier assembly (Box).

frame#

The coordinate system of this detector’s trimmed, assembled pixel grid (DetectorFrame).

id#

ID of the detector (int).

instrument#

The name of the instrument this detector belongs to (str).

name#

Name of the detector (str).

orientation#

Nominal position and rotation of the detector (Orientation).

physical_type#

Vendor name or technology type for this detector (str).

This may have a different interpretation for different cameras.

pixel_size#

Nominal size of a pixel (assumed square) in focal plane coordinate units (float).

serial#

Serial number for the detector (str).

to_field_angle#

The transform from pixels to field angle coordinates (Transform [DetectorFrame, FieldAngleFrame]).

to_focal_plane#

The transform from pixels to focal-plane coordinates (Transform [DetectorFrame, FocalPlaneFrame]).

type#

Enumerated type of the detector (DetectorType).

visit#

The ID of the visit this detector is associated with (int or None).

Methods Documentation

copy() Detector#

Copy the detector.

This deep-copies all data fields and amplifiers, but only shallow-copies the internal CameraFrameSet, as that’s conceptually immutable.

static from_legacy(legacy_detector: LegacyDetector, *, instrument: str, visit: int | None = None, is_raw_assembled: bool | None = None) Detector#

Convert from a legacy lsst.afw.cameraGeom.Detector instance.

Parameters#

legacy_detector

Legacy detector to convert.

instrument

Name of the instrument this detector belongs to.

visit

Visit ID, if this camera geometry can be associated with a particular visit.

is_raw_assembled

Whether to populate Amplifier.assembled_raw_geometry (True) or Amplifier.unassembled_raw_geometry (False). If None, this is set to visit is not None, since we expect to only add a visit ID to detectors that have been assembled.

serialize(archive: OutputArchive[Any], save_frames: bool = True) DetectorSerializationModel#

Serialize this detector to an archive.

Parameters#

archive

Archive to save to.

save_frames

Whether to save the CameraFrameSet held by this detector. This allows the frame set to be saved once for multiple detectors when they are part of a multi-detector object.

to_legacy(*, is_raw_assembled: bool | None = None) LegacyDetector#

Convert to a legacy lsst.afw.cameraGeom.Detector instance.

Parameters#

is_raw_assembled

Whether to use Amplifier.assembled_raw_geometry (True) or Amplifier.unassembled_raw_geometry (False). If None, this is set to self.visit is not None, since we expect to only add a visit ID to detectors that have been assembled.