Skip to content

Releases: sigmf/sigmf-python

v1.6.1 Bluefile Converter

20 Jan 16:59
615d544

Choose a tag to compare

Bluefile Converter

In this release we are excited to announce the addition of a converter for the MIDAS Blue and Platinum BLUE RF recording formats (commonly .cdif files). This allows you to seamlessly integrate BLUE file recordings into your SigMF workflows.

The converter automatically detects BLUE file formats and can create standard SigMF file pairs, archives, or Non-Conforming Datasets (NCDs) that reference the original recording. Original BLUE header information is preserved in the SigMF metadata under the blue: namespace.

Python API Example

You can use the converter directly within your Python scripts. If no output path is provided, a metadata-only SigMFFile object for a Non-Conforming Dataset (NCD) is returned without writing any files.

from sigmf.convert.blue import blue_to_sigmf

# Convert a BLUE file to a standard SigMF file pair
meta = blue_to_sigmf(blue_path="recording.cdif", out_path="recording")

# Create an NCD object in memory (no files written)
meta = blue_to_sigmf(blue_path="recording.cdif")

# Access samples and metadata
all_samples = meta.read_samples()
sample_rate = meta.sample_rate

# Original bluefile metadata preserved (in `fixed`, `adjunct`, and `extended` keys)
meta.get_global_field('blue:adjunct')
{'xstart': 0.025, 'xdelta': 5.5555555555555555e-08, 'xunits': 1}

Command-Line Example

The converter is also integrated into the unified sigmf_convert command-line tool, which automatically detects the input file format.

# Convert a .cdif file to a SigMF archive
sigmf_convert recording.cdif recording.sigmf --archive

# Create a non-conforming dataset (metadata only, references original data)
sigmf_convert recording.cdif recording --ncd

What's Changed

Thanks

Special thanks for the initial BLUE converter implementation and testing by @KelseyCreekSoftware.

Full Changelog: v1.5.1...v1.6.1

v1.5.1 Archive Upgrades

13 Jan 22:31
ac7669c

Choose a tag to compare

Sample access

Regardless of the source format (SigMF Pair / Archive / Non-Conforming Dataset) remember you can access samples by:

import sigmf
meta = sigmf.fromfile("example.sigmf")
# access by slicing
samples = meta[0:10]
# access by single file read
samples = meta.read_samples(count=10)
# access all samples from some capture index
samples = meta.read_samples_in_capture(2)
# by default all samples returned will be within [-1, +1] regardless of underlying format

What's Changed

  • fix capture byte boundaries for archives by @Teque5 in #124
  • bug: slicing for complex fixed-point data by @Teque5 in #126

Full Changelog: v1.4.0...v1.5.1

v1.4.0 Unified Sample Access

08 Jan 19:05
ef0d8ce

Choose a tag to compare

New ways to use SigMF

When accessing samples from sigmf files samples returning from a direct read and a slice always yield the same result:

import sigmf
meta = sigmf.fromfile('some_archive.sigmf')
# equivalent methods
meta[:] == meta.read_samples()
meta[0:1024] == meta.read_samples(count=1024)
meta[3:13] == meta.read_samples(start_index=3, count=10)

Integer datatypes are now always scaled such that the min/max is -1/1. If raw values are desired then set autoscale=False when doing fromfile():

meta = sigmf.fromfile('some_archive.sigmf', autoscale=False)
# still equivalent:
meta[0:10] == meta.read_samples(count=10)

What's Changed

Full Changelog: v1.3.0...v1.4.0

v1.3.0 Attributes

08 Jan 18:56
99065b7

Choose a tag to compare

New ways to use SigMF

When properties are part of sigmf global fields, they can now be read and written via attributes:

import sigmf
meta = sigmf.fromfile("some.sigmf-data")

sample_rate = meta.sample_rate # reads from metadata["global"]["core::sample_rate"]
num_channels = meta.num_channels # reads from metadata["global"]["core::num_channels"]
meta.author = "Bruce Wayne" # writes to metadata["global"]["core::author"]

What's Changed

New Contributors

Full Changelog: v1.2.12...v1.3.0

v1.2.12 Polish

20 Oct 15:58
4cdc35e

Choose a tag to compare

Module Polish

# you can now load a sigmf archive or file just by doing
import sigmf
sigmf.fromfile('some.sigmf')

Also, a warning will now be created if your metadata uses an undeclared extension. Remember extensions should be listed in core:extensions like:

"global": {
     ...
     "core:extensions" : [
         {
         "name": "extension-01",
         "version": "0.0.5",
         "optional": true
         },
         {
         "name": "extension-02",
         "version": "1.2.3",
         "optional": false
         }
     ]
     ...
 }

What's Changed

New Contributors

Full Changelog: v1.2.10...v1.2.12

v1.2.10

04 Jun 14:54
2ae107f

Choose a tag to compare

What's Changed

Full Changelog: v1.2.9...v1.2.10

v1.2.9 Path Hotfix

10 Apr 20:45
d4031c0

Choose a tag to compare

What's Changed

  • Take filenames with dots into account in get_sigmf_filenames() by @daniestevez in #107

New Contributors

Full Changelog: v1.2.8...v1.2.9

v1.2.8 Docs & Pathlib Everywhere

26 Mar 16:18
b9b6bed

Choose a tag to compare

Highlights

What's Changed

New Contributors

Full Changelog: v1.2.6...v1.2.8

v1.2.6 NCD & Collections

13 Jan 17:46

Choose a tag to compare

Highlights

  • Support for non-conforming datasets (where the data file is not a .sigmf-data)
  • Improvements for .sigmf-collection
  • Add equality checking for SigMFFile

What's Changed

  • remove unnecessary inline comprehension by @Teque5 in #75
  • override global info instead of replace on init by @Teque5 in #77
  • Fix path handling for non-conforming datasets by @GreenK173 in #81
  • Add specification version to the metadata in SigMFCollection by @GreenK173 in #83
  • datetime parsing for python 3.7 thru 3.12; fix deprecation warning by @Teque5 in #93
  • Add directory of the collection to SigMFCollection by @GreenK173 in #85
  • Fix coding style and PEP8 violations by @GreenK173 in #86
  • Add eq method to SigMFFile by @Teque5 in #98 (thanks to @jhazentia)

New Contributors

Full Changelog: v1.2.3...v1.2.6

v1.2.3 Validator

16 Sep 19:36

Choose a tag to compare

Release coincident with start of GNU Radio Conference 2024. Perhaps another patch coming later this week after the SigMF workshop.

What's Changed Since v1.2.1

What's new?

  • Better SigMF archive handling & bugfixes.
  • Improved multi-threaded sigmf_validate.

Other Improvements

  • Allow globstar (*) in sigmf_validate by @gregparkes in #59
  • always set metadata version to current implemented specification by @Teque5 in #67
  • add test for bad checksum by @Teque5 in #68
  • improve github action by @Teque5 in #73

Removed Bits

  • delete concept of default metadata and clarify validation err by @Teque5 in #69
  • remove sigmf_gui due to lack of support and PySimpleGUI changes by @Teque5 in #66

Full Changelog: v1.2.1...v1.2.3