lina-usc / pylossless

🧠 EEG Processing pipeline that annotates continuous data
https://pylossless.readthedocs.io/en/latest/
MIT License
18 stars 8 forks source link

Add optional step to flag channels/epochs based of fixed microvolt threshold #91

Closed scott-huberty closed 1 year ago

scott-huberty commented 1 year ago

Section 2.4.1.3 of the lossless paper describes a step to flag channels/epochs based off a 50 microvolt fixed threshold. something like:

  1. input: channel x epoch x times array
  2. take std across the times axis (return a channel x epochs array)
  3. if std value of a cell is > 50, it is "above threshold". flag chs & epochs:
  4. For each channel, if the std val of > 20% of epochs are "above threshold" . Flag channel..
  5. For each Epoch - if the std val for > 20% of channels are "above threshold", flag epoch.

The paper called this "staging" but given that 1) We are not convinced we should rei-implement allowing a staging script 2) The very Paper itself uses this step and says this step may be a common procedure users want to do... and 3) We need to do it just to validate pylossless against MATLAB losless... I propose we include this as an optional step of the pipeline.

EDIT: I am going take a stab at this today.

christian-oreilly commented 1 year ago

I propose we include this as an optional step of the pipeline.

I don't mind, but we may want to think about formalizing the framework for "optional steps".