Skip to main content

Maintain a database of IGWN Data Quality Reports

Project description

dqrdb

PyPI version License: GPL v3 Docs

dqrdb maintains a MariaDB/MySQL database that tracks every Data Quality Report (DQR) produced by the IGWN DQR pipeline — which events have been processed, where the report files live, and what site and revision produced them.

Overview

When the DQR task manager completes a report, dqrdb records it:

GraceDB alert → dqralert → DQR task manager → dqr-process-upload → dqrdb

The database can also be populated in bulk from an existing directory tree using dqr-scandir.

Installation

pip install dqrdb

Quick Start

1. Configure the database connection

Create a dqrdb.ini file:

[DATABASE]
host     = localhost
user     = dqr-dev
password = <your-password>
database = dqr

2. Populate the database from an existing directory tree

dqr-scandir -v \
    --base-url https://ldas-jobs.ligo.caltech.edu/~dqr \
    --project online \
    /home/dqr/public_html/o4dqr/online/events/

3. Query the database from Python

from dqrdb.utils import get_events

results = get_events('S230529ad', project='online')
for r in results:
    print(r['site'], r['version'], r['url'])

4. Add a result programmatically

from pathlib import Path
from dqrdb.utils import add_result

added = add_result(
    path=Path('/home/dqr/public_html/o4dqr/online/events/202305/S230529ad_LHO_01'),
    url='https://ldas-jobs.ligo.caltech.edu/~dqr/online/events/202305/S230529ad_LHO_01/',
    gid='S230529ad',
    project='online',
    site='LHO',
    rev=1,
)
print('New record inserted:', added)

Command-Line Reference

Command Description
dqr-scandir Walk a directory tree and record all DQR results
dqr-process-upload Accept a remote DQR upload and register it in the database

Documentation

Full documentation — including configuration reference, CLI options, and API docs — is available at:

https://dqr-builder.docs.ligo.org/dqrdb/

License

dqrdb is distributed under the GNU General Public License v3 or later.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

dqrdb-0.2.0.tar.gz (33.4 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

dqrdb-0.2.0-py3-none-any.whl (39.9 kB view details)

Uploaded Python 3

File details

Details for the file dqrdb-0.2.0.tar.gz.

File metadata

  • Download URL: dqrdb-0.2.0.tar.gz
  • Upload date:
  • Size: 33.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.11.8

File hashes

Hashes for dqrdb-0.2.0.tar.gz
Algorithm Hash digest
SHA256 6306359d22b8a46b4e2d8f8ea3a80836fe60f78ac58783c28c888bdce0fb7ec8
MD5 c004d950fc652610c45b5a60cdd778f0
BLAKE2b-256 d6c380d5be90b31a3ca98dd90b475c388f8ad1aa3c3d51c85122d9b3bbe08296

See more details on using hashes here.

File details

Details for the file dqrdb-0.2.0-py3-none-any.whl.

File metadata

  • Download URL: dqrdb-0.2.0-py3-none-any.whl
  • Upload date:
  • Size: 39.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.11.8

File hashes

Hashes for dqrdb-0.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 c889229d8221165897ea509c47634b365845eadbf039605be904755ed4fe1df5
MD5 a5b4f017ff2bd2c5cfb81ff325d2ea2a
BLAKE2b-256 4c64ab7d69df017f5aab76675a1aa07d8ca5b92fa9a71da7f4ffebaeaaf19ae8

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page