CommKit
High-performance digital communications research kit for Python.
CommKit is a Python library for digital communications research that treats hardware as a first-class concern. A single Signal object carries IQ samples, physical metadata, and modulation context - with DSP operations dispatching automatically to NumPy, CuPy, or JAX based on data location.
Why CommKit?
- One object, complete context: Sampling rate, symbol rate, modulation format, and pulse shape travel with the signal through the processing pipeline.
- Backend-transparent DSP:
dispatch()resolves NumPy, CuPy, or SciPy modules at runtime. The same code executes seamlessly on CPU or GPU. - Method chaining: High-level fluent API (
sig.to("gpu").fir_filter(taps).resample(sps_out=2)...) for rapid prototyping. - JAX escape hatch: Zero-copy DLPack export on GPU allows direct application of JAX transforms (gradients,
vmap,scan) without leaving the research loop.
Modules & Features
| Module | Key Capabilities & Features |
|---|---|
commkit.core |
Signal container (IQ samples + metadata), SingleCarrierFrame, Preamble, and symbol/frame factories (PAM, PSK, QAM). |
commkit.backend |
Hardware abstraction layer (dispatch, to_device, to_jax, from_jax), placement management, and backend execution (NumPy, CuPy, JAX). |
commkit.mapping |
Gray-coded constellations, symbol mapping, hard demapping, soft LLR computation (max-log and exact log-sum-exp via JAX JIT), and GMI. |
commkit.filtering |
Pulse shaping (RRC, RC, Gaussian, Smooth-Rectangle), tap generators, matched filtering, Overlap-Save, and polyphase multirate filtering. |
commkit.multirate |
Fractional and integer sample rate conversion (resample, decimate, upsample, decimate_to_symbol_rate). |
commkit.timing |
Preamble generation (Barker, Zadoff-Chu), cross-correlation timing delay estimation, and frame alignment. |
commkit.frequency |
Carrier frequency offset estimation (FOE via M-th power, Mengali-Morelli, Jacobsen) and phase-locked FOE correction. |
commkit.recovery |
Carrier phase recovery (CPR via Viterbi-Viterbi, BPS, DD-PLL) and cycle-slip detection/correction. |
commkit.equalization |
Adaptive equalizers (lms, rls, cma, rde, zf), butterfly MIMO topology support, with Numba JIT and JAX execution backends. |
commkit.impairments |
Channel impairments simulation: AWGN (with SPS correction), PMD (differential group delay, Jones matrix), phase noise, IQ imbalance, and chromatic dispersion. |
commkit.coding |
Channel coding and FEC primitives (BCH, Convolutional, CRC, Galois field arithmetic, Hamming, Interleaving, LDPC, Polar, Rate matching, Reed-Solomon, Turbo codes). |
commkit.metrics |
System performance evaluation: EVM (%, dB), data-aided SNR, and BER estimation. |
commkit.analysis |
Laser phase and linewidth characterization: DSH, homodyne IQ, zero-phase drift detrending, AWGN-free lag-slope linewidth fit, Di Domenico $\beta$-separation line FWHM, and Allan deviation. |
commkit.spectral |
Welch PSD estimation and frequency shifting with bin-quantized mixing. |
commkit.io |
Signal persistence and disk serialization (load_npz, save_npz). |
commkit.plotting |
Visualization tools for constellations, eye diagrams, PSDs, time-domain signals, filter responses, and equalizer convergence. |
commkit.helpers |
General DSP helpers: random bit/symbol generators, array normalization, RMS calculation, and SI prefix formatting. |
Installation & Usage
Requires Python 3.12+ and uv.
Core Installation (CPU)
# Using uv (Recommended)
uv pip install git+https://github.com/lokgar/commkit.git
# Or with standard pip
pip install git+https://github.com/lokgar/commkit.git
GPU Support
To install with CUDA acceleration (includes JAX CUDA 13 and CuPy stacks):
# Using uv
uv pip install "commkit[gpu] @ git+https://github.com/lokgar/commkit.git"
# Or with standard pip
pip install "commkit[gpu] @ git+https://github.com/lokgar/commkit.git"
Development Installation
git clone https://github.com/lokgar/commkit.git
cd commkit
# Sync core environment
uv sync
# Sync environment with all extras (including GPU packages)
uv sync --all-extras
Examples & Notebooks
For complete usage scripts and DSP examples, explore the examples/ directory.
Running Tests
# CPU test suite
uv run pytest --device=cpu
# GPU test suite (requires CuPy + CUDA)
uv run pytest --device=gpu
# Run all test suites
uv run pytest --device=all
License
This project is licensed under the MIT License.
Metadata
Release files for commkit 1.0.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | |
|---|---|---|---|---|
| commkit-1.0.0.tar.gz | 629.1 kB | With provenance | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| commkit-1.0.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 988.0 kB
Release files / commkit-1.0.0.tar.gz
| Download URL | commkit-1.0.0.tar.gz |
|---|---|
| Size | 629.1 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
023c79cc3407ab712edc9ae3387b641454036787685aeee13facd39c1a61ae5d
|
|
BLAKE2b-256 checksum How to use checksums |
f4e1970ca27cd1c00f96651c3e8a56358b43807c862f8e373e33a42773c4a5a5
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Aug 31, 2026.
Transparency logRelease files / commkit-1.0.0-py3-none-any.whl
| Download URL | commkit-1.0.0-py3-none-any.whl |
|---|---|
| Size | 359.0 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
b3eb33ca6ebe7cba17e59063eab1273b7b1e475730248b5f90bc6ee5022e8013
|
|
BLAKE2b-256 checksum How to use checksums |
9b479c8feb8a8dcc8dc1dff33318c39216ec732ddb5b6a46b4d2cbdc1bd3b3cc
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Aug 31, 2026.
Transparency logSecurity for commkit 1.0.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
Full provenance
All 2 files in this release have been uploaded with provenance metadata.
Attestation for commkit-1.0.0.tar.gz
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Aug 31, 2026.
Transparency logA note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.