LSST Applications 24.1.5,g02d81e74bb+fa3a7a026e,g180d380827+a53a32eff8,g2079a07aa2+86d27d4dc4,g2305ad1205+c0501b3732,g295015adf3+7d3e92f0ec,g2bbee38e9b+0e5473021a,g337abbeb29+0e5473021a,g33d1c0ed96+0e5473021a,g3a166c0a6a+0e5473021a,g3ddfee87b4+5dd1654d75,g48712c4677+3bf1020dcb,g487adcacf7+065c13d9cf,g50ff169b8f+96c6868917,g52b1c1532d+585e252eca,g591dd9f2cf+d7ac436cfb,g5a732f18d5+53520f316c,g64a986408d+fa3a7a026e,g858d7b2824+fa3a7a026e,g8a8a8dda67+585e252eca,g99cad8db69+a5a909b84f,g9ddcbc5298+9a081db1e4,ga1e77700b3+15fc3df1f7,ga8c6da7877+4cf350ccb2,gb0e22166c9+60f28cb32d,gba4ed39666+c2a2e4ac27,gbb8dafda3b+f991a0b59f,gc120e1dc64+9ccbfdb8be,gc28159a63d+0e5473021a,gcf0d15dbbd+5dd1654d75,gd96a1ce819+42fd0ee607,gdaeeff99f8+f9a426f77a,ge6526c86ff+0d71447b4b,ge79ae78c31+0e5473021a,gee10cc3b42+585e252eca,gff1a9f87cc+fa3a7a026e
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: