Skip to content

Latest commit

 

History

History
executable file
·
32 lines (22 loc) · 774 Bytes

alert.md

File metadata and controls

executable file
·
32 lines (22 loc) · 774 Bytes

alert.py documentation


ztfquery.alert.py is module to visualise alerts generated by ZTF.

Requirements

  • None

There is a simple library inside ztfquery to load, access and display ZTF alerts.

Reading Avro Alert

Assuming you have a .avro alert stored in you computer at full_path_to_avro then:

from ztfquery import alert
ztfalert = alert.AlertReader.load(full_path_to_avro)

Inthere, the alert itself is stored as ztfalert.alert.
Now, if you want to display the alert for instance, simply use the show() method.

You can also quickly display the alert by using the display_alert:

from ztfquery import alert
fig = alert.display_alert(full_path_to_avro, show_ps_stamp=True)