Hi all! I’m very unfamiliar with MEG data in general, but am trying to use the MNE package to load in some data collected several years ago (in 2013). From what I can tell, the data is in KIT format, such that I have several .sqd files (plus an .hsp and .elp file) for each subject.
To start, I tried to use the function mne.io.read_raw_kit(data_fn)
to read it in.
When doing so, the first error I got was UnsupportedKITFormat: SQD file format V2R001 is not officially supported. Set allow_unknown_format=True to load it anyways.
This is probably unsurprising, given how old the data is.
But when changing that allow_unknown_format
flag to True, I get a different error that is much less informative. Here’s the full trace:
Extracting SQD Parameters from data/meg/R0487/R0487_MEGBound_Block1_5.16.13.sqd...
Creating Raw.info structure...
---------------------------------------------------------------------------
TypeError Traceback (most recent call last)
<ipython-input-15-979032905ed0> in <module>
----> 1 mne.io.read_raw_kit(input_fname = data_fn, allow_unknown_format=True)
~/opt/anaconda3/lib/python3.8/site-packages/mne/io/kit/kit.py in read_raw_kit(input_fname, mrk, elp, hsp, stim, slope, stimthresh, preload, stim_code, allow_unknown_format, standardize_names, verbose)
914 coordinates should be in units of meters.
915 """
--> 916 return RawKIT(input_fname=input_fname, mrk=mrk, elp=elp, hsp=hsp,
917 stim=stim, slope=slope, stimthresh=stimthresh,
918 preload=preload, stim_code=stim_code,
<decorator-gen-254> in __init__(self, input_fname, mrk, elp, hsp, stim, slope, stimthresh, preload, stim_code, allow_unknown_format, standardize_names, verbose)
~/opt/anaconda3/lib/python3.8/site-packages/mne/io/kit/kit.py in __init__(self, input_fname, mrk, elp, hsp, stim, slope, stimthresh, preload, stim_code, allow_unknown_format, standardize_names, verbose)
132 self.preload = False
133 logger.info('Creating Raw.info structure...')
--> 134 info, kit_info = get_kit_info(
135 input_fname, allow_unknown_format, standardize_names)
136 kit_info['slope'] = slope
<decorator-gen-257> in get_kit_info(rawfile, allow_unknown_format, standardize_names, verbose)
~/opt/anaconda3/lib/python3.8/site-packages/mne/io/kit/kit.py in get_kit_info(rawfile, allow_unknown_format, standardize_names, verbose)
514 if allow_unknown_format:
515 unsupported_format = True
--> 516 warn("Force loading KIT format %s", version_string)
517 else:
518 raise UnsupportedKITFormat(
~/opt/anaconda3/lib/python3.8/site-packages/mne/utils/_logging.py in warn(message, category, module, ignore_namespaces)
363 # because we move out of the MNE stack, so warnings won't properly
364 # recognize the module name (and our warnings.simplefilter will fail)
--> 365 warnings.warn_explicit(
366 message, category, fname, lineno, module,
367 globals().get('__warningregistry__', {}))
TypeError: 'str' object is not callable
Any insight into what’s going on?
For reference, my MNE version is 0.24.0, and I’m running this on MacOS Big Sur 11.6.