Creating reduced datasets with GWpy#
The command-line tool gwpy-rds provides a convenient way to create reduced
data sets using GWpy.
gwpy-rds accesses data for the requested channels for a single time
interval, and writes these data to a single new file.
This can be then fed to batch workflows, or other applications, to
speed up data access without needing to transfer the original full dataset.
Usage#
Create a reduced data set (RDS) using GWpy.
This tool allows you to create a reduced data set (RDS) by specifying a start and end time, a list of channels, and an output file. The tool will fetch the data for the specified channels and time range, and write it to the output file in the specified format.
Usage: gwpy-rds [-h] [-g SOURCE] [-o OUTPUT_FILE] [-f FORMAT] [-O key=value]
[-L LOG_NAME] [-v] [-V]
start end channel|ifo [channel|ifo ...]
Positional arguments#
- start
Start time of data request. Can be specified as a GPS time, date/time string, or relative time; please ensure that date strings containing spaces are quoted.
- end
End time of data request. Can be specified as a GPS time, date/time string, or relative time; please ensure that date strings containing spaces are quoted.
- channel|ifo
Data channel or IFO to request; can be specified multiple times. An IFO prefix (e.g., ‘H1’) can be passed to request public strain data from GWOSC.
Options#
- -g, --source
Source from which to get data. See help(TimeSeries.get) for documentation on the supported sources.
- -o, --output-file
Output file in which to write data.
Default:
gwpy-rds.h5- -f, --format
Format in which to write output data. Default is inferred from -o/–output-file. See below or help(TimeSeriesDict.write) for supported formats.
- -O, --option
Additional options to pass to the TimeSeriesDict.get.
- -L, --log-name
Name of the logger to configure for verbose output; use ‘root’ to enable logging in all modules.
Default:
'gwpy'- -v, --verbose
Increase verbosity; pass once for INFO, twice for DEBUG.
Default:
0- -V, --version
Show the version number and exit.
Examples:
Get data for GW150914:
$ gwpy-rds 1126259462 1126259522 H1:GWOSC-4KHZ_R1_STRAIN L1:GWOSC-4KHZ_R1_STRAIN -o gw150914.gwf -O version=4
Supported -f/–format values:
gwf
gwf.framecpp
gwf.framel
gwf.lalframe
hdf5
For more information, see the online documentation at: