sarkit.crsd.Reader
- class Reader(file)
Read a CRSD file
A Reader object can be used as a context manager in a
withstatement. Attributes, but not methods, can be safely accessed outside of the context manager’s context.- Parameters:
- file
file object CRSD file to read
- file
- Attributes:
- metadata
Metadata CRSD metadata
- metadata
Methods
done()Indicates to the reader that the user is done with it
read_channel(channel_identifier, *[, ...])Read signal and pvp data from a CRSD file channel
read_ppps(sequence_identifier, *[, out])Read ppp data from a CRSD file
read_pvps(channel_identifier, *[, out])Read pvp data from a CRSD file
read_signal(channel_identifier[, out])Read signal data from a CRSD file
read_signal_compressed(*[, out])Read signal data from a CRSD file with signal arrays stored in compressed format
read_support_array(sa_identifier[, masked, out])Read SupportArray
See also
Examples
>>> import sarkit.crsd as skcrsd >>> with file.open("rb") as f, skcrsd.Reader(f) as r: ... sa_id = r.metadata.xmltree.findtext("{*}Data/{*}Support//{*}SAId") ... sa = r.read_support_array(sa_id) ... tx_id = r.metadata.xmltree.findtext("{*}Data/{*}Transmit//{*}TxId") ... txseq = r.read_ppps(tx_id) ... ch_id = r.metadata.xmltree.findtext("{*}Data/{*}Receive/{*}Channel/{*}ChId") ... sig, pvp = r.read_channel(ch_id)