Registry / testing / pyprep

pyprep

JSON →
library0.6.0pypypi✓ verified 82d ago

PyPREP is a Python implementation of the PREP (Preprocessing Pipeline) for EEG data, designed to detect and interpolate noisy channels, perform robust referencing, and filter data. Current version 0.6.0, with monthly releases.

pip install pyprep
INSTALL
IMPORT
SIG · PYPREP
P
pyprep
testingpythonv0.6.0
harness data pending
Install & Compatibility
Where this runs

No compatibility data collected yet for this library.

Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

NoisyChannels
from pyprep import NoisyChannels
from pyprep.noisy_channels import NoisyChannels
PrepPipeline
from pyprep import PrepPipeline
Reference
from pyprep import Reference

Load a raw MNE object and apply the PREP pipeline for channel noise detection, robust referencing, and interpolation.

import mne from pyprep.prep import PREP # Load raw EEG data (example: sample data from mne) raw = mne.io.read_raw_fif('sample_raw.fif', preload=True) # Run PREP pipeline prep_params = { 'reref_ch': [], 'line_freqs': [60], } prep = PREP(raw, prep_params=prep_params) prep.fit() # Get corrected raw raw_corrected = prep.raw_eeg print('PREP completed successfully')
Debug
Known issues
gotchaPyPREP expects the raw data to have channel types of 'eeg'. If not, set them using raw.set_channel_types().
fix
raw.set_channel_types({ch: 'eeg' for ch in raw.ch_names})
affects: >=0.4.0
deprecatedImporting NoisyChannels from pyprep.findNoisyChannels is deprecated; use from pyprep.noisy_channels import NoisyChannels.
fix
Use 'from pyprep.noisy_channels import NoisyChannels'.
affects: >=0.5.0
gotchaPREP requires a reference channel list. If you pass an empty list for 'reref_ch', it uses robust referencing. If you omit it, the pipeline fails.
fix
Always include 'reref_ch' in prep_params, even if empty.
affects: all
Upgrade
Version history
0.6.0latest on PyPI · released Feb 26, 2026
Audit
Dependencies
numpyrequiredCore numerical operations
scipyrequiredSignal processing and statistics
mnerequiredEEG data handling and I/O
Agent activity
6 hits · last 30 days
node
6
Resources

No resource links recorded.

pyprep — pip install pyprep · libregistry