QSIprep dependencies error fugue, prelude

Hello, I tried to run qsiprep version 0.16.0RC3 and it caused an error:

[WARNING] This document format requires a nonempty element.
Please specify either ‘title’ or ‘pagetitle’ in the metadata.
Falling back to ‘CITATION’
Cannot run qsiprep. Missing dependencies:
fugue (Interface: FUGUE)
fugue (Interface: FUGUE)
prelude (Interface: PRELUDE)

It seems to be the same error as this post: Cannot run qsiprep. Missing dependencies: fugue, prelude

Any suggestions on how to address this? Thank you.

Hi,

Hmm this is strange, I’ve been able to run 0.16.0RC3 find via singularity. What are your data like? In particular, what kind of SDC are you doing, if any? Both fugue and prelude are likely used for fieldmap operations, and maybe are only needed for a certain kind (e.g. phase diff, as opposed to RPE).

Best,
Steven

You are correct, I’m trying to run a dwi run with 42 directions with GRE field maps. The imaging parameters are described below. Should I skip using the fieldmaps, since FSL’s topup would address it?

  1. Diffusion MRI
    13.1. 42-directions; Acquisition time per run = 6m56s
    13.2. TR = 8000 ms; TE = 83 ms; voxel size = 2.0 mm isotropic; Slices = 68; FoV read = 256 mm; Phase enc. dir. A >> P; Accel. factor PE = 2; Filter: Raw filter, Prescan Normalize; Flip angle = not described; Delay in TR = 0 ms; PAT mode = GRAPPA; Multi-slice mode: Interleaved; Series: Interleaved; Fat suppr.: Fat sat.; Echo spacing = 0.73 ms; b-value 1 = 0 s/mm2; b-value 2 = 1000 s/mm2, b-value 1 and = 1; Diffusion scheme" Monopolar
    13.3. Information from pre-2022 documents: Cardiac-gated acquisition; # of volumes = 49 (42 directions, 7 B0); dummy scans collected for DWI (data discarded and not uploaded to PACS) = 15 s (unsure about how many TRs this corresponds to. This is cardiac-gated DTI, so TR is variable)
  1. Field map for DTI
    12.1. Gradient echo field maps for DWI: one scan as a pair of magnitude and phase image, acquisition time per run =1m20s
    12.2. TR = 800 ms; TE1 = 4.92 ms; TE2 = 7.38 ms; TE difference = 2.46 ms; voxel size = 4.0 x 4.0 x 2.0 mm; Slices = 68; FoV read = 256 mm; Filter: None; Flip angle = 60 deg; Measurements = 1; Multi-slice mode: Interleaved; Series: Interleaved; Fat suppr.: None; Phase enc. Dir. = A >> P (Y-axis)

This sounds like a bug and should be reported to the Github repo, though it seems someone already has an active issue: Cannot run qsiprep. Missing dependencies: fugue, prelude · Issue #407 · PennLINC/qsiprep · GitHub and that you’ve commented on it. Hopefully it gets addressed soon. I doubt QSIPrep meant to explicitly drop support for GRE fieldmaps. TOPUP is meant for blip-up-blip-down/RPE fieldmaps, as far as I know.

In the mean time, you can try the fieldmap-less approach for SDC (syn option) if you are in a rush. Or you can try to add those functions to the container yourself! This is a little more complicated, but still feasible.

  1. You need a local installation of FSL. If you already have one, great! If not, install FSL if you can.
  2. Make sure your local copy has fugue and prelude, by running which fugue or which prelude in the terminal. The paths to these commands should popup as $FSLDIR/bin/fugue or $FSLDIR/bin/prelude, where $FSLDIR is the path to your fsl installation.
  3. Enter your singularity container to see where its FSLDIR is. This can be done with
singularity shell -e /path/to/qsiprep.img

when in the container, try running either echo $FSLDIR or which fslreorient2std to see where FSL functions live.

  1. When running singularity, put your copies of fugue and prelude in the container. Your singularity command will look the same, EXCEPT you will be mounting your functions as well! This is done with the -B flag. For example:
singularity run -e -B /path/to/local/prelude:/path/to/singularity/prelude -B (do same with fugue) .... (rest of command is normal)

Essentially, you are tricking the container into using your copies of the command by placing them in the containers FSLDIR. Does this make sense?

Best,
Steven

Thanks for the detailed instructions Steven, I’ll give it a try. Cheers.

Hi @estephanmoana, Sorry for the late reply. This error is my fault. In reducing the size of the docker image in 0.16 I was over-aggressive and prelude and fugue were deleted. This will be fixed in the next release!