Tutorial on BIDS/fMRIprep for Brainhack DC
This repository contains all the materials for the tutorial on BIDS/fMRIprep, and the materials needed to complete the associated challenges. I've included a copy of the Nature Neuro fMRIprep paper, the preprint to the paper (which has additional information), the dcm2niix application taken from https://github.com/rordenlab/dcm2niix , a folder with the results report generated by fMRIprep, my BIDS conversion script and associated parameters file, a job script to run fmriprep on an HPC using a singularity container, and a presentation on all of this. For the challenges below, it will be easiest to download or clone the entire repo to your machine. Though it is not needed for the challenges, and I highly advise against running fmriprep on your laptop, here is a link to obtain a copy of a singularity container of fMRIprep version 1.4.1: https://drive.google.com/file/d/1R_SYNm6wrteJXK-xEyWMlfm-A1Qt77vv/view?usp=sharing
CHALLENGE 1 - BIDS Conversion:
A) Download the zipped dicoms folder (and unzip) from this link (~2 GB; I'll give the link during the tur Then, download the dcm2niix application, the BidsConvert.sh & BidsConvertParameters.sh scripts from this repo. Now hack the BidsConvertParameters.sh file to match the paths of your machine, and run the script on the dicoms folder you downloaded. Document an errors that arise, and try to fix them.
B) Use the BIDS validator to see if this converted dataset is BIDS compatible. Are there any errors or warnings? If so, what do they mean. Is this dataset ready for fmriprep? https://bids-standard.github.io/bids-validator/
C) BONUS: If you have a dicoms folder of your own data, modify the parameters file and try using the BIDS conversion scripts on your own data.
CHALLENGE 2 - fMRIprep:
A) Download the fmriprep_reports folder and launch the html file contained therein. How many functional tasks were processed, and how many runs per task? How many spaces are the data processed to (i.e. what templates)? How do you get to the boilerplate methods section that fMRIprep generates?
B) Download the fmriprep_job_script_example.sh script. Read through the script and get an understanding of the options involved in running fmriprep. Now pretend you are running fmriprep on your laptop (I highly recommend against actually running it on your laptop because it will eat up all of your hardware resources and you won't be able to do anything else). Edit this code so that you could run this on your laptop. Pay special attention to the paths because the local paths need to be mapped to the paths within the container.
C) BONUS: If you have a server or powerful workstation that you can access, try running fmriprep using the script you just hacked. You can use the fmriprep-singularity container I provided a link for at the top of this README.