NeuralEnsemble / elephant

Elephant is the Electrophysiology Analysis Toolkit
http://www.python-elephant.org
BSD 3-Clause "New" or "Revised" License
202 stars 92 forks source link

[Fix] #613 spike_train_generation module to handle multichannel AnalogSignal inputs #614

Closed Moritz-Alexander-Kern closed 4 months ago

Moritz-Alexander-Kern commented 10 months ago

This PR closes #613.

This PR changes the handling of neo.AnalogSignals in elephant.spike_train_generation module.

  1. Type Annotations: Improved code readability with type annotations.

  2. Multichannel Support: handling of analog signals with multiple channels in spike_extraction, threshold_detection, and peak_detection.

  3. New Parameter: always_as_list: Ensures a consistent list output of SpikeTrains, even with single-channel input.

  4. Unit Tests: testing for various input types and values to validate reliability, and multichannel AnalogSignals

  5. Input Checks: Enhanced to catch errors related to incorrect input types.

todo:

coveralls commented 10 months ago

Coverage Status

coverage: 88.347% (+0.1%) from 88.222% when pulling 147ac1b0a602f13e92cd53450160e8ce6b55785b on INM-6:fix/#613_spike_train_generation_peak_detection into bdd98eefe99706621f5c840ce28134dac0e794af on NeuralEnsemble:master.