query_names

dqsegdb2.query_names(ifo, host=None, raw=False, **request_kwargs)

Query for all defined flags for the given ifo

Parameters:
  • ifo (str) – The interferometer prefix for which to query.

  • host (str, optional) – The URL of the DQSegDB server; if None get_default_host() will be used to discover the default host.

  • raw (bool, optional) – Return the full JSON response from the request.

  • request_kwargs – Other keyword arguments are passed to igwn_auth_utils.get().

Returns:

  • set – If raw=False the set of all define flag names in the format {ifo}:{name}.

  • dict – If raw=True: the full JSON response is returned.

Examples

>>> from dqsegdb2.query import query_names
>>> query_names('X1')
{'G1:GEO-FLAG_1', 'G1:GEO-FLAG_2'}
>>> query_names('X1', raw=True)
{'results': ['GEO-FLAG_1', 'GEO-FLAG_2'], 'query_information': ...}