Composable NumPy-based digital signal processing blocks and pipelines
Project description
npDSP
A small, composable digital signal processing library built on NumPy.
npDSP provides simple DSP blocks that can be combined into pipelines using Python's >> operator.
Installation
Install from PyPI:
pip install npDSP
Or with uv:
uv add npDSP
Quick start
import numpy as np
import npdsp
pipeline = npdsp.Add(1) >> npdsp.Multiply(2)
x = np.array([1, 2, 3])
y = pipeline(x)
print(y)
# [ 4 6 8]
Blocks can also be given names and accessed through a pipeline:
pipeline = npdsp.Add(1, name="offset") >> npdsp.Multiply(2, name="gain")
print(pipeline["gain"])
Features
- NumPy-based signal processing
- Composable processing blocks
- Pipeline construction with
>> - Stateful processing blocks such as
Delay - Mathematical operations
- Conversion and utility blocks
- Type hints
- Block profiling
- Sphinx API documentation
Documentation
Documentation is available on Read the Docs.
The documentation includes:
- Getting Started
- Concepts
- API Reference
- Block reference
- Core API reference
- Examples
Development
npDSP uses uv for development and dependency management.
Clone the repository:
git clone https://github.com/mrhiemstra/npDSP.git
cd npDSP
Install the development dependencies:
uv sync
Run the test suite:
uv run pytest
Build the documentation:
uv run sphinx-build -b html docs/source docs/build/html
Build the package:
uv build
Requirements
- Python 3.10+
- NumPy 2.2.6+
- si-prefix 1.3.3+
- typing-extensions 4.16.0+
License
npDSP is released under the MIT License.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file npdsp-0.0.2.tar.gz.
File metadata
- Download URL: npdsp-0.0.2.tar.gz
- Upload date:
- Size: 13.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/7.0.0 CPython/3.13.14
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
c12f0c6fce0ec08f44c27e2cbd31689f5a39918b6835f3ad510de2ef2e0bf3c7
|
|
| MD5 |
e5054e2cd4a2c1974cdedd5210ec37a8
|
|
| BLAKE2b-256 |
1130eb2631f28c836b32f0a51676f6eea739b247f8370b22905c40e067046714
|
Provenance
The following attestation bundles were made for npdsp-0.0.2.tar.gz:
Publisher:
publish.yml on mrhiemstra/npDSP
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
npdsp-0.0.2.tar.gz -
Subject digest:
c12f0c6fce0ec08f44c27e2cbd31689f5a39918b6835f3ad510de2ef2e0bf3c7 - Sigstore transparency entry: 2313533772
- Sigstore integration time:
-
Permalink:
mrhiemstra/npDSP@2ce6d263d19a140839424f95e0fbc0b39ded243b -
Branch / Tag:
refs/tags/v0.0.2 - Owner: https://github.com/mrhiemstra
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@2ce6d263d19a140839424f95e0fbc0b39ded243b -
Trigger Event:
push
-
Statement type:
File details
Details for the file npdsp-0.0.2-py3-none-any.whl.
File metadata
- Download URL: npdsp-0.0.2-py3-none-any.whl
- Upload date:
- Size: 19.2 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/7.0.0 CPython/3.13.14
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
7c729d9f66973fa6a25e5a125e05ce793e7cfd0252d5414ce0972aeec72ec1dc
|
|
| MD5 |
64b8f2e59d6ecb6eb51b4b1d1845cd3c
|
|
| BLAKE2b-256 |
a25fe29cd972be14f97edee91f7abacfef22978605c566626174e9c4c1b55e02
|
Provenance
The following attestation bundles were made for npdsp-0.0.2-py3-none-any.whl:
Publisher:
publish.yml on mrhiemstra/npDSP
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
npdsp-0.0.2-py3-none-any.whl -
Subject digest:
7c729d9f66973fa6a25e5a125e05ce793e7cfd0252d5414ce0972aeec72ec1dc - Sigstore transparency entry: 2313533792
- Sigstore integration time:
-
Permalink:
mrhiemstra/npDSP@2ce6d263d19a140839424f95e0fbc0b39ded243b -
Branch / Tag:
refs/tags/v0.0.2 - Owner: https://github.com/mrhiemstra
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@2ce6d263d19a140839424f95e0fbc0b39ded243b -
Trigger Event:
push
-
Statement type: