Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

BIDS Specification is different than bids-validator for non-parametric structural MR images #1861

Open
Slevinski opened this issue Dec 14, 2023 · 2 comments

Comments

@Slevinski
Copy link
Contributor

The BIDS Specification allows for echo and chunk with non-parametric structural MR images. The bids-validator does not.

bids-validator

"regexp": "^[\\/\\\\](sub-[a-zA-Z0-9]+)[\\/\\\\](?:(ses-[a-zA-Z0-9]+)[\\/\\\\])?anat[\\/\\\\]\\1(_\\2)?(?:_task-[a-zA-Z0-9]+)?(?:_acq-[a-zA-Z0-9]+)?(?:_ce-[a-zA-Z0-9]+)?(?:_rec-[a-zA-Z0-9]+)?(?:_run-[0-9]+)?(?:_part-(imag|mag|phase|real))?_(?:@@@_anat_suffixes_@@@)\\.(@@@_anat_ext_@@@)$",

BIDS Specification Modality specific files section and the Entity Table appendix.
https://bids-specification.readthedocs.io/en/stable/modality-specific-files/magnetic-resonance-imaging-data.html#non-parametric-structural-mr-images
https://bids-specification.readthedocs.io/en/stable/appendices/entity-table.html

For the bids-validator, the new line should be:

  "regexp": "^[\\/\\\\](sub-[a-zA-Z0-9]+)[\\/\\\\](?:(ses-[a-zA-Z0-9]+)[\\/\\\\])?anat[\\/\\\\]\\1(_\\2)?(?:_task-[a-zA-Z0-9]+)?(?:_acq-[a-zA-Z0-9]+)?(?:_ce-[a-zA-Z0-9]+)?(?:_rec-[a-zA-Z0-9]+)?(?:_run-[0-9]+)?(?:_echo-[0-9]+)?(?:_part-(imag|mag|phase|real))?(?:_chunk-[0-9]+)?_(?:@@@_anat_suffixes_@@@)\\.(@@@_anat_ext_@@@)$",
@effigies
Copy link
Collaborator

effigies commented Dec 14, 2023

Thanks for the bug report! Would you be willing to submit a PR with your proposed fix?

@Slevinski
Copy link
Contributor Author

Slevinski commented Dec 14, 2023

Sure, I modified the regex and created a pull request.
#1863

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants