Skip to content

BIDS

If you are following the project workflow, by now you should have a project set up on the cluster and you might be in the process of organizing your raw data. The next step is to convert your data into BIDS format.

BIDS is an acronym that stands for Brain Imaging Data Structure. It is a standardized format for the organization and the description of neuroscientific data (see the fMRI example below).
In a nutshell, BIDS provides a framework for standardizing file names, folder structures and metadata for different kinds of data such as neuroimaging, behavioral, physiological etc.
We recommend you to go through the BIDS specification page and BIDS Starter Kit pages to understand more in depth the concepts and the phylosophy behind BIDS. Here you can find a collection of examples of converted BIDS datasets.

.
├── CHANGES
├── dataset_description.json
├── participants.tsv
├── README
└── sub-01
    ├── anat
       ├── sub-01_T1w.nii.gz
       ├── sub-01_T1w.json
       ├── sub-01_T2w.nii.gz
       └── sub-01_T2w.json
    ├── func
       ├── sub-01_task-mybrillianttask_bold.nii.gz
       ├── sub-01_task-mybrillianttask_bold.json
       └── sub-01_task-mybrillianttask_events.tsv
    └── task-mybrillianttask_bold.json

Why BIDS?

  • It provides a logical and intelligible structure for data of different kinds.
  • It makes your data clear and reusable by other researchers, thus increasing the chance of collaborations and the chance of being cited.
  • It helps you to organize your data without coming up by yourself with an efficient and flexible structure.
  • It has been adopted by all the major tools for neuroscientific analysis.
  • It improves science and also your science.

How to BIDS

In the following tabs, you can find links to different tools to convert unprocessed data into BIDS for different modalities. We suggest only on specific tools that are either widely used or provide some advantages for the users, for an exstensive list of bids converters, please refer to the official BIDS page.

Before you start converting your data, we strongly recommend to go through the BIDS specification page relative to your modalities of interest. Make sure you read the common principles to grasp the jargon used by BIDS. If you have any issue or need help for data conversion, please write to cecile-admins-l at ovgu.de

There are several very efficient tools for (f)MRI bids conversion, mainly python based:

  • bidscoin: It is a GUI based and user friendly converter; it allows users to easily map dicom files with the appropriate bids file names and structure. Once one partipant dataset has been converted, assuming equal settings for all participants, the conversion can be run for all participants at once without the need to specify a participant-specific conversion. It can also be used via command line. Bidscoin tutorial
  • dcm2bids: A very powerful command line based converter. Users need to specify a configuration file (.json file) that describes the content of the dataset and allows the tool to map each image to the appropriate bids file. It also provides a helper function that guesses the nature of the images and helps users to fill in the configuration file. dcm2bids tutorial
  • heudiconv: A very powerful converter based on command line; it requires to define heuristics via python scripting to achieve a correct conversion. It helps users to create proper heuristics by producing a dicominfo.tsv which lists all the images in the dicom files and relative information. Heudiconv tutorial

EEG BIDS recommended formats

Given the variety of EEG data formats, BIDS recommends two main formats (we also strongly suggest to use these two formats):

  • European format: .edf
  • BrainVision format: .vhdr, .vmrk, .eeg

Other BIDS accepted formats, although not recommended by BIDS, are Biosemi: .bdf and EEGLAB: .fdt, .set.

Relevant converters

  • mne-bids: A python based converter related to the mne analysis library. It requires python coding. mne-bids tutorial
  • fieldtrip: Matlab based converter, it requires matlab coding. It can convert non-recommended data formats to BrainVision or European formats fieldtrip bids tutorial
  • eeglab: GUI based and user friendly converter; being a Matlab based tool, users can entirely script their data conversion EEG-BIDS tutorial

Physiological data

We recommend to read the dedicated page in the BIDS website.

Physio data general rules

  • What kind of data: Cardiac, respiratory and other continuous recordings
  • File types: Continuous recordings as compressed files .tsv.gz (no header). Metadata as .json files.
  • Where: Data can go under different <datatype>/ folders, such as func, anat, dwi, meg, eeg, ieeg, or beh
  • How: Data must have the following format:
    <matches>[_recording-<label>]_physio.tsv.gz <matches>[_recording-<label>]_physio.json where <matches> can be sub-012_task-mytaskname and _recoding-<label> can be used to distinguish between two or more type of recordings e.g. recording-breathing and recording-eyetracking. In case you have multiple sessions and runs your file might be: sub-012_ses-1_task-mytaskname_run-1-breathing_physio.tsv.gz and the relative metadata sub-012_ses-1_task-mytaskname_run-1-breathing_physio.json.

Eye-tracking data

Eye-tracking data roughly follows the principles of physiological data, but with some fundamental differences, we recommend to carefully read the relevant section in the official page

For eye-tracking data conversion, we suggest to use the python based library eye2bids. It works quite well with data collected with all the major eye-trackers. Alternatively, you can use Fieldtrip; both software are already available in Cecile.

The BIDS proposal for non-invasive brain stimulation is currently in an advanced development stage, but still work in progress; please refer to the bep037 page or the github page

Anonimize your data

Although BIDS helps to pseudo-anonymize your dataset, data such as MRI anatomical images require further steps to reduce the possibility to link a dataset to a specific person. The common approach is to use algorithms for the de-identification of neuroimaging data like defacing. Here it is a list of anonymization tools

Validate your BIDS dataset

After you have accomplished the BIDS conversion, the last step is to validate your dataset. Keep in mind that this step is very important to ensure that your dataset actually complies with BIDS.

The validation can be done on Cecile by using bids-validator. The bids-validator is installed on Cecile, you can use it as any other software, if you do not know how to use software on Cecile, please refer to the software page.

Periodical validation checks

In order to keep the minimal standards on Cecile, there will be periodical BIDS validation on your dataset, in case a dataset is not valid you will receive an email asking to make your dataset BIDS compliant.