How is BIDS "run" meant to be used?

I was hoping for some clarity on the run entity.

The standard says:

Definition: If several scans of the same modality are acquired they MUST be indexed with a key-value pair: _run-1 , _run-2 , …, _run-<index> (only nonnegative integers are allowed for the <index> ). When there is only one scan of a given type the run key MAY be omitted.

This implies that all acquisitions should share the numbering scheme, although it would seem more natural for me to e.g. index task-rest and task-flanker separately, like:

  • task-rest_run-001

  • task-flanker_run-001

  • task-rest_run-002

  • task-flanker_run-002

What is expected by BIDS?

There’s more information in the task fMRI section of the specification here:

If more than one run of the same task has been acquired the run-<index> key/value pair MUST be used: _run-1 , _run-2 , _run-3 , and so on. If only one run was acquired the run-<index> can be omitted. In the context of functional imaging a run is defined as the same task, but in some cases it can mean different set of stimuli (for example randomized order) and participant responses.

To summarize, you would iterate run separately for your flanker and rest tasks.

Thanks, does that generalize to entities besides task?

There may be an exception or two that I can’t think of, but yes, this should generalize across entities.

Under Common principles, the definition for run is:

  1. Run - an uninterrupted repetition of data acquisition that has the same acquisition parameters and task (however events can change from run to run due to different subject response or randomized nature of the stimuli). Run is a synonym of a data acquisition.

As such, any time an entity distinguishes files with different acquisition parameters (or tasks), run should not be incremented.

1 Like

It sounds like this is outside of your current scope, @Trevor_Day, but just pinging in while thinking about run:

There’s a fun bit of ambiguity re: run in the context of longer tasks, such as movie-watching, which can span multiple acquisitions. In that context, run could be incremented only when exactly the same movie segment is shown twice or when different movie segments are shown. For more context, you can find the discussion here.