Skip to main content

The Python DSP Toolkit

Project description

SigKit

Version Tests Passing GitHub Contributors Issues Pull Requests

SigKit is a modular digital signal‐processing toolkit built on top of NumPy. It has additive impairments to simulate OTA impairments. We include a full Machine Learning toolkit with methods for PyTorch designed for training Modulation Classification Models that are capable of generalizing over the air (OTA). It provides:

  • Core abstractions (Signal, Impairment, Modem, …) for working in complex baseband
  • NumPy ipairments, PyTorch Transforms & tools (AWGN, fading, filtering, SNR & BER calculators)
  • PyTorch Transforms so you can drop signal operations straight into Compose
  • PyTorch Lightning Pipeline includes our pretrained model and methods for retraining
  • (WIP) GNURadio Blocks wrapping our tools
  • Synthetic data generators & torch.utils.data.Dataset classes

🚀 Getting Started

Try the example notebook

A quick way to explore SigKit is to run the Jupyter notebook in:

examples/notebooks/basic.ipynb

The notebook is a guide that covers:

  • Generating a signal with a Modem
  • Adding an Impairment like AWGN
  • Calculating Signal Metrics
  • Visualizing the waveform

Be sure to restart your notebook's kernel after installing the package.

Classification

There is also an example notebook for running the pretrained model.

examples/notebooks/classification.ipynb

Pull down LFS objects first with git lfs pull

Installing SigKit

Package Installation

Installing the pypi package
pip install sigkit
Installing from source (recommended for ML tasks)
git clone https://github.com/IsaiahHarvi/SigKit.git
cd SigKit
pip install -e .
Sanity Check for source installs

You can be gauranteeed your installation is sound by running pytest without failure from the root of the repository.

(Optional) DevContainer for VS Code

If you use VS Code and would prefer to isolate your SigKit installation, we’ve provided a DevContainer in the repository. It is designed to be OS agnostic but it is confirmed to support: Ubunutu >22.04, ARM MacOS, Windows

To setup:

  1. Install the Remote – Containers extension in VS Code.
  2. Clone, open the project, and run chmod +x .devcontainer/setup.sh.
  3. Run Reopen in Container from the VSCode console.

Inside the container you’ll have all dependencies installed and SigKit ready to run.


State of Implementations

The below table tracks major planned features. Smaller features like Signal Impairments and Torch Transforms are not tracked here.

Feature Implemented Torch Transform
Architecture - -
Rust bindings No -
GNURadio - -
ClassificationBlock No -
Modulator No -
Modems - -
PSK Yes -
FSK Yes -
QAM WIP -
OFDM WIP -
MSK No -
ASK No -
Machine Learning - -
Training Pipeline Yes -
Pretrained Model Yes (WIP) -
Procedural Dataset Yes -
File Dataset No -
Signal Impairments - -
AWGN Yes
Frequency Shift Yes
Phase Shift Yes
Polyphase Resampling No
Rayleigh Fading No
Random Resampling No
IQ Imbalance No
Time Shift No

🛠️ Development

  • Tests:

    pytest
    
  • Lint & Format:

    ruff check . --fix
    ruff format .
    
  • Update docs:

    # Install the optional dependencies [docs] or:
    pip install sphinx piccolo_theme tomli
    
    ./docs/gen.sh
    

License

This project is released under the MIT License. See LICENSE for details.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

sigkit-0.0.3.tar.gz (22.0 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

sigkit-0.0.3-py3-none-any.whl (26.2 kB view details)

Uploaded Python 3

File details

Details for the file sigkit-0.0.3.tar.gz.

File metadata

  • Download URL: sigkit-0.0.3.tar.gz
  • Upload date:
  • Size: 22.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for sigkit-0.0.3.tar.gz
Algorithm Hash digest
SHA256 df100f1685e82c0c28e285d5286afa82144ef3585cea9b3d7c240764bdf3265d
MD5 3cbf7f9907b069062546d33c8d05728c
BLAKE2b-256 745493ae74571548d4bafb73e90aba262ac5496dec096ca187ed4c15f3294e35

See more details on using hashes here.

Provenance

The following attestation bundles were made for sigkit-0.0.3.tar.gz:

Publisher: python-publish.yml on IsaiahHarvi/SigKit

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file sigkit-0.0.3-py3-none-any.whl.

File metadata

  • Download URL: sigkit-0.0.3-py3-none-any.whl
  • Upload date:
  • Size: 26.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for sigkit-0.0.3-py3-none-any.whl
Algorithm Hash digest
SHA256 dbc5cddcb2cac18518d8891c7dde05e69f45e78391bc42ca0b3c8c58b335bb08
MD5 3253b5537a795d307e5abbc5dc533cf9
BLAKE2b-256 8da6559318d2372f94e4450bc41d6c791002729379d9b4d39cf05161dd5da691

See more details on using hashes here.

Provenance

The following attestation bundles were made for sigkit-0.0.3-py3-none-any.whl:

Publisher: python-publish.yml on IsaiahHarvi/SigKit

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page