sigmf.sigmffile.fromfile

sigmf.sigmffile.fromfile(filename, skip_checksum=False, autoscale=True)

Read a file as a SigMFFile or SigMFCollection.

The file can be one of: * a SigMF Archive (.sigmf) * a SigMF Metadata file (.sigmf-meta) * a SigMF Dataset file (.sigmf-data) * a SigMF Collection file (.sigmf-collection) * a non-SigMF RF recording that can be converted (.wav, .cdif, .xml, etc.)

Parameters:
  • filename (str | bytes | PathLike) – Path for SigMF Metadata, Dataset, Archive or Collection (with or without extension).

  • skip_checksum (bool, default False) – When True will not read entire dataset to calculate hash.

  • autoscale (bool, default True) – If dataset is in a fixed-point representation, scale samples from (min, max) to (-1.0, 1.0).

Returns:

A SigMFFile or a SigMFCollection depending on file type.

Return type:

SigMFFile | SigMFCollection

Raises: