Catalog of Observed Gravitational-wave Mergers

Information about the growing catalog of gravitational-wave mergers can be accessed through the pycbc.catalog package.

Which mergers do we have information about?

import pycbc.catalog

c = pycbc.catalog.Catalog()

# Names of mergers in the catalog
print c.names

# Approximate GPS time of the mergers
print [c[m].time for m in c]
$ python ../examples/catalog/what.py
/home/travis/build/pycbc-build/environment/lib/python2.7/site-packages/h5py/__init__.py:36: FutureWarning: Conversion of the second argument of issubdtype from `float` to `np.floating` is deprecated. In future, it will be treated as `np.float64 == np.dtype(float).type`.
  from ._conv import register_converters as _register_converters
['LVT151012', 'GW170608', 'GW150914', 'GW170814', 'GW170817', 'GW170104', 'GW151226']
[1128678900.44, 1180922494.49, 1126259462.4, 1186741861.53, 1187008882.43, 1167559936.6, 1135136350.65]

Plotting some key statistics from the catalog

import pycbc.catalog, pylab

c = pycbc.catalog.Catalog()
mchirp, elow, ehigh = c.median1d('mchirp', return_errors=True)
spin = c.median1d('chi_eff')

pylab.errorbar(mchirp, spin, xerr=[-elow, ehigh], fmt='o', markersize=7)
pylab.xlabel('Chirp Mass')
pylab.xscale('log')
pylab.ylabel('Effective Spin')
pylab.show()

(Source code, png, hires.png, pdf)

_images/stat.png

Accessing data around each event

Data around each event can also be easily accessed for any detector.

import pycbc.catalog, pylab

m = pycbc.catalog.Merger("GW170817")

# Retreive data from the Livingston observatory around the BNS merger
ts = m.strain("L1").time_slice(m.time - 30, m.time + 6)

# Whiten the data with a 4s filter
white = ts.whiten(4, 4)

times, freqs, power = white.qtransform(.01, logfsteps=200,
                                    qrange=(110, 110),
                                    frange=(20, 512))
pylab.pcolormesh(times, freqs, power**0.5)
pylab.yscale('log')
pylab.ylabel("Frequency (Hz)")
pylab.xlabel("Time (s)")
pylab.show()

(Source code, png, hires.png, pdf)

_images/data.png