deepextractor.data.omicron¶
Omicron glitch-trigger utilities.
!! DISCLAIMER !! fetch_omicron_triggers() relies on gwtrigfind locating Omicron output files on the local filesystem. These files are only present on the computing clusters co-located with each LIGO detector site:
L1 (Livingston) → LLO cluster (ldas-pcdev*.ligo-la.caltech.edu) H1 (Hanford) → LHO cluster (ldas-pcdev*.ligo-wa.caltech.edu)
Do NOT run trigger-fetching code on CIT, LDAS, or any off-site cluster — it will fail to locate trigger files and raise RuntimeError.
Module Contents¶
- deepextractor.data.omicron.find_clean_gaps(peak_times: numpy.ndarray, durations: numpy.ndarray, run_start: int | float, run_end: int | float, trigger_buffer: float = 0.5) list[tuple[float, float]][source]¶
Return trigger-free time intervals within a GPS span.
Builds excluded windows from each trigger’s peak time and duration, merges overlapping exclusions, then returns their complement within
[run_start, run_end).- Parameters:
peak_times – Omicron trigger peak times (GPS seconds).
durations – Trigger durations (seconds), matched 1-to-1 with peak_times.
run_start – GPS start of the observing run (inclusive).
run_end – GPS end of the observing run (exclusive).
trigger_buffer – Extra padding (seconds) on each side of every trigger beyond the raw duration. Accounts for ring-down and edge effects.
- Returns:
List of
(gap_start, gap_end)tuples (GPS seconds), sorted by start time, all within[run_start, run_end).
- deepextractor.data.omicron.fetch_omicron_triggers(ifo: str, gps_start: int, gps_end: int, channel: str | None = None) dict[str, numpy.ndarray][source]¶
Return Omicron trigger parameters for a GPS interval.
- Parameters:
ifo – Detector prefix —
"L1"or"H1".gps_start – GPS start time (inclusive).
gps_end – GPS end time (exclusive).
channel – Full channel name, e.g.
"L1:GDS-CALIB_STRAIN". Defaults to the standard strain channel for ifo.
- Returns:
peak_time: GPS time of peak SNRtstart: GPS start of the Omicron Q-tiletend: GPS end of the Omicron Q-tileduration: tend - tstart (tile width in seconds)
- Return type:
Dict with 1-D float64 arrays per trigger
- Raises:
ValueError – If ifo is unrecognised and channel is not given.
RuntimeError – If no trigger files are found. Usually means the script is not running on the correct site cluster.
- deepextractor.data.omicron.save_omicron_triggers(triggers: dict[str, numpy.ndarray], prefix: str, output_dir: str | pathlib.Path = '.') None[source]¶
Save trigger arrays to
<output_dir>/<prefix>_triggers.npz.- Parameters:
triggers – Dict returned by fetch_omicron_triggers (peak_time, tstart, tend, duration).
prefix – Filename stem, e.g.
"l1_o3a".output_dir – Destination directory (created if absent).