Hi,
in my BIDS dataset I do have
sub-_ses-_acq-mb3_dir-0_epi.nii.gz images.
To avoid redundant json files, i simply add a
acq-mb3_dir-0_epi.json file at the upper level
I get a BIDS validation error:
acq-mb3_dir-0_epi.json
Location:
sourcedata/acq-mb3_dir-0_epi.json
Reason:
Files with such naming scheme are not part of BIDS specification. This error is most commonly caused by typos in file names that make them not BIDS compatible. Please consult the specification and make sure your files are named correctly. If this is not a file naming issue (for example when including files not yet covered by the BIDS specification) you should include a “.bidsignore” file in your dataset (see https://github.com/INCF/bids-validator#bidsignore for details). Please note that derived (processed) data should be placed in /derivatives folder and source data (such as DICOMS or behavioural logs in proprietary formats) should be placed in the /sourcedata folder.
bids-validator@1.3.12
1: [ERR] Files with such naming scheme are not part of BIDS specification. This error is most commonly caused by typos in file names that make them not BIDS compatible. Please consult the specification and make sure your files are named correctly. If this is not a file naming issue (for example when including files not yet covered by the BIDS specification) you should include a ".bidsignore" file in your dataset (see https://github.com/bids-standard/bids-validator#bidsignore for details). Please note that derived (processed) data should be placed in /derivatives folder and source data (such as DICOMS or behavioural logs in proprietary formats) should be placed in the /sourcedata folder. (code: 1 - NOT_INCLUDED)
./task-ArchiEmotional_dir-ap_bold.json
Evidence: task-ArchiEmotional_dir-ap_bold.json
./task-ArchiEmotional_dir-ap_sbref.json
Evidence: task-ArchiEmotional_dir-ap_sbref.json
./task-ArchiEmotional_dir-pa_bold.json
Evidence: task-ArchiEmotional_dir-pa_bold.json
./task-ArchiEmotional_dir-pa_sbref.json
Evidence: task-ArchiEmotional_dir-pa_sbref.json
./task-ArchiSocial_dir-ap_bold.json
Evidence: task-ArchiSocial_dir-ap_bold.json
./task-ArchiSocial_dir-ap_sbref.json
Evidence: task-ArchiSocial_dir-ap_sbref.json
./task-ArchiSocial_dir-pa_bold.json
Evidence: task-ArchiSocial_dir-pa_bold.json
./task-ArchiSocial_dir-pa_sbref.json
Evidence: task-ArchiSocial_dir-pa_sbref.json
./task-ArchiSpatial_dir-ap_bold.json
Evidence: task-ArchiSpatial_dir-ap_bold.json
./task-ArchiSpatial_dir-ap_sbref.json
Evidence: task-ArchiSpatial_dir-ap_sbref.json
... and 200 more files having this issue (Use --verbose to see them all).
The only thing I did recently was to rename this from ‘./task-ArchiEmotional_acq-ap_bold.json’ (that was OK) to ‘./task-ArchiEmotional_dir-ap_bold.json’
Am I missing something or I am hitting a limitation of BIDS-validator ?
Looking at the regular expression in the validator used to match top level functional files it does not attempt to match ‘_dir-’ but it is matching ‘_acq-’ so this appears to be an oversight in the validator.
To confirm all these files are at the top level of the dataset?
Sorry , but I’m afraid I have nother one of that kind
sub-01_ses-00_task-ArchiSocial_dir-ap_bold.nii.gz454867.499 KB | application/gzip
Location:
sourcedata/sub-01/ses-00/func/sub-01_ses-00_task-ArchiSocial_dir-ap_bold.nii.gz
Reason:
Files with such naming scheme are not part of BIDS specification. This error is most commonly caused by typos in file names that make them not BIDS compatible. Please consult the specification and make sure your files are named correctly. If this is not a file naming issue (for example when including files not yet covered by the BIDS specification) you should include a ".bidsignore" file in your dataset (see https://github.com/INCF/bids-validator#bidsignore for details). Please note that derived (processed) data should be placed in /derivatives folder and source data (such as DICOMS or behavioural logs in proprietary formats) should be placed in the /sourcedata folder.
Evidence:
sub-01_ses-00_task-ArchiSocial_dir-ap_bold.nii.gz
sub-01_ses-00_task-ArchiSocial_dir-ap_sbref.nii.gz1812.495 KB | application/gzip
Location:
sourcedata/sub-01/ses-00/func/sub-01_ses-00_task-ArchiSocial_dir-ap_sbref.nii.gz
Reason:
Files with such naming scheme are not part of BIDS specification. This error is most commonly caused by typos in file names that make them not BIDS compatible. Please consult the specification and make sure your files are named correctly. If this is not a file naming issue (for example when including files not yet covered by the BIDS specification) you should include a ".bidsignore" file in your dataset (see https://github.com/INCF/bids-validator#bidsignore for details). Please note that derived (processed) data should be placed in /derivatives folder and source data (such as DICOMS or behavioural logs in proprietary formats) should be placed in the /sourcedata folder.
Evidence:
sub-01_ses-00_task-ArchiSocial_dir-ap_sbref.nii.gz
Bizarre! I haven’t published a fix for the first issue. My copy of the validator does not see ‘sourcedata/sub-01/ses-00/func/sub-01_ses-00_task-ArchiSocial_dir-ap_sbref.nii.gz’ as an issue but does throw an error for ‘./task-ArchiSocial_dir-ap_bold.json’
The sourcedata directory should be ignored by default in the validator.
I’ve released a new version of the validator 1.4.0. @bthirion if you have a chance could you try this new version from the command line to confirm that it validates your dataset now?
Will update here when a version of this is deployed onto OpenNeuro.
Sorry, I get the error below, which I don’t undertsand.
bt206016@is151225:/neurospin/tmp/bthirion/ibc_release/sourcedata$ bids-validator .
bids-validator@1.4.0
Unhandled rejection (
reason: TypeError: Cannot read property 'length' of undefined
at Object.formatIssues [as issues] (/home/bt206016/.nvm/versions/node/v13.7.0/lib/node_modules/bids-validator/utils/consoleFormat.js:21:21)
at /home/bt206016/.nvm/versions/node/v13.7.0/lib/node_modules/bids-validator/cli.js:47:36
at /home/bt206016/.nvm/versions/node/v13.7.0/lib/node_modules/bids-validator/validators/bids/start.js:26:7
at /home/bt206016/.nvm/versions/node/v13.7.0/lib/node_modules/bids-validator/utils/options.js:25:9
at /home/bt206016/.nvm/versions/node/v13.7.0/lib/node_modules/bids-validator/utils/options.js:63:9
at /home/bt206016/.nvm/versions/node/v13.7.0/lib/node_modules/bids-validator/utils/options.js:50:11
at processTicksAndRejections (internal/process/task_queues.js:97:5)
).
bt206016@is151225:/neurospin/tmp/bthirion/ibc_release/sourcedata$
I haven’t any custormized files. I have uninstalled and reinstalled bids-validator, but the result is unchanged.
Maybe there is an online version or circeci or anywhere that I can use ?
Thx for your time and patience.
Best,
B