ligo.raven.offline_search¶
- ligo.raven.offline_search.num_above(array, minfar=1e-09, maxfar=0.001)[source]¶
- Calculates the cumulative number of events with the same or smaller
false alarm rate.
- Parameters:
array (array) – Array of values to bin
minfar (float) – Minimum bound of binning
maxfar (float) – Maximum bound of binning
- Returns:
bins_used (array) – Values of bins used
counts (counts) – Counts in each bin
- ligo.raven.offline_search.choose_gracedb(path)[source]¶
- Determine whether the input given is from an official GraceDB online
server or from a local file.
- Parameters:
path (str) – Either GraceDB API URL or path to local local
- Returns:
GraceDB – GraceDB class instance, either official online or mock offline
- Return type:
class
- ligo.raven.offline_search.get_skymap_filename(graceid, is_gw, gracedb)[source]¶
Get the skymap fits filename.
- Parameters:
graceid (str) – GraceDB ID
is_gw (bool) – If True, uses method for superevent or preferred event. Otherwise uses method for external event.
gracedb (class) – GraceDB client
- Returns:
filename – Filename of latest sky map
- Return type:
str
- ligo.raven.offline_search.offline_search(input_path_gw, input_path_ext, output_path='results', t_start=None, t_end=None, tl=-1, th=5, gw_far_thresh=0.0002777777777777778, ext_far_thresh=None, alert_far_thresh=1.9025875190258752e-07, trials_factor=1, use_radec=False, use_emrate=False, load_gw_fars=False, group=None, pipeline=None, ext_search=None, se_search=None)[source]¶
Perform offline RAVEN search, where the inputs can be any combination of two online GraceDB instances or local files.
- Parameters:
input_path_gw (str) – Input for GW data, either a GraceDB API url or path to local file
input_path_ext (str) – Input for external data, either a GraceDB API url or path to local file
output_path (str) – Output path of results directory to add data products to
t_start (float) – Start time of search
t_end (float) – End time of search
tl (float) – Start of coincident time window
th (float) – End of coincident time window
gw_far_thresh (float) – Maximum GW FAR cutoff to consider superevent in search
ext_far_thresh (float) – Maximum external FAR cutoff to consider event in search
alert_far_thresh (float) – Joint FAR cutoff to consider a coincidence for an alert
trials_factor (float) – Trials factor given by the number of independent GW pipelines
use_radec (bool) – If True and needed, will use the single pixel RA/dec method to calculate the sky map overlap integral
use_emrate (bool) – If True, will use the calculated rate of external triggers, given from, the time and number of triggers in the time period when calculating the joint FAR
load_gw_fars (bool) – If True, loads all of the GW candidates in the given time period to plot their FARS
group (str) – “CBC”, “Burst”, or “Test”,
pipeline (str) – External trigger pipeline name
ext_search (str) – External trigger search
se_search (str) – List of superevent search
- Returns:
output_table – AstroPy Table of joint candidates found during the search
- Return type:
Table