-
Notifications
You must be signed in to change notification settings - Fork 85
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
Fix bug if no event descriptions are present; support stim_type column in events.tsv #680
Conversation
If no event descriptions could be generated, we'd crash as we'd try to access descriptions like an array, while our placeholder would only be a string. This is fixed now. The other part of this PR is related to the naming of the column in the events.tsv file that contains the event description. According to BIDS, this column is optional and shall be named `trial_type`. Now I've come across multiple (older?) datasets where the column is called `stim_type` instead. I've now added support for reading this column if `stim_type` is not present. A warning will be issued in this case, informing the user that the column name should be changed. This was necessary to read the ds000117 datset from https://openneuro.org/datasets/ds000117
Closes mne-tools#41 Remaining / highlightes issues: - Original dataset doesn't store fine-calibration and crosstalk files according to BIDS, so not doing Maxwell filtering for now - I'd like to calculate the contrast of "face" vs "scrambled", however, to do that, I'd need to merge the "familiar" and "unfamiliar" events to "faces". We need to add support for operations like this. Tests will fail until mne-tools/mne-bids#680 has been merged.
Codecov Report
@@ Coverage Diff @@
## master #680 +/- ##
==========================================
+ Coverage 93.71% 93.80% +0.08%
==========================================
Files 22 22
Lines 2707 2713 +6
==========================================
+ Hits 2537 2545 +8
+ Misses 170 168 -2
Continue to review full report at Codecov.
|
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.
I don't know where "stim_type" comes from, but I think it's fair enough to handle it as proposed in this PR.
1 job failing due to download problems. |
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.
LGTM
+1 for MRG when CIs are green
Since the download problem seems to be persistent (@adam2392 was running into this issue too), and given that all but that one CI runs are green, this should be good to merge. |
thanks @hoechenberger |
* Process Faces dataset Closes #41 Remaining / highlightes issues: - Original dataset doesn't store fine-calibration and crosstalk files according to BIDS, so not doing Maxwell filtering for now - I'd like to calculate the contrast of "face" vs "scrambled", however, to do that, I'd need to merge the "familiar" and "unfamiliar" events to "faces". We need to add support for operations like this. Tests will fail until mne-tools/mne-bids#680 has been merged. * Remove cruft
If no event descriptions could be generated, we'd crash as we'd try
to access descriptions like an array, while our placeholder would only
be a string. This is fixed now.
The other part of this PR is related to the naming of the column in the
events.tsv file that contains the event description. According to
BIDS, this column is optional and shall be named
trial_type
. NowI've come across multiple (older?) datasets where the column is
called
stim_type
instead. I've now added support for reading thiscolumn if
trial_type
is not present. A warning will be issued inthis case, informing the user that the column name should be changed.
This was necessary to read the ds000117 datset from
https://openneuro.org/datasets/ds000117
Merge checklist
Maintainer, please confirm the following before merging: