Working with Segment Lists

LIGO data is not always available. In addition, there are times when data may be available, but of poor quality. For these reasons, most work with LIGO data begins with a "segment list", specifying the times of data to be analyzed.

Finding Segment Lists with Timeline

The Timeline application can be used to find and download segment lists. For example, a segment list of times where H1 data passed the Burst Group's category 2 data quality checks might look like this:


Burst CAT 2 segment list

Each line of the text file corresponds to 1 segment of data that passed the data quality checks. Shown are the GPS start time of the segment, the GPS end time, and the duration (in seconds) of the segment.

We can download both the data and the segment list for this period of time:

  1. Navigate to the S5 Timeline Query Form
  2. Enter a start time of 844605900 and a duration of 10000
  3. Choose the "Plot" option
  4. Choose H1_BURST_CAT2
  5. To download the segment list, click the link under "Download Segment List". Save it as "h1_burst_cat2.txt"
  6. To download the data, click the link that says "Get Strain Data"
Once you have the data and the segment lists, you can use the LOSC example API to read in the segment list and the good data.
import readligo as rl

segs = rl.SegmentList('h1_burst_cat2.txt')
for (begin, end) in segs:
    strain, meta, dq = rl.getstrain(begin, end, 'H1')
    #-- Your analysis code goes here

Constructing Segment Lists from Data Files

Segment lists can also be constructed directly from LOSC data files. For details, see documentation of the LOSC Example API or the Introduction to LIGO Data Files tutorial. If your prefer to write your own segment API, you may want to see this Matlab example script or read about the structure of LOSC data files.

Types of segments

LIGO data files contain a variety of segment types. For LOSC, the segments called DATA indicate when strain data is available. Then the segments CAT1, CAT2, CAT3 indicate problems with the data (CAT1 being worst). There are also segments of times when hardware injections are not occuring. For more information, see here for the S5 and S6>.