AlarmEvent
class optris_sdk.alarms.AlarmEvent
One transition, with the cause that produced it.
value and limit are in the unit of the signal the rule
watches, as its limits are (see the module docstring): the SDK's
temperature unit for a temperature, a difference in it for a rule
with a reference. In Fahrenheit value is NaN while the rule is
orphaned, and limit is NaN when has_limit is false.
AlarmEvent — properties
host_time
When this transition happened, as a datetime.
timestamp_us cannot answer that. It is the driving
observation's own stamp, so it is the frame clock counting
from the camera's start for a rule on a region or on the
camera, the poll time for a PIF rule, and wall clock for a
value the application published -- three different clocks in
one field, and only the last of them a date.
This one is always microseconds since the Unix epoch, read
from the system clock when the rule was evaluated, and it is
timezone-aware UTC. It can jump backwards when the machine's
clock is set or stepped by NTP, which timestamp_us never
does, so order by sequence and display this.
has_limit
Whether this transition actually crossed a limit.
False for a settle to clear on the first frame, where limit
is zero (NaN in Fahrenheit) and means nothing. Check this
before printing it, or every line of the log reads
"(limit 0.0)".