LSCsoft-glue

raw JSON →
4.1.1 verified Fri May 01 auth: no python

GLUE (Grid LSC User Environment) is a collection of utilities for running data analysis pipelines for online and offline analysis as well as accessing various grid utilities. Current version is 4.1.1, actively maintained, with releases roughly every few months.

pip install lscsoft-glue
error ModuleNotFoundError: No module named 'glue.lal'
cause Trying to import from glue.lal without installing the lscsoft-glue package.
fix
pip install lscsoft-glue
error AttributeError: module 'glue' has no attribute 'Cache'
cause Using old top-level import pattern (from glue import Cache) which no longer works after restructuring.
fix
Use 'from glue.lal import Cache'
error ValueError: Cannot parse segment string: 'H1:1126257418-1126259500'
cause Calling to_segwizard() without proper columns, or mix-up between old and new segment string format.
fix
Ensure each cache entry has 4 columns: observatory, description, start_time, end_time, filename. LIGO channel/duration format is not supported.
breaking In version 2.0+, the top-level 'glue' package was restructured into subpackages like glue.lal, glue.segments, etc. Importing from the old flat namespace will fail.
fix Use 'from glue.lal import ...' instead of 'from glue import ...'
deprecated The 'glue.segmentdb' module is deprecated and may be removed in future versions. Use 'ligo.segments' directly for segment database queries.
fix Replace 'from glue.segmentdb import *' with 'from ligo.segments import *'
gotcha The 'Cache' class's 'to_segwizard' method expects Unix-formatted file paths even on Windows. Backslashes will cause parsing errors.
fix Use forward slashes or os.path.normpath() to convert paths.

Create a LIGO cache file using GLUE's Cache class.

from glue.lal import Cache
cache = Cache()
cache.append('H1', 'R', 1126257418, 1126259500, '/path/to/file.gwf')
cache.to_segwizard('/tmp/cache.txt')