Closed Ferdodonna closed 4 years ago
@thht it's a fieldtrip dataset. Any idea?
hi @Ferdodonna, first of all, thank you for the good and detailed bug report.
from the matlab screenshot of the structure you provide it seems that this is not a FieldTrip data structure you are trying to load. the read_*_fieldtrip
functions can only handle data structures created by FieldTrip. it might be the case that FieldTrip has changed their structures very recently, but so far i am not aware of that.
what matlab toolbox does the data structure originate from?
Oh that is my bad. I told @agramfort it might be fieldtrip, even though I've never used Matlab. This is not my data, I just wanted to play around with P300s in MNE. I'm currently asking the author what they used for preprocessing the data. Should I delete this issue?
no problem. however, it is quite easy to import this data into mne.
you basically load the mat file into python using pymatreader like this:
from mne.externals.pymatreader import read_mat
mat_data = read_mat(fname)
and then you use mne.create_info
to create the Info
object and with that create a mne datastructure from an array using one of these classes: https://mne.tools/stable/python_reference.html#id4
Hello, is this problem solved now? I also want to import the. Mat file into python program,thanks @Ferdodonna
Hello, is this problem solved now? I also want to import the. Mat file into python program,thanks @Ferdodonna
Hello @AiCxlai please re-read the comment immediately above yours: https://github.com/mne-tools/mne-python/issues/7716#issuecomment-623885071
If that doesn't work for you, please use our forum (https://mne.discourse.group) to ask usage questions.
Describe the bug
Two errors are raised while trying to read a .mat file. File can be opened and plotted in Matlab:
Steps to reproduce
Dataset used: P300S01.mat [size 40MB]
Expected results
I expected a Raw object to be created, using the raw variable as reference.
Actual results
Actual output:
Additional information
Platform: Windows-10-10.0.18362-SP0 Python: 3.7.3 (default, Mar 27 2019, 17:13:21) [MSC v.1915 64 bit (AMD64)] Executable: C:\Users\suuuj\Anaconda3\python.exe CPU: Intel64 Family 6 Model 142 Stepping 10, GenuineIntel: 8 cores Memory: 7.9 GB
mne: 0.20.0 numpy: 1.18.3 {blas=C:\projects\numpy-wheels\numpy\build\openblas_info, lapack=C:\projects\numpy-wheels\numpy\build\openblas_lapack_info} scipy: 1.2.1 matplotlib: 3.2.0 {backend=Qt5Agg}
sklearn: 0.20.3 numba: 0.43.1 nibabel: 3.0.2 cupy: Not found pandas: 1.0.3 dipy: 1.1.1 mayavi: 4.7.1 {qt_api=pyqt5, PyQt5=5.14.1} pyvista: Not found vtk: 8.1.2