LSSTApplications  10.0+286,10.0+36,10.0+46,10.0-2-g4f67435,10.1+152,10.1+37,11.0,11.0+1,11.0-1-g47edd16,11.0-1-g60db491,11.0-1-g7418c06,11.0-2-g04d2804,11.0-2-g68503cd,11.0-2-g818369d,11.0-2-gb8b8ce7
LSSTDataManagementBasePackage
cameraConfig.py
Go to the documentation of this file.
1 import lsst.pex.config as pexConfig
2 from lsst.afw.geom import TransformMapConfig
3 
4 __all__ = ["CameraConfig", "DetectorConfig"]
5 
6 class DetectorConfig(pexConfig.Config):
7  """!A configuration that represents (and can be used to construct) a Detector
8  """
9  transformDict = pexConfig.ConfigField("Dictionary of camera transforms keyed on the transform type.", TransformMapConfig)
10  name = pexConfig.Field("Name of detector slot", str)
11  id = pexConfig.Field("ID of detector slot", int)
12  bbox_x0 = pexConfig.Field("x0 of pixel bounding box", int)
13  bbox_y0 = pexConfig.Field("y0 of pixel bounding box", int)
14  bbox_x1 = pexConfig.Field("x1 of pixel bounding box", int)
15  bbox_y1 = pexConfig.Field("y1 of pixel bounding box", int)
16  detectorType = pexConfig.Field("Detector type: SCIENCE=0, FOCUS=1, GUIDER=2, WAVEFRONT=3", int)
17  serial = pexConfig.Field("Serial string associated with this specific detector", str)
18  offset_x = pexConfig.Field("x offset from the origin of the camera in mm in the transposed system.", float)
19  offset_y = pexConfig.Field("y offset from the origin of the camera in mm in the transposed system.", float)
20  refpos_x = pexConfig.Field("x position of the reference point in the detector in pixels "+\
21  "in transposed coordinates.", float)
22  refpos_y = pexConfig.Field("y position of the reference point in the detector in pixels "+\
23  "in transposed coordinates.", float)
24  yawDeg = pexConfig.Field("yaw (rotation about z) of the detector in degrees. "+\
25  "This includes any necessary rotation to go from detector coordinates to camera coordinates "+\
26  "after optional transposition.", float)
27  pitchDeg = pexConfig.Field("pitch (rotation about y) of the detector in degrees", float)
28  rollDeg = pexConfig.Field("roll (rotation about x) of the detector in degrees", float)
29  pixelSize_x = pexConfig.Field("Pixel size in the x dimension in mm", float)
30  pixelSize_y = pexConfig.Field("Pixel size in the y dimension in mm", float)
31 
32  # Depending on the choice of detector coordinates, the pixel grid may need to be transposed before rotation to put
33  # it in camera coordinates.
34  transposeDetector = pexConfig.Field("Transpose the pixel grid before orienting in focal plane?", bool)
35 
36 class CameraConfig(pexConfig.Config):
37  """!A configuration that represents (and can be used to construct) a Camera
38  """
39  detectorList = pexConfig.ConfigDictField("List of detector configs", keytype=int, itemtype=DetectorConfig)
40  transformDict = pexConfig.ConfigField("Dictionary of camera transforms keyed on the transform type.", TransformMapConfig)
41  name = pexConfig.Field("Name of this camera", str)
42 
43  plateScale = pexConfig.Field("Plate scale of the camera in arcsec/mm", float)
44  # Note that the radial transform will also apply a scaling, so all coefficients should be
45  # scaled by the plate scale in appropriate units
46  radialCoeffs = pexConfig.ListField("Coefficients for radial distortion", float)
47  # The following is commented until radialXYTransform supports an offset (ticket/3155)
48  #boresiteOffset_x = pexConfig.Field("Offset of the camera coordinates system relative to the boresite (x value)", float)
49  #boresiteOffset_y = pexConfig.Field("Offset of the camera coordinates system relative to the boresite (y value)", float)
A configuration that represents (and can be used to construct) a Detector.
Definition: cameraConfig.py:6
A configuration that represents (and can be used to construct) a Camera.
Definition: cameraConfig.py:36