Camera Alert ( antares.model.alert.CameraAlert )

class antares.model.alert.CameraAlert(alert_id, ra, decl, CA, decision, locus_id, IM=None, IR=None, IS=None)

Bases: antares.model.alert.Alert

Represents a camera alert which is a sub-class of Alert. A camera alert is associated with CA, IM, IR, IS and LA context objects. and is initialized with these 5 available contexts.

Param:antares.context.CAContext CA: CA context object
Param:antares.context.IMContext IM: IM context object
Param:antares.context.IRContext IR: IR context object
Param:antares.context.ISContext IS: IS context object
Param:antares.context.LAContext LA: LA context object

Attributes Summary

CA CA (Camera Alert) context object.
LA LA (Locus-aggregated Alert) context object.
IM IM (Image) context object.
IR IR (Image RAFT) context object.
IS IS (Image Section) context object.
replicas A list of the alert replicas created by camera alert.
annotation Annotation of the camera alert.

Methods Summary

createReplica([astro_id]) Create an alert replica which is associated with an optional astro object id astro_id.
createCombo(replicas) Create an alert combo object which contains a set of alert replicas.
throttle(annotation) Throttle the alert.
divert(annotation) Divert the alert.
mark_as_rare(annotation) Mark the alert as a rare alert.
hasReplicas() Check whether alert has replicas.
associatedAstroObjs()
loadReplicas() Load replicas from database.
commit() Commit the alert data to Locus-aggregated Alerts DB.
__str__()

Attributes Documentation

CA = None

CA (Camera Alert) context object. CA properties are always available.

Type:antares.context.CAContext
LA = None

LA (Locus-aggregated Alert) context object. LA properties are always available.

Type:antares.context.LAContext
IM = None

IM (Image) context object.

Type:antares.context.IMContext
IR = None

IR (Image RAFT) context object.

Type:antares.context.IRContext
IS = None

IS (Image Section) context object.

Type:antares.context.ISContext
replicas = None

A list of the alert replicas created by camera alert.

Type:list
annotation

Annotation of the camera alert.

Type:string

Methods Documentation

createReplica(astro_id=None)

Create an alert replica which is associated with an optional astro object id astro_id.

Param:int astro_id: ID of the astro object to be associated with the created replica. It is optional.
createCombo(replicas)

Create an alert combo object which contains a set of alert replicas.

Parameters:replicas (list) – a list of alert replicas
throttle(annotation)

Throttle the alert.

Parameters:annotation (string) – a short description of why the alert is throttled.
divert(annotation)

Divert the alert.

Parameters:annotation (string) – a short description of why the alert is diverted.
mark_as_rare(annotation)

Mark the alert as a rare alert.

Parameters:annotation (string) – a short description of why the alert is rare.
hasReplicas()

Check whether alert has replicas.

Returns:True if alert has replicas, otherwise False.
associatedAstroObjs()
loadReplicas()

Load replicas from database.

commit()

Commit the alert data to Locus-aggregated Alerts DB.

__str__()