Dcm2bids config file - fieldmaps "IntendedFor" indexes

I am using dcm2bids to convert MRI data to bids format, which I will eventually preprocess in fMRIprep. I have multiple field maps that map to different functional scans. An example protocol:

T1
Functional scan 1
Functional scan 2
Functional scan 3
GRE Field map
Functional scan 4
Functional scan 5
Functional scan 6
Functional scan 7
Functional scan 8
GRE Field map
Functional scan 9
Functional scan 10

The scanner outputs 2 folders for each field map, one with magnitude and one with phasediff. So, in my dcm2bids config file, I have added this code:

  {
    "dataType": "fmap",
    "modalityLabel": "magnitude1",
    "customLabels": "run-1",
    "criteria": {
        "SidecarFilename": "010*",
        "EchoTime": 0.00492
    },
    "intendedFor": [
        1,
        2,
        3,
        7,
        8
    ]
  },
  {
    "dataType": "fmap",
    "modalityLabel": "magnitude2",
    "customLabels": "run-1",
    "criteria": {
        "SidecarFilename": "010*",
        "EchoTime": 0.00738
    },
    "intendedFor": [
        1,
        2,
        3,
        7,
        8]
  },
  {
    "dataType": "fmap",
    "modalityLabel":"phasediff",
    "customLabels": "run-1",
    "criteria": {
        "SidecarFilename": "011*",
        "EchoTime1": 0.00492,
        "EchoTime2": 0.00738
    },
    "intendedFor": [
        1,
        2,
        3,
        7,
        8]
  },

My question is: When I am counting the indexes, do I count the field map as 2 indexes (mag and phasediff, as the output folders look like) as follows:

T1 (0)
Functional scan 1 (1)
Functional scan 2 (2)
Functional scan 3 (3)
GRE Field map (4,5)
Functional scan 4 (6)
Functional scan 5 (7)
Functional scan 6 (8)
Functional scan 7 (9)
Functional scan 8 (10)
GRE Field map (11,12)
Functional scan 9 (13)
Functional scan 10 (14)

Or do I count them as 3 indexes (mag 1, mag 2, phase diff) as follows:

T1 (0)
Functional scan 1 (1)
Functional scan 2 (2)
Functional scan 3 (3)
GRE Field map (4,5,6)
Functional scan 4 (7)
Functional scan 5 (8)
Functional scan 6 (9)
Functional scan 7 (10)
Functional scan 8 (11)
GRE Field map (12,13,14)
Functional scan 9 (15)
Functional scan 10 (16)


Hi @ed11zq,

Keep in mind this convention is for an OLD version of dcm2bids, which now uses an ID system instead of the serial position index (see here: Create a config file - dcm2bids documentation).

All you have to do is count the position of the items in the config file. It seems like you only put the part of the config file with your fmaps so I cannot say which order is correct, but it is solely based on the position of the items in the config.

But as stated earlier, this method is now deprecated in dcm2bids version 3+.

Best,
Steven

This is helpful, Steven! I will see about using the ID instead. Thank you.