Skip to content

Commit

Permalink
Integrated the classfile cleanup into pipeline
Browse files Browse the repository at this point in the history
  • Loading branch information
jstout211 committed Apr 5, 2024
1 parent 60c5353 commit 22bab2f
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions nih2mne/make_meg_bids.py
Original file line number Diff line number Diff line change
Expand Up @@ -297,6 +297,13 @@ def process_meg_bids(input_path=None, subject_in=None, bids_id=None,
for task, task_sublist in dset_dict.items():
for run, base_meg_fname in enumerate(task_sublist, start=1):
meg_fname = op.join(input_path, base_meg_fname)
try:
_clear_ClassFile(meg_fname) #Remove Trials that fail CTFtools
except:
logger.warn(f'''Could not clear the Classfile, this may cause
issues with processing. If so, change the following
file to write permissions and retry:
{str(op.join(meg_fname, 'ClassFile.cls'))}''')

if crop_trailing_zeros==True:
# This is necessary for trial based acq that is terminated early
Expand Down

0 comments on commit 22bab2f

Please sign in to comment.