simulate_bids_dataset

bidsaid.simulate.simulate_bids_dataset(n_subs=1, n_sessions=1, n_runs=1, task_name='rest', output_dir=None, n_cores=None, progress_bar=False)[source]

Generate a Simulated BIDS Dataset with fMRIPrep Derivatives.

Creates a minimal BIDS dataset structure with fMRIPrep derivatives, including:
  • BIDS root directory with:
    • Dataset description JSON file

    • One simulated NIfTI image per subject/run

  • Derivatives folder with fMRIPrep outputs:
    • Dataset description JSON file

    • One simulated NIfTI image per subject/run

Note

Returns output_dir if the path exists.

Parameters

n_subsint, default=1

Number of subjects.

n_sessionsint or None, default=1

Number of sessions for each subject.

n_runsint, default=1

Number of runs for each subject.

task_namestr, default=”rest”

Name of task.

output_dirstr, Path, or None, default=None

Path to save the simulated BIDS directory to.

Important

If None, a directory named “simulated_bids_dir” will be created in the current working directory.

n_coresint or None, default=None

The number of cores to use for multiprocessing with Joblib (over subjects). The “loky” backend is used.

progress_barbool, default=False

If True, displays a progress bar.

Returns

Path

Root of the simulated BIDS directory.