Metadata-Version: 2.4
Name: lfpack
Version: 0.1.0
Summary: LFP codec — lossy compression of local-field-potential recordings via adaptive SVD and wavelet-packet thresholding
Project-URL: Homepage, https://github.com/int-brain-lab/lfpack
Project-URL: Bug Tracker, https://github.com/int-brain-lab/lfpack/issues
Author: The International Brain Laboratory
License: MIT
Requires-Python: >=3.10
Requires-Dist: h5py>=3.0
Requires-Dist: ibl-neuropixel
Requires-Dist: numpy
Requires-Dist: pywavelets
Requires-Dist: scipy
Provides-Extra: dev
Requires-Dist: pytest; extra == 'dev'
Requires-Dist: pytest-cov; extra == 'dev'
Description-Content-Type: text/markdown

# lfpack — LFP codec for Neuropixels recordings

<p align="center">
  <img src="docs/figures/logo.png" alt="lfpack logo" width="300"/>
</p>

Lossy codec for local-field-potential (LFP) recordings from Neuropixels probes.
Achieves **>100× compression** with median RMSE < 25 µV via an 8-stage pipeline
(bad-channel detection → dephasing → highpass → interpolation → CAR → decimation → Cadzow → adaptive SVD + wavelet-packet thresholding).

```bash
pip install lfpack
```

## Documentation

Full documentation is at **https://int-brain-lab.github.io/lfpack/**.

| Section | Contents |
| --- | --- |
| [Tutorial](https://int-brain-lab.github.io/lfpack/tutorials/first-compression.html) | End-to-end compression and decompression of a recording |
| [How-To: binned reads](https://int-brain-lab.github.io/lfpack/how-to/binned-reads.html) | Memory-efficient channel-binned access |
| [How-To: multi-recording files](https://int-brain-lab.github.io/lfpack/how-to/multi-recording.html) | Combining multiple recordings in one HDF5 file |
| [API reference](https://int-brain-lab.github.io/lfpack/reference/) | Full public API (`compress_bin_to_h5`, `LFPackReader`, …) |
| [HDF5 format](https://int-brain-lab.github.io/lfpack/reference/hdf5-layout.html) | On-disk layout specification |
| [Pipeline explanation](https://int-brain-lab.github.io/lfpack/explanation/pipeline.html) | Stage-by-stage description of the compression pipeline |
| [SVD+WP benchmark](https://int-brain-lab.github.io/lfpack/explanation/benchmark.html) | RMSE, SNR, and compression-ratio results across 11 insertions |