Donders-Institute / bidscoin

BIDScoin converts your source-level neuroimaging data to BIDS
https://bidscoin.readthedocs.io
GNU General Public License v3.0
131 stars 35 forks source link

Support for CT images or guideline for user to add additional modalities #186

Closed yehman closed 1 year ago

yehman commented 1 year ago

Is your feature request related to a problem? Please describe. I'm converting a lot of modalities including CT, which is apparently not recognized by bidscoin.

Describe the solution you'd like CT images being converted and placed into respective BIDS compliant folders for CT images.

Describe alternatives you've considered I'm currently setting CT images as T1w images with acq labeled as CT.

Additional context I've looked into adding CT manually into the bidscoin schema, but it is non-trivial, so perhaps a guideline on which changes need to be made would be helpful so users could add their own modalities.

marcelzwiers commented 1 year ago

I don't know much about CT and I haven't seen any documentation on the support for it in BIDS. The bids schemas are made by BIDS working groups and I simply copied them into bidscoin (see the original here: https://github.com/bids-standard/bids-specification/tree/master/src/schema). What can be done instead is making an unofficial BIDS-like CT modality ourselves (and add it to the .bidsignore file) in the template bidsmap (and perhaps write a separate plugin if needed). No need to edit the schemas

marcelzwiers commented 1 year ago

Alternatively, you can label your CT as extra_data

marcelzwiers commented 1 year ago

Labeling your CT as T1w is not a good idea, it will cause bids-apps to crash or generate meaningless results

marcelzwiers commented 1 year ago

image

marcelzwiers commented 1 year ago

If you want to add CT as a separate modality (instead of extra_data), you can have a look at how this is done for MRS (see e.g. the Twix section in the bidsmap_dccn.yaml template)

yehman commented 1 year ago

Thanks for pointing me in the right direction. I will take a look at 'bidsmap_dccn.yaml' to see if I can make an alternative template. (and leave schema alone) I have tried putting CTs in extra_data, but we also have lots of extra_data, so it gets lost in the mix.

Since this posting, I have learned that CT in BIDS is an extension (BEP024) that is not yet completed at this time. That would explain why it is not yet merged into the main BIDS standard yet. Chris Rorden of dcm2niix implemented partial support (https://neurostars.org/t/ct-in-bids-format/9129/3) for CT including json sidecar with some caveats, which is sufficient for our needs (coregistration of iEEG electrode locations to MRI).

marcelzwiers commented 1 year ago

I'll see if I can add a CT item to the anat section of the template bidsmap (this was suggested in the BEP)

marcelzwiers commented 1 year ago

Done! (commit 7cf6846c54825c8e60b9ec4019680893b486dbb8)