Comments (9)
I think actually eegfaster exist so maybe that would collide
ah, interesting: https://github.com/mdelpozobanos/eegfaster ... but it's not based on MNE (which is not necessarily a drawback)
In any case at least leave it at a gist which we could mention in the pyprep readme if anyone is looking for that.
I took the FASTER code from this gist: https://gist.github.com/wmvanvliet/d883c3fe1402c7ced6fc
I think I'd prefer to mention to remove all non-prep code from this repo and mention the FASTER gist somewhere in the README.
We have to work on more code than we can handle anyways, so removing unneeded things is a good start.
from pyprep.
Yes, if we could fix the mne multitaper that'd be great ... both for MNE and pyprep. I think it'd be nice to have a working Python implementation for that.
And yes, we need more tests (and better tests) ... and once we have them, we should start refactoring the code without breaking the tests.
re: what to focus on:
- removing noisy.py is a simple PR < 1hour
- adding tests can be done incrementally ... whenever somebody has time to take a look and has a good idea
- biggest chunk is fixing mne multitaper --> that'll have to be done in MNE-Python
Other things to do is compare RANSAC in pyprep with RANSAC in autoreject ... and perhaps "unify" them ... take the best of each combination and make one version out of them (probably "enhance" autoreject ransac ... and then make autoreject a dependency in pyprep to import RANSAC from there.)
--> this is also a big job.
So I see two big jobs and some smaller jobs.
Once all of this is done, we can start refactoring :-)
from pyprep.
Yeah, I agree. But noisy.py
does has some functionality that find_noisy_channels.py
does not include. find_bad_epochs
. So I think maybe we could:
- Put find_bad_epochs into a separate file
- Remove
noisy.py
- Add a notebook on using
find_noisy_channels.py
standalone
from pyprep.
I think that find_bad_epochs
is out of the scope for pyprep. IMHO, pyprep should do one thing and do it well --> being a python implementation of the matlab PREP pipeline.
WDYT @yjmantilla
from pyprep.
@sappelhoff I think in that case we should make available that functionality in another repo, for example pyfaster or something. I think actually eegfaster exist so maybe that would collide. In any case at least leave it at a gist which we could mention in the pyprep readme if anyone is looking for that.
from pyprep.
Another way would be to create a repo specifically for finding noisy stuff including find_noisy_channels and the noisy epochs functions. And then make prep use that module. That way pyprep is the prep implementation and only cares about that and pynoisy (or how that would be called) would only care about finding noisy eeg, being it continuous or epoched.
from pyprep.
Right now the biggest issues are:
- the mne multitaper filter, which I know there was a windowed version done which we could test.
- the test and validation of the pipeline, which I think are even more important than the filter unless we think of the filter as something absolutely essential of prep.
There was a suggestion too for the API change. So after we eliminate the noisy.py what should our focus be, on your opinion?
from pyprep.
@sappelhoff just to your last comment, something else that would be handy for end users (like me) would be a paragraph or two somewhere in the README or docs comparing autoreject to PyPREP and discussing how they relate. For example, is it valid for someone to clean their raw EEG using PyPREP and then try and remove any remaining bad epochs with autoreject, or should they only be used independently?
from pyprep.
For example, is it valid for someone to clean their raw EEG using PyPREP and then try and remove any remaining bad epochs with autoreject, or should they only be used independently?
PREP (and pyprep) will interpolate channels .. and autoreject will also interpolate on an epoch level (or drop really bad epochs without trying to interpolate) --> so I guess the danger could be to interpolate a channel based on data that's been already interpolated. And that's like using a copy machine to copy a copy instead of copying the original --> it's getting worse each iteration.
Personally, I would not use prep and autoreject together ... except maybe with heavy testing - but I haven't given it much thought.
Regarding a paragraph to guide users: Sure that'd be helpful, but we'd have to find somebody who wants to pour a lot of testing and knowledge into it :-) I personally don't know much more than what I said in the beginning of this post.
from pyprep.
Related Issues (20)
- Use the MNE logger to set the verbosity HOT 6
- Make pyprep load MNE raw data for object, if not already loaded HOT 3
- filt vs filtfilt (MATLAB implementation)
- Add a "reject_by_annotation" parameter for finding bad channels HOT 1
- pyprep.utils._filter_design throws error for large sampling rates HOT 4
- Passing a custom montage to the PrepPipeline(raw, montage=?)? HOT 5
- Saving prep.raw give error " ValueError: Measurement infos are inconsistent for dig" HOT 4
- List of channel names causes TypeError in find_bad_by_ransac HOT 2
- migrate from `.zenodo.json` to `CITATION.cff` HOT 1
- update issue/pr templates HOT 1
- Computation of window size based on cutoff frequency in local detrend method HOT 1
- Question: using pyprep.NoisyChannels on numpy arrays HOT 1
- Issue with RawBrainVision HOT 2
- find_all_bads throws inf/nan error after filtering/detrending? HOT 12
- Documentation for Noisy Channels Algorithms' stand-alone use HOT 1
- [Feature suggestion] Allow for relevant annotation selection during processing.
- How to include the prep output in my preprocessing pipeline? HOT 1
- New release? HOT 4
- Possible to add an argument in find_bad_by_nan_flat() to change FLAT_THRESHOLD ? HOT 2
- Add to NoisyChannel a bad_by_psd method to tackle low-frequency artefacts HOT 8
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from pyprep.