Hi Everyone,
I am a new user of MNE-NIRS package with no experience in Python. Since I watched Dr.Robert Luke’s webinar regarding the MNE-NIRS analysis, I became interested in exploring the package in Python.
I have run into many obstacles to try the package with my data, which brings out multiple questions. Some questions can sound very silly…
My data have been collected using NIRScout system having multiple outcome files including .nirs, .snirf per subject. Because I have used Homer3 for analysis, my files are organized by subject and each file of subjects contains all of the outcome files (nirs and snif files in the same folder). I am wondering if it is still okay to keep that structure of the files in each folder to run the data in MNE-NIRS package. Also, when running a group level analysis, can I have sub-folders by subjects in a folder?
Also, I grappled with how to import/load the data. In each subject folder, there are two files - .nirs, and .snirf - which one do you recommend to use ( mne.io.read_raw_nirx()
or ‘mne.io.read_raw_snirf()’)?
Lastly, here is the error code that I ran into. Due to the lack of my experience in Python, I could not figure out what it meant. I actually tried the both, nirx and snif codes. This is one of them. FYI, ANN is the file name of a subject, and I can see the ANN folder in the directory (User/hkim302/JupyterNotebook).
Thank you for your help in adavance!
Loading User/hkim302/JupyterNotebook/ANN
---------------------------------------------------------------------------
FileNotFoundError Traceback (most recent call last)
<ipython-input-69-ffff1d20a989> in <module>
----> 1 raw_intensity = mne.io.read_raw_nirx(fname, preload=False, verbose=None)
~\Anaconda3\lib\site-packages\mne\io\nirx\nirx.py in read_raw_nirx(fname, preload, verbose)
43 mne.io.Raw : Documentation of attribute and methods.
44 """
---> 45 return RawNIRX(fname, preload, verbose)
46
47
<decorator-gen-238> in __init__(self, fname, preload, verbose)
~\Anaconda3\lib\site-packages\mne\io\nirx\nirx.py in __init__(self, fname, preload, verbose)
76 fname = op.dirname(op.abspath(fname))
77
---> 78 fname = _check_fname(fname, 'read', True, 'fname', need_dir=True)
79
80 # Check if required files exist and store names for later use
~\Anaconda3\lib\site-packages\mne\utils\check.py in _check_fname(fname, overwrite, must_exist, name, need_dir)
176 f'{name} does not have read permissions: {fname}')
177 elif must_exist:
--> 178 raise FileNotFoundError(f'{name} does not exist: {fname}')
179 return str(op.abspath(fname))
180
FileNotFoundError: fname does not exist: User/hkim302/JupyterNotebook/ANN