ligo-ex ligo-ds
  Richardson Lab Data Science Log  Not logged in ELOG logo
Message ID: 11     Entry time: Sun Jun 2 15:53:47 2024
Author: Rutuja Gurav 
Type: Infrastructure 
Category: Scripts/Programs 
Subject: Unable to access Segments DB on Chimay? 

Cannot access SegDB on Chimay. See error below.


from gwpy.segments import DataQualityFlag
from gwpy.time import to_gps, from_gps
ifo, run = 'L1', 'O4'

if run == 'O3':
O3a_start, O3a_end = '2019-04-01T08:00:00', '2019-10-01T08:00:00'
O3b_start, O3b_end = '2019-11-01T08:00:00', '2020-03-27T10:00:00'
start_gps, end_gps = to_gps(O3a_start), to_gps(O3b_end)
if run == 'O4':
O4_start, O4_end = '2023-05-24T15:00:00', '2024-01-16T16:00:00'
start_gps, end_gps = to_gps(O4_start), to_gps(O4_end)

print(start_gps, end_gps)
segs = DataQualityFlag.query(ifo+':DMT-ANALYSIS_READY:1',start_gps, end_gps, url="https://segments.ligo.org")


HTTPError: 401 Client Error: Unauthorized for url: https://segments.ligo.org/dq/L1/DMT-ANALYSIS_READY/1?e=1389456018&include=metadata,known,active&s=1368975618

ELOG V3.1.3-7933898