find_channels#
- gwpy.io.nds2.find_channels(
- channels: Sequence[str | Channel | nds2.channel],
- connection: nds2.connection | None = None,
- host: str | None = None,
- port: int | None = None,
- sample_rate: float | tuple[float, float] | None = None,
- type: int | str | None = 127,
- dtype: int | str | DTypeLike = 127,
- *,
- unique: bool = False,
- epoch: str | tuple[int, int] | None = 'ALL',
Query an NDS2 server for channel information.
- Parameters:
- channels
listofstr List of channel names to query, each can include bash-style globs.
- connection
nds2.connection, optional Open NDS2 connection to use for query.
- host
str, optional Name of NDS2 server to query, required if
connectionis not given.- port
int, optional Port number on host to use for NDS2 connection.
- sample_rate
int,float,tuple, optional A single number, representing a specific sample rate to match, or a tuple representing a
(low, high)interval to match.- type
int, optional The NDS2 channel type to match.
- dtype
int, optional The NDS2 data type to match.
- unique
bool, optional, default:False Require one (and only one) match per channel.
- epoch
str,tupleofint, optional The NDS epoch to restrict to, either the name of a known epoch, or a 2-tuple of GPS
[start, stop)times.
- channels
- Returns:
- channels
listofnds2.channel List of NDS2 channel objects.
- channels
See also
nds2.connection.find_channelsFor documentation on the underlying query method.
Examples
>>> from gwpy.io.nds2 import find_channels >>> find_channels(['G1:DER_DATA_H'], host='nds.ligo.caltech.edu') [<G1:DER_DATA_H (16384Hz, RDS, FLOAT64)>]