Skip to content
Snippets Groups Projects

Update to not reference HTTPConnection

Merged Duncan Macleod requested to merge duncanmmacleod/gwdatafind:update-readme into main
1 file
+ 16
10
Compare changes
  • Side-by-side
  • Inline
+ 16
10
# GWDataFind
The client library for the LIGO Data Replicator (LDR) service.
The GWDataFind data discovery client.
The DataFind service allows users to query for the location of
The GWDataFind service allows users to query for the location of
Gravitational-Wave Frame (GWF) files containing data from the current
gravitational-wave detectors.
@@ -32,17 +32,23 @@ To find the URLs of all `H1_R` files for the LIGO-Hanford observatory in
a given GPS interval:
```python
>>> from gwdatafind import connect
>>> conn = connect()
>>> conn.find_urls('H', 'H1_R', 1198800018, 1198800618)
>>> from gwdatafind import find_urls
>>> find_urls('H', 'H1_R', 1198800018, 1198800618)
```
This can be shortened for single interactions to
To utillise connection pooling, create a `Session`:
```python
>>> from gwdatafind import find_urls
>>> find_urls('H', 'H1_R', 1198800018, 1198800618)
```
>>> from gwdatafind import (find_urls, Session)
>>> with Session() as sess:
... for ifo in ("H", "L"):
... urls[ifo] = find_urls(
... ifo,
... f"{ifo}1_R",
... 1198800018,
... 1198800618,
... session=sess,
... )
## On the command-line
@@ -53,4 +59,4 @@ run
$ python -m gwdatafind --help
```
For more documentation, see gwdatafind.readthedocs.org.
For more documentation, see <https://gwdatafind.readthedocs.io/>.
Loading