Skip to main content

Deterministic ECG codec with Python + Rust core; staged proof on 4 standard clinical corpora (MIT-BIH, NSTDB, EDB, PTB-XL)

Project description

ZPE-Bio

Deterministic ECG codec repository with a Python CLI, a Rust core crate, and committed validation artifacts. This README is intentionally limited to claims that are backed by proof artifacts already on disk and by tests that run in CI. ZPE-Bio is one of 17 independent encoding products in the Zer0pa portfolio, each developed for its own domain.

This repo's claimed surface is ECG staged proof only. It does not use the wearable runbooks as release evidence, and it does not make a generalized biosignal or regulatory claim.

Anchored Proof Surface

Claim Proof Artifact On Disk CI Test Anchor
MIT-BIH benchmark writer emits summary + aggregate artifacts validation/results/BENCHMARK_SUMMARY.md, validation/results/mitdb_python_only/mitdb_aggregate.json tests/test_benchmark_mitdb.py
PTB-XL benchmark writer emits committed-style summary artifacts validation/results/ptbxl/summary.json tests/test_benchmark_physionet.py
Clinical ECG round-trip remains deterministic and high-fidelity in the Python codec validation/results/BENCHMARK_SUMMARY.md tests/test_codec.py, tests/test_deterministic_replay.py
Python and Rust codec implementations remain parity-gated in CI core/rust/, tests/test_parity.py tests/test_parity.py

Not Claimed

  • No public release-readiness verdict
  • No generalized biosignal victory claim
  • No Bio Wearable closure claim
  • No regulatory or FDA claim

Benchmark Results (committed artifacts, beta)

Results below are from committed benchmark artifacts. All runs are CPU-only Python codec; no hardware path is implied.

MIT-BIH Arrhythmia Database (48 records, full corpus)

Metric Value
Records processed 48/48
Integrity pass rate 48/48 (100%)
Mean compression ratio 1.323
Mean SNR 43.3 dB
Mean RMSE 3.24 uV
Mean PRD 1.12%
Max PRD 2.32%

Source: validation/results/BENCHMARK_SUMMARY.md, validation/results/mitdb_python_only/mitdb_aggregate.json | CI: tests/test_benchmark_mitdb.py

MIT-BIH Noise Stress Test Database (nstdb, 15 entries)

Metric Value
Records processed 15/15
Integrity pass rate 15/15 (100%)
Mean compression ratio 1.310
Mean SNR 60.5 dB
Max PRD 1.96%

Source: validation/results/nstdb/summary.json | CI: tests/test_benchmark_physionet.py

European ST-T Database (edb, 90 entries)

Metric Value
Records processed 90/90
Integrity pass rate 90/90 (100%)
Mean compression ratio 1.376
Mean SNR 52.5 dB
Max PRD 4.34%

Source: validation/results/edb/summary.json | CI: tests/test_benchmark_physionet.py

PTB-XL ECG Database (100 records sample)

Metric Value
Records processed 100/100
Integrity pass rate 100/100 (100%)
Mean compression ratio 1.576
Mean SNR 32.0 dB
Max PRD 5.29%

Source: validation/results/ptbxl/summary.json | CI: tests/test_benchmark_physionet.py

Note on PTB-XL SNR/PRD: PTB-XL records are 12-lead 500 Hz clinical studies; the lower SNR relative to MIT-BIH reflects higher signal diversity and more channels compressed per segment, not codec regression. Integrity passes 100/100.

Local Validation

python -m venv .venv
source .venv/bin/activate
python -m pip install --upgrade pip
python -m pip install -e ".[dev,validation]"
pytest -q
python -m build

Quick ECG smoke check:

python -m zpe_bio roundtrip --mode clinical --samples 250

Repository Map

  • python/zpe_bio/: Python package and CLI
  • core/rust/: Rust codec crate
  • embedded/: embedded reference firmware tree
  • tests/: repo-local pytest suite
  • scripts/: benchmark and operator scripts
  • validation/results/: committed benchmark outputs
  • validation/runbooks/: execution and boundary runbooks
  • docs/: repo documentation and regulatory/reference material

Read Next

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

zpe_bio-0.2.1.tar.gz (102.9 kB view details)

Uploaded Source

Built Distribution

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

zpe_bio-0.2.1-py3-none-any.whl (108.7 kB view details)

Uploaded Python 3

File details

Details for the file zpe_bio-0.2.1.tar.gz.

File metadata

  • Download URL: zpe_bio-0.2.1.tar.gz
  • Upload date:
  • Size: 102.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for zpe_bio-0.2.1.tar.gz
Algorithm Hash digest
SHA256 abc4f3203ee4a6649bd7be9014ad8798bfff631753c5d8dff87885dd3d24dbfd
MD5 3411cc076499bf53881eff95722e6fc7
BLAKE2b-256 e758a9e19d26b1f6070539c6e18331c8fbe77902f164cdca37a3bb836fd6bd2e

See more details on using hashes here.

File details

Details for the file zpe_bio-0.2.1-py3-none-any.whl.

File metadata

  • Download URL: zpe_bio-0.2.1-py3-none-any.whl
  • Upload date:
  • Size: 108.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for zpe_bio-0.2.1-py3-none-any.whl
Algorithm Hash digest
SHA256 569a52eae1a440dac6563938ba4244ab795e745dc3c0299f44a6f6efa3b39ad0
MD5 aeed9fd4217cb68254fe3b294012b980
BLAKE2b-256 38e99d0c10de99df4f6f20658309aade073bec9b3eb2153cbe4de048444f6452

See more details on using hashes here.

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