Signal-aware data analysis and preprocessing framework
Project description
PBstats
PBstats is a high-performance, signal-aware data analysis and preprocessing framework built for engineers, researchers, and data scientists. It provides a fluent, chainable interface for cleaning, transforming, and visualizing complex signal data (ECG, EMG, EEG, Vibration, etc.).
Key Features
- Fluent API: Chain operations like
.remove_dc().standardize().fft().plot(). - Signal-Aware Metrics: Built-in support for RMS, SNR, Peak Frequency, and Energy.
- Advanced Transforms: FFT, STFT, Hilbert Transform (Envelope/Phase), and Wavelet Transform (CWT).
- Professional Visualization: Publication-ready plots and a comprehensive
dashboard()view. - Reproducible Pipelines: Define, save, and reload processing workflows as JSON.
- Batch Processing: Efficiently process entire datasets with timing reports and error handling.
Installation
# Clone the repository
git clone https://github.com/yourusername/PBstats.git
cd PBstats
# Install dependencies
pip install .
Quick Start
from PBstats import Data, Pipeline
import numpy as np
# Create some dummy signal data
fs = 1000
t = np.linspace(0, 1, fs)
signal = np.sin(2 * np.pi * 50 * t) + 0.5 * np.random.randn(fs)
# Process and visualize in one go!
d = (Data(signal, fs=fs, label="Test Signal")
.remove_dc()
.standardize()
.fft()
.plot_spectrum())
Recent Updates
I have recently updated the core framework with the following improvements:
- Vectorized Imputation Engine: Optimized the
ffillandbfillmethods in the preprocessing module. By replacing pure-Python loops with vectorized NumPy accumulation logic, the framework can now process massive signals (millions of samples) up to 100x faster. - Expanded Dependency Graph: Added
statsmodelsto the core dependencies. This ensures that advanced statistical tests, such as Augmented Dickey-Fuller (ADF) and KPSS for stationarity, work out-of-the-box. - Enhanced Reliability: Refined the
NormalizationMixinandOutlierMixinto handle edge cases like zero-variance signals and constant data without crashing.
Project Structure
PBstats/core/: CentralDataandPipelinelogic.PBstats/preprocessing/: Signal cleaning, scaling, and outlier handling.PBstats/transforms/: Frequency and time-frequency domain analysis.PBstats/statistics/: Hypothesis testing and descriptive metrics.PBstats/visualization/: High-quality plotting engine.
Developed with passion for the Signal Processing community.
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 pbstats-0.1.0.tar.gz.
File metadata
- Download URL: pbstats-0.1.0.tar.gz
- Upload date:
- Size: 26.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.11.4
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
08c52cd402974526c953307b46ec4de68e7a7dbf52c475fb904e22a69d80297e
|
|
| MD5 |
4df014958d574d55eb6c2e036647948e
|
|
| BLAKE2b-256 |
6beaab8782b93929f563d23f6b0d909df663637f9d20e335c0c064bf5ae48dbb
|
File details
Details for the file pbstats-0.1.0-py3-none-any.whl.
File metadata
- Download URL: pbstats-0.1.0-py3-none-any.whl
- Upload date:
- Size: 36.1 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.11.4
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
99f6112099cd657ed974138a9cff96d758f1ac9a27dc490e079abb13378cf60b
|
|
| MD5 |
825f651837ad272b290b0a6613cb040f
|
|
| BLAKE2b-256 |
2032dd6059764ed2d8974d0c610e5e984ea7c955b26deb131f00676a684d9a07
|