LSST Applications g0d97872fb5+4fd969bb9d,g1653933729+34a971ddd9,g28da252d5a+072f89fe25,g2bbee38e9b+a99b0ab4cd,g2bc492864f+a99b0ab4cd,g2ca4be77d2+c0e3b27cd8,g2cdde0e794+704103fe75,g3156d2b45e+6e87dc994a,g347aa1857d+a99b0ab4cd,g35bb328faa+34a971ddd9,g3a166c0a6a+a99b0ab4cd,g3e281a1b8c+8ec26ec694,g4005a62e65+ba0306790b,g414038480c+9ed5ed841a,g569e0e2b34+cb4faa46ad,g5a97de2502+520531a62c,g717e5f8c0f+29153700a5,g7ede599f99+367733290c,g80478fca09+17051a22cc,g82479be7b0+f2f1ea0a87,g858d7b2824+29153700a5,g8b782ad322+29153700a5,g8cd86fa7b1+05420e7f7d,g9125e01d80+34a971ddd9,ga5288a1d22+e7f674aaf3,gae0086650b+34a971ddd9,gae74b0b5c6+45ef5cdc51,gb58c049af0+ace264a4f2,gc28159a63d+a99b0ab4cd,gcf0d15dbbd+8051a81198,gda6a2b7d83+8051a81198,gdaeeff99f8+7774323b41,gdf4d240d4a+34a971ddd9,ge2409df99d+cb167bac99,ge33fd446bb+29153700a5,ge79ae78c31+a99b0ab4cd,gf0baf85859+890af219f9,gf5289d68f6+9faa5c5784,w.2024.36
LSST Data Management Base Package
Loading...
Searching...
No Matches
Public Member Functions | Public Attributes | Static Public Attributes | List of all members
lsst.meas.algorithms.simple_curve.DetectorCurve Class Reference
Inheritance diagram for lsst.meas.algorithms.simple_curve.DetectorCurve:
lsst.meas.algorithms.simple_curve.Curve

Public Member Functions

 __eq__ (self, other)
 
 fromTable (cls, table)
 
 toTable (self)
 
 evaluate (self, detector, position, wavelength, kind='linear', bounds_error=False, fill_value=0)
 

Public Attributes

 wavelength
 
 efficiency
 

Static Public Attributes

str mode = 'DETECTOR'
 

Detailed Description

Subclass of `Curve` that represents a single curve per detector.

Parameters
----------
wavelength : `astropy.units.Quantity`
    Wavelength values for this curve
efficiency : `astropy.units.Quantity`
    Quantum efficiency values for this curve
metadata : `dict`
    Dictionary of metadata for this curve

Definition at line 296 of file simple_curve.py.

Member Function Documentation

◆ __eq__()

lsst.meas.algorithms.simple_curve.DetectorCurve.__eq__ ( self,
other )
Define equality for this class

Reimplemented from lsst.meas.algorithms.simple_curve.Curve.

Definition at line 310 of file simple_curve.py.

310 def __eq__(self, other):
311 return (self.compare_metadata(other)
312 and numpy.array_equal(self.wavelength, other.wavelength)
313 and numpy.array_equal(self.wavelength, other.wavelength))
314

◆ evaluate()

lsst.meas.algorithms.simple_curve.DetectorCurve.evaluate ( self,
detector,
position,
wavelength,
kind = 'linear',
bounds_error = False,
fill_value = 0 )
Interpolate the curve at the specified position and wavelength.

Parameters
----------
detector : `lsst.afw.cameraGeom.Detector`
    Is used to find the appropriate curve given the position for
    curves that vary over the detector.  Ignored in the case where
    there is only a single curve per detector.
position : `lsst.geom.Point2D`
    The position on the detector at which to evaluate the curve.
wavelength : `astropy.units.Quantity`
    The wavelength(s) at which to make the interpolation.
kind : `str`, optional
    The type of interpolation to do (default is 'linear').
    See documentation for `scipy.interpolate.interp1d` for
    accepted values.
bounds_error : `bool`, optional
    Raise error if interpolating outside the range of x?
    (default is False)
fill_value : `float`, optional
    Fill values outside the range of x with this value
    (default is 0).

Returns
-------
value : `astropy.units.Quantity`
    Interpolated value(s).  Number of values returned will match the
    length of `wavelength`.

Raises
------
ValueError
    If the ``bounds_error`` is changed from the default, it will raise
    a `ValueError` if evaluating outside the bounds of the curve.

Reimplemented from lsst.meas.algorithms.simple_curve.Curve.

Definition at line 325 of file simple_curve.py.

325 def evaluate(self, detector, position, wavelength, kind='linear', bounds_error=False, fill_value=0):
326 # Docstring inherited from base classs
327 return self.interpolate(self.wavelength, self.efficiency, wavelength,
328 kind=kind, bounds_error=bounds_error, fill_value=fill_value)
329
330

◆ fromTable()

lsst.meas.algorithms.simple_curve.DetectorCurve.fromTable ( cls,
table )
Class method for constructing a `Curve` object.

Parameters
----------
table : `astropy.table.QTable`
    Table containing metadata and columns necessary
    for constructing a `Curve` object.

Returns
-------
curve : `Curve`
    A `Curve` subclass of the appropriate type according
    to the table metadata

Reimplemented from lsst.meas.algorithms.simple_curve.Curve.

Definition at line 316 of file simple_curve.py.

316 def fromTable(cls, table):
317 # Docstring inherited from base classs
318 cls._check_cols(['wavelength', 'efficiency'], table)
319 return cls(table['wavelength'], table['efficiency'], table.meta)
320

◆ toTable()

lsst.meas.algorithms.simple_curve.DetectorCurve.toTable ( self)
Convert this `Curve` object to an `astropy.table.QTable`.

Returns
-------
table : `astropy.table.QTable`
    A table object containing the data from this `Curve`.

Reimplemented from lsst.meas.algorithms.simple_curve.Curve.

Definition at line 321 of file simple_curve.py.

321 def toTable(self):
322 # Docstring inherited from base classs
323 return QTable({'wavelength': self.wavelength, 'efficiency': self.efficiency}, meta=self.metadata)
324

Member Data Documentation

◆ efficiency

lsst.meas.algorithms.simple_curve.DetectorCurve.efficiency

Definition at line 327 of file simple_curve.py.

◆ mode

str lsst.meas.algorithms.simple_curve.DetectorCurve.mode = 'DETECTOR'
static

Definition at line 308 of file simple_curve.py.

◆ wavelength

lsst.meas.algorithms.simple_curve.DetectorCurve.wavelength

Definition at line 312 of file simple_curve.py.


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