gwcelery.tasks.first2years_external module

Create mock external events to be in coincidence with MDC superevents.

gwcelery.tasks.first2years_external.IVORN_PIPELINE_DICT = {'Fermi': 'Fermi', 'SNEWS': 'SNEWS', 'SVOM': 'fsc', 'Swift': 'SWIFT'}

This dict maps from the pipeline name to the name listed in the IVORN.

gwcelery.tasks.first2years_external.create_upload_external_event(gpstime, pipeline, ext_search)[source]

Create a random external event VOEvent or Kafka alert packet.

Parameters:
  • gpstime (float) – Event’s GPS time

  • pipeline (str) – External trigger pipeline name

  • ext_search (str) – Search field for external event

Returns:

event – Alert packet in format as if it was sent from GCN or Kafka, in a XML GCN notice alert packet in string format for the GRB or SubGRB search or a dictionary Kafka packet if for SubGRBTargeted search.

Return type:

str or dict

(task)gwcelery.tasks.first2years_external.upload_external_event(alert, ext_search=None)[source]

Upload a random GRB event(s) for a certain fraction of MDC or O3-replay superevents.

Notes

Every n superevents, upload a GRB candidate within the standard CBC-GRB or Burst-GRB search window, where the frequency n is determined by the configuration variable joint_mdc_freq or joint_O3_replay_freq.

For both testing internal MDC events on all instances and for all superevents uploaded to gracedb-playground.

Parameters:
  • alert (dict) – IGWN alert packet

  • ext_search (str) – Search field for external event, meant primarily for testing purposes

Returns:

events, pipelines – Returns tuple of the list of external events created and the list of pipelines chosen for each event

Return type:

tuple

(task)gwcelery.tasks.first2years_external.upload_snews_event()[source]

Create and upload a SNEWS-like MDC external event.

Returns:

ext_event – XML GCN notice alert packet in string format

Return type:

str