Open regisoc opened 9 months ago
Describe the bug When trying to upload/parse a .set file two types of behaviour appeared. Extracted from: https://docs.google.com/document/d/104zOjSfpGifbEgERGuI-6UTma1i_r4rHlmKc0ZSFl-o/edit?usp=sharing
.set
Browser Environment (please complete the following information):
List
Describe the bug When trying to upload/parse a
.set
file two types of behaviour appeared. Extracted from: https://docs.google.com/document/d/104zOjSfpGifbEgERGuI-6UTma1i_r4rHlmKc0ZSFl-o/edit?usp=sharingBrowser Environment (please complete the following information):
List
Case 1: `Cannot read file - list index out of range`
Logs: Case 1: ``` 127.0.0.1 - - [22/Nov/2023 10:45:55] "GET /socket.io/?EIO=4&transport=polling HTTP/1.1" 200 242 0.000417 (3541620) accepted ('127.0.0.1', 43558) connect: 9bU2t8_FzNRciT9nAAAC get_set_data: {'files': [{'path': '/home/seden/work/bids/1234-1234-FACE.set', 'task': 'FACE', 'run': 1}]} {'files': [{'path': '/home/seden/work/bids/1234-1234-FACE.set', 'task': 'FACE', 'run': 1}], 'subjectID': '', 'recordingID': '', 'date': '2000-01-01 00:00:00', 'fileFormat': 'set'} get_set_data: {'files': [{'path': '/home/seden/work/bids/1234_1234_FACE.set', 'task': 'FACE', 'run': 1}]} {'files': [{'path': '/home/seden/work/bids/1234_1234_FACE.set', 'task': 'FACE', 'run': 1}], 'subjectID': '', 'recordingID': '', 'date': '2000-01-01 00:00:00', 'fileFormat': 'set'} BIDS Conversion - START eeg_to_bids: {'eegData': {'files': [{'path': '/home/seden/work/bids/1234_1234_FACE.set', 'task': 'FACE', 'run': 1}], 'subjectID': '', 'recordingID': '', 'date': '2000-01-01T05:00:00.000Z', 'fileFormat': 'set'}, 'fileFormat': 'set', 'eegRuns': [{'eegFile': '/home/seden/work/bids/1234_1234_FACE.set', 'eegBIDSBasename': None, 'eventFile': None, 'task': 'FACE', 'run': 1}], 'modality': 'eeg', 'bids_directory': '/home/seden/work/EEG2BIDS_output', 'read_only': False, 'event_files': '', 'site_id': '', 'project_id': '', 'sub_project_id': '', 'session': '1234', 'participantID': '1234', 'preparedBy': 'roc', 'bidsMetadata': '', 'reference': '1234', 'powerLineFreq': '50', 'subject_id': '', 'outputFilename': '1234_1234_bids', 'age': 'n/a', 'sex': 'n/a', 'project': 'n/a', 'cohort': 'n/a'} eeg_to_bids_thread: {'eegData': {'files': [{'path': '/home/seden/work/bids/1234_1234_FACE.set', 'task': 'FACE', 'run': 1}], 'subjectID': '', 'recordingID': '', 'date': '2000-01-01T05:00:00.000Z', 'fileFormat': 'set'}, 'fileFormat': 'set', 'eegRuns': [{'eegFile': '/home/seden/work/bids/1234_1234_FACE.set', 'eegBIDSBasename': None, 'eventFile': None, 'task': 'FACE', 'run': 1}], 'modality': 'eeg', 'bids_directory': '/home/seden/work/EEG2BIDS_output', 'read_only': False, 'event_files': '', 'site_id': '', 'project_id': '', 'sub_project_id': '', 'session': '1234', 'participantID': '1234', 'preparedBy': 'roc', 'bidsMetadata': '', 'reference': '1234', 'powerLineFreq': '50', 'subject_id': '', 'outputFilename': '1234_1234_bids', 'age': 'n/a', 'sex': 'n/a', 'project': 'n/a', 'cohort': 'n/a'} - Time: init started. - Converter: init started. Traceback (most recent call last): File "/home/seden/work/EEG2BIDS/python/libs/iEEG.py", line 286, in to_bids raw = mne.io.read_raw_eeglab(input_fname=file, preload=False, verbose=True) File "/home/seden/work/EEG2BIDS/python/lib/python3.8/site-packages/mne/io/eeglab/eeglab.py", line 311, in read_raw_eeglab return RawEEGLAB( File "Case 2: `Cannot read file - The file does not seem to contain epochs (trials less than 2). You should try using read_raw_eeglab function.`
``` BIDS Conversion - START eeg_to_bids: {'eegData': {'files': [{'path': '/home/seden/work/bids/1234_1234_FACE.set', 'task': 'FACE', 'run': 1}], 'subjectID': '', 'recordingID': '', 'date': '2000-01-01T05:00:00.000Z', 'fileFormat': 'set'}, 'fileFormat': 'set', 'eegRuns': [{'eegFile': '/home/seden/work/bids/1234_1234_FACE.set', 'eegBIDSBasename': None, 'eventFile': None, 'task': 'FACE', 'run': 1}], 'modality': 'eeg', 'bids_directory': '/home/seden/work/EEG2BIDS_output', 'read_only': False, 'event_files': '', 'site_id': '', 'project_id': '', 'sub_project_id': '', 'session': '1234', 'participantID': '1234', 'preparedBy': 'roc', 'bidsMetadata': '', 'reference': '1234', 'powerLineFreq': '50', 'subject_id': '', 'outputFilename': '1234_1234_bids', 'age': 'n/a', 'sex': 'n/a', 'project': 'n/a', 'cohort': 'n/a'} eeg_to_bids_thread: {'eegData': {'files': [{'path': '/home/seden/work/bids/1234_1234_FACE.set', 'task': 'FACE', 'run': 1}], 'subjectID': '', 'recordingID': '', 'date': '2000-01-01T05:00:00.000Z', 'fileFormat': 'set'}, 'fileFormat': 'set', 'eegRuns': [{'eegFile': '/home/seden/work/bids/1234_1234_FACE.set', 'eegBIDSBasename': None, 'eventFile': None, 'task': 'FACE', 'run': 1}], 'modality': 'eeg', 'bids_directory': '/home/seden/work/EEG2BIDS_output', 'read_only': False, 'event_files': '', 'site_id': '', 'project_id': '', 'sub_project_id': '', 'session': '1234', 'participantID': '1234', 'preparedBy': 'roc', 'bidsMetadata': '', 'reference': '1234', 'powerLineFreq': '50', 'subject_id': '', 'outputFilename': '1234_1234_bids', 'age': 'n/a', 'sex': 'n/a', 'project': 'n/a', 'cohort': 'n/a'} - Time: init started. - Converter: init started. /home/seden/work/EEG2BIDS/python/libs/iEEG.py:286: RuntimeWarning: Estimated head radius (0.9 cm) is below the 3rd percentile for infant head size. Check if the montage_units argument is correct (the default is "mm", but your channel positions may be in different units). raw = mne.io.read_raw_eeglab(input_fname=file, preload=False, verbose=True) Traceback (most recent call last): File "/home/seden/work/EEG2BIDS/python/libs/iEEG.py", line 286, in to_bids raw = mne.io.read_raw_eeglab(input_fname=file, preload=False, verbose=True) File "/home/seden/work/EEG2BIDS/python/lib/python3.8/site-packages/mne/io/eeglab/eeglab.py", line 311, in read_raw_eeglab return RawEEGLAB( File "