PennLINC / CuBIDS

Curation of BIDS (CuBIDS): A sanity-preserving software package for processing BIDS datasets.
https://cubids.readthedocs.io/
MIT License
21 stars 10 forks source link

Add command to replace IntendedFor fields with B0FieldSource/B0FieldIdentifier #274

Open tsalo opened 11 months ago

tsalo commented 11 months ago

SDCFlows doesn't seem to work on phase-difference field maps with the IntendedFor field, but it does work on B0FieldSource/B0FieldIdentifier fields. EPI distortion correction seems to work with either one.

I'm not sure how to correctly divvy up field maps if multiple ones are intended for the same distorted files.

Per Matt, check for shim settings.

mattcieslak commented 11 months ago

Just to double-check, which of the phasediff files had the IntendedFor in its sidecar? both the phasediff and the magnitude images?

tsalo commented 11 months ago

I just checked and it's actually a separate-phase maps setup, but the IntendedFor is present in all four files.

mattcieslak commented 11 months ago

This might be an sdcflows bug then

tsalo commented 11 months ago

@mattcieslak you're right. It looks like SDCFlows identifies B0Field fmaps first, and it ignores the session entity when it does it, so having even one B0Field-type fmap in the BIDS dataset will mean that IntendedFor ones won't be identified.

tsalo commented 11 months ago

Still, given that there's this weird limitation in SDCFlows, it would definitely be useful to have a command that ensures that we use consistent field map labeling in a dataset.

tsalo commented 9 months ago

Plus it would generally be a good idea to include tools to basically update BIDS datasets to use newer features. Here are a few examples: