skbold.exp_model.batch_fsf module¶
-
class
FsfCrawler
(preproc_dir, run_idf, template='mvpa', mvpa_type='trial_wise', output_dir=None, subject_idf='sub', event_file_ext='bfsl', func_idf='func', prewhiten=True, derivs=False, mat_suffix=None, sort_by_onset=False, n_cores=1)[source]¶ Bases:
object
Given an fsf-template, this crawler creates subject-specific fsf-FEAT files assuming that appropriate .bfsl files exist.
Parameters: - template (str) – Absolute path to template fsf-file. Default is ‘mvpa’, which models each bfsl-file as a separate regressor (and contrast against baseline).
- mvpa_type (str) – Whether to estimate patterns per trial (mvpa_type=’trial_wise’) or to estimate patterns per condition (or per run, mvpa_type=’run_wise’)
- preproc_dir (str) – Absolute path to directory with preprocessed files.
- run_idf (str) – Identifier for run to apply template fsf to.
- output_dir (str) – Path to desired output dir of first-levels.
- subject_idf (str) – Identifier for subject-directories.
- event_file_ext (str) – Extension for event-file; if ‘bfsl’ (default, for legacy reasons), then assumes single event-file per predictor. If ‘tsv’ (cf. BIDS), then assumes a single tsv-file with all predictors.
- func_idf (str) – Identifier for which functional should be use.
- prewhiten (bool) – Whether the data should be prewhitened in model fitting
- derivs (bool) – Whether to model derivatives of original regressors
- mat_suffix (str) – Identifier (suffix) for design.mat and batch.fsf file (such that it does not overwrite older files).
- sort_by_onset (bool) – Whether to sort predictors by onset (first trial = first predictor), or, when False, sort by condition (all trials condition A, all trials condition B, etc.).
- n_cores (int) – How many CPU cores should be used for the batch-analysis.
-
class
MelodicCrawler
(preproc_dir, run_idf, template=None, output_dir=None, subject_idf='sub', func_idf='func', copy_reg=True, copy_mc=True, varnorm=True, n_cores=1)[source]¶ Bases:
object
-
__init__
(preproc_dir, run_idf, template=None, output_dir=None, subject_idf='sub', func_idf='func', copy_reg=True, copy_mc=True, varnorm=True, n_cores=1)[source]¶ Given an fsf-template (Melodic), this crawler creates subject- specific fsf-melodic files and (optionally) copies the corresponding registration and mc directories to the out-directory.
Parameters: - template (str) – Absolute path to template fsf-file
- preproc_dir (str) – Absolute path to the directory with preprocessed files
- run_idf (str) – Identifier for run to apply template fsf to
- output_dir (str) – Path to desired output dir of Melodic-ica results.
- subject_idf (str) – Identifier for subject-directories.
- func_idf (str) – Identifier for which functional should be use.
- copy_reg (bool) – Whether to copy the subjects’ registration directory
- copy_mc (bool) – Whether to copy the subjects’ mc directory
- varnorm (bool) – Whether to apply variance-normalization (melodic option)
- n_cores (int) – How many CPU cores should be used for the batch-analysis.
-