-
Notifications
You must be signed in to change notification settings - Fork 34
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Artifact Detection and BCI-Fit Artifact Report #336
Conversation
Add channels back from devices, search for frontal channels to do eye blink detection from.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This will add some really useful functionality! My comments are optional but would make it easier to extend this with more options.
percent_bad: float = 50.0, | ||
detect_eog: bool = True, | ||
eye_channels: Optional[List[str]] = None, | ||
detect_voltage: bool = True) -> None: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Rather than having a of boolean flag for each artifact type it might be more flexible here to have a single parameter that is a list of ArtifactTypes of interest.
extra_labels: Optional[Annotations] = None) -> Annotations: | ||
"""Label the artifacts in the raw data.""" | ||
# Create an empty annotations object to store all the annotations | ||
annotations = mne.Annotations(0, 0, 'start') |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This class is very large and it might make sense to split up its responsibilities. One option is to introduce the concept of an ArtifactLabeler
with a subclass for each type (ex. VoltageLabeler
, EOGEventLabeler
). Then this method could iterate through the ArtifactTypes
of interest, matching each one to a labeler, and combine the results.
Overview
Added an Artifact Detection class to the
signal.evaluate
module. Updated the artifact report section to include information about artifacts detected.Ticket
https://www.pivotaltracker.com/story/show/187526878
https://www.pivotaltracker.com/story/show/187833646
Contributions
artifact.py
: module added to detect and report on artifacts in EEG data. This replaces the old evaluator and rules modules.report.py
: updated the artifact report to extract relevant information and add to the PDF report.Test
make test-all
& using thedemo_report.py
to produce reports.Documentation
Changelog