WIP: Finally Use Mffpy for read_raw_egi#12981
WIP: Finally Use Mffpy for read_raw_egi#12981scott-huberty wants to merge 3 commits intomne-tools:mainfrom
read_raw_egi#12981Conversation
- more functional - annotate acquisition skips
1. the current EGI reader does this. 2. If we don't do this, then the sensor positions will appear way larger than the head during calls like plot_sensors, plot_components etc. It seems like in the sensorLayout.xml file, that type "2" indicates a head shape point.
|
I came across this PR while exploring the EGI MFF refactor (referenced in #6937 and #8038) and wanted to share some findings after running the existing test suite on this branch n_channels = np.sum(list(mff_reader.num_channels.values())) # allocates for EEG + PNS
...
data_chunk, _ = mff_reader.get_physical_samples_from_epoch(epoch)["EEG"] # only reads EEG
...
eeg[:, start:end] = this_chunk # shape mismatchThis causes errors like |
@aman-coder03 feel free to create a superceding PR from this branch. But a friendly word of caution, IMO it will be more difficult to tackle this migration if you do not work with EGI/Magstim data and are unfamiliar with the file format and hardware. If you do not already need to work with EGI data, this might not be the best issue to tackle if you are a new contributor. I started this PR because I have an EGI dataset with nested event ID's (i.e. |
|
@scott-huberty thanks for the context! Could you share what specific upstream |
|
@scott-huberty I've spent the last 24 hours auditing this branch. I have locally resolved the ValueError broadcasting mismatch and the UnboundLocalError you and @aman-coder03 discussed. I've also identified the root of the datetime parsing failures. I am preparing a superceding PR to finalize this migration. Would you like to review my indexing fix before I open the new PR? |
closes #6937
Maybe also #11380 ?
xref #8038
This is not ready for review(!) But I am using
mffpyfor a project and so I figured I would get this on the board..Maybe a good target date for merge would be just after the MNE 1.9 release, so that devs can work with it for a few months before it is shipped in a stable release.
TODO:
TODO/XXXcommentsmffpy