- MNE version: 1.6.1
- operating system: Windows11
Hi,
I have 2 issues related to the edf format in which I save my seeg data.
- My data is in uV, I can see it when I read the TRC file with function ‘MicromedTRC’ from micromed_io.trc), yet when I read the TRC file using
raw = create_mne_from_micromed_recording(os.path.join(fpath, fname)), units appear in V inraw.info['chs'](for each channel, ‘unit_mul’ =0). I tried to manually update the unit by imposing ‘unit_mul’ = -6 for each channel, before saving the raw object in an edf file usingmne.export.export_raw(os.path.join(fpath, newname), raw, fmt='edf'), but then when I load the edf file again, ‘unit_mul’=0 for each channel. - I’m updating my channels type using
for inc in raw.info.ch_names:
if inc[0:3] == 'eog':
raw.set_channel_types({inc: 'eog'})
elif inc.endswith('z'):
raw.set_channel_types({inc: 'eeg'})
else:
raw.set_channel_types({inc: 'seeg'})
This works fine: I have the appropriate channels types, but when I save my raw object in the BIDS format using write_raw_bids(raw, bids_path, allow_preload=True, format='EDF', event_id={v: k for k, v in events_mapping.items()}, montage=digmontage, overwrite=True)and then load the edf ‘ieeg’ file saved in the BIDS dataset, the channel type of all my channels is ‘eeg’. Yet in the tsv file ‘channels’, the channels type are correct.
I’d be happy to have your advice on these issues: are these known issues (I couldn’t find them on the forum) and is there a way to avoid them?
Thanks a lot for your help,
All the best,
Flore