DiaForcedSourceId

class lsst.dax.apdb.DiaForcedSourceId(*, diaObjectId: int, visit: int, detector: int, ra: float, dec: float, midpointMjdTai: float)

Bases: object

Collection of data items identifying DIAForcedSource records.

DIAForcedSource primary key is (diaObjectId, visit, detector), in Cassandra the table is partitioned by both spatial coordinates (ra and dec) and time (midpointMjdTai).

Attributes Summary

dec

DIAForcedSource dec, in degrees.

detector

Detector ID.

diaObjectId

ID of parent DIAObject record.

midpointMjdTai

DIAForcedSource midpointMjdTai, not required to be exact, but needs to be close to the value in database record.

ra

DIAForcedSource ra, in degrees.

visit

Visit ID.

Methods Summary

from_named_tuple(named_tuple)

Construct DiaForcedSourceId from a named tuple.

Attributes Documentation

dec: float

DIAForcedSource dec, in degrees. Not required to be exact, but needs to be close to the value in database record.

detector: int

Detector ID.

diaObjectId: int

ID of parent DIAObject record.

midpointMjdTai: float

DIAForcedSource midpointMjdTai, not required to be exact, but needs to be close to the value in database record.

ra: float

DIAForcedSource ra, in degrees. Not required to be exact, but needs to be close to the value in database record.

visit: int

Visit ID.

Methods Documentation

classmethod from_named_tuple(named_tuple: Any) DiaForcedSourceId

Construct DiaForcedSourceId from a named tuple.

Parameters:
named_tuple

Named tuple which includes the same attributes as this class, e.g. a tuple returned from pandas.DataFrame.itertuples(). Any additional attributes are ignored.

Returns:
object_idDiaForcedSourceId

Instance of this class.