New multi-user install for Mac Studio Apple M2 Ultra

Summary of what happened:

Hi,

I was given the task of installing fmriprep on multiple Macs. I’ve tried following the guide to install it in a Docker container. The faculty I’m assisting wants this in a multi-user environment, so I created the following folders.

Users/Shared/fmriprep/data
Users/Shared/fmriprep/output

Would someone help me with the setup or guide me through the process for a multi-user Mac Apple chip setup?

Thanks.

Command used (and if a helper script was used, a link to the helper script or the command generated):

docker run -ti --rm --platform linux/amd64 \
-v /Users/Shared/fmriprep/data:/data:ro \
-v /Users/Shared/fmriprep/output:/out \
nipreps/fmriprep:latest /data /out participant

Version:

Latest (24.0.1 at this time).

Environment (Docker, Singularity / Apptainer, custom installation):

Docker

Data formatted according to a validatable standard? Please provide the output of the validator:

bids-validator@1.14.6
(node:8) Warning: Closing directory handle on garbage collection
(Use `node --trace-warnings ...` to show where the warning was created)
	1: [ERR] This file is too small to contain the minimal NIfTI header. (code: 36 - NIFTI_TOO_SMALL)
		./sub-01/anat/sub-01_T1w.nii.gz
		./sub-01/func/sub-01_task-rest_bold.nii.gz

	Please visit https://neurostars.org/search?q=NIFTI_TOO_SMALL for existing conversations about this issue.

	2: [ERR] Empty files not allowed. (code: 99 - EMPTY_FILE)
		./sub-01/anat/sub-01_T1w.nii.gz
		./sub-01/func/sub-01_task-rest_bold.nii.gz

	Please visit https://neurostars.org/search?q=EMPTY_FILE for existing conversations about this issue.

	1: [WARN] The recommended file /README is missing. See Section 03 (Modality agnostic files) of the BIDS specification. (code: 101 - README_FILE_MISSING)

	Please visit https://neurostars.org/search?q=README_FILE_MISSING for existing conversations about this issue.

	2: [WARN] The Authors field of dataset_description.json should contain an array of fields - with one author per field. This was triggered because there are no authors, which will make DOI registration from dataset metadata impossible. (code: 113 - NO_AUTHORS)

	Please visit https://neurostars.org/search?q=NO_AUTHORS for existing conversations about this issue.

        Summary:            Available Tasks:        Available Modalities: 
        3 Files, 52B                                MRI                   
        1 - Subject                                                       
        1 - Session                                                       

Relevant log outputs (up to 20 lines):

Traceback (most recent call last):
  File "/opt/conda/envs/fmriprep/bin/fmriprep", line 8, in <module>
    sys.exit(main())
             ^^^^^^
  File "/opt/conda/envs/fmriprep/lib/python3.11/site-packages/fmriprep/cli/run.py", line 40, in main
    parse_args()
  File "/opt/conda/envs/fmriprep/lib/python3.11/site-packages/fmriprep/cli/parser.py", line 903, in parse_args
    validate_input_dir(
  File "/opt/conda/envs/fmriprep/lib/python3.11/site-packages/fmriprep/utils/bids.py", line 245, in validate_input_dir
    subprocess.check_call(['bids-validator', str(bids_dir), '-c', temp.name])  # noqa: S607
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/opt/conda/envs/fmriprep/lib/python3.11/subprocess.py", line 413, in check_call
    raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command '['bids-validator', '/data', '-c', '/tmp/tmpzyipqk6c.json']' returned non-zero exit status 1.

Screenshots / relevant information:


Hi @Alison_Peterson, and welcome to neurostars!

In the future, please do not delete the Software Support post template, which helps to organize your post. You can see I added it back in for you this time.

Most BIDS organizations would have their output folder in $BIDS/derivatives/fmriprep.

Looks like these are not full files, is it possible these are shortcuts?

Best,
Steven

Hi!
I created those files because I was getting a different error:

bids-validator@1.14.6
	1: [ERR] Quick validation failed - the general folder structure does not resemble a BIDS dataset. Have you chosen the right folder (with "sub-*/" subfolders)? Check for structural/naming issues and presence of at least one subject. (code: 61 - QUICK_VALIDATION_FAILED)
		.data

	Please visit https://neurostars.org/search?q=QUICK_VALIDATION_FAILED for existing conversations about this issue.

Traceback (most recent call last):
  File "/opt/conda/envs/fmriprep/bin/fmriprep", line 8, in <module>
    sys.exit(main())
             ^^^^^^
  File "/opt/conda/envs/fmriprep/lib/python3.11/site-packages/fmriprep/cli/run.py", line 40, in main
    parse_args()
  File "/opt/conda/envs/fmriprep/lib/python3.11/site-packages/fmriprep/cli/parser.py", line 903, in parse_args
    validate_input_dir(
  File "/opt/conda/envs/fmriprep/lib/python3.11/site-packages/fmriprep/utils/bids.py", line 245, in validate_input_dir
    subprocess.check_call(['bids-validator', str(bids_dir), '-c', temp.name])  # noqa: S607
  1. Created a subject directory:
mkdir -p /Users/Shared/fmriprep/data/sub-01/anat
mkdir -p /Users/Shared/fmriprep/data/sub-01/func
  1. I created dummy files for testing:
touch /Users/Shared/fmriprep/data/sub-01/anat/sub-01_T1w.nii.gz
touch /Users/Shared/fmriprep/data/sub-01/func/sub-01_task-rest_bold.nii.gz

Then I run again:

docker run -ti --rm --platform linux/amd64 \
-v /Users/Shared/fmriprep/data:/data:ro \
-v /Users/Shared/fmriprep/output:/out \
nipreps/fmriprep:latest /data /out participant

Hi @Alison_Peterson,

The BIDS validator will throw errors for empty files like that. Should be fine when you use real images.

Best,
Steven

1 Like