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

tools/minc_to_bids_converter.pl #1070

Open
3 tasks
cmadjar opened this issue Apr 5, 2024 · 5 comments
Open
3 tasks

tools/minc_to_bids_converter.pl #1070

cmadjar opened this issue Apr 5, 2024 · 5 comments

Comments

@cmadjar
Copy link
Collaborator

cmadjar commented Apr 5, 2024

Test Plan

  • Set config options in 'MINC to BIDS Converter Tool Options' of the Configuration module

  • Run following command:

perl tools/minc_to_bids_converter.pl -profile prod -dataset_name BIDS_LORIS25_test -verbose
  • Run bids-validator:
sudo npm install -g bids-validator
bids-validator /data/Loris-MRI/data/BIDS_export/BIDS_LORIS25_test/
  • If validator gives errors with a code, enter into the 'BIDS Validation options to ignore' config under 'MINC to BIDS Converter Tool Options' the codes as values, and test that the warnings are silenced

Bugs previously found

@CamilleBeau
Copy link

I am getting this error from running the bids-validator:

(loris-mri-python) lorisadmin@cbeaudoin-test-26:/opt/Loris-MRI/bin/mri$ bids-validator /data/Loris-MRI/data/BIDS_export/BIDS_LORIS25_test/
/usr/lib/node_modules/bids-validator/dist/commonjs/cli.js:127308
var fd = FormData;
^

ReferenceError: FormData is not defined
at node_modules/then-request/lib/browser.js (/usr/lib/node_modules/bids-validator/dist/commonjs/cli.js:127308:14)
at __require2 (/usr/lib/node_modules/bids-validator/dist/commonjs/cli.js:111080:51)
at Object. (/usr/lib/node_modules/bids-validator/dist/commonjs/cli.js:128964:36)
at Module._compile (node:internal/modules/cjs/loader:1198:14)
at Object.Module._extensions..js (node:internal/modules/cjs/loader:1252:10)
at Module.load (node:internal/modules/cjs/loader:1076:32)
at Function.Module._load (node:internal/modules/cjs/loader:911:12)
at Module.require (node:internal/modules/cjs/loader:1100:19)
at require (node:internal/modules/cjs/helpers:119:18)
at Object. (/usr/lib/node_modules/bids-validator/bin/bids-validator:18:30)

@CamilleBeau
Copy link

Other than that, I got these warnings in the converter script, but everything else ran fine. Not sure all of these are expected or bugs:

WARNING: Cannot compute EffectiveEchoSpacing & TotalReadoutTime for demo_947103_V6_fMRI_001.mnc
'dicom_0x0019:el_0x1028' should be a number. Its value is 26.483
'dicom_0x0051:el_0x100b' should be a number. Its value is 64

WARNING: skipping demo_947103_V6_fieldmapDWI_002.mnc since fieldmapDWI is not listed in bids_mri_scan_type_rel.
(also a few more like this)
WARNING: skipping demo_300125_V1_fieldmapBOLD_003.mnc since fieldmapBOLD is not listed in bids_mri_scan_type_rel.
WARNING: skipping demo_300125_V1_dwi25_001.mnc since dwi25 is not listed in bids_mri_scan_type_rel.
WARNING: skipping demo_300170_V1_dwi65_001.mnc since dwi65 is not listed in bids_mri_scan_type_rel.

WARNING: SliceTiming is not supplied as the values read from the MINC header seem erroneous.
This is most likely due to a dcm2mnc conversion problem

WARNING: Cannot compute EffectiveEchoSpacing & TotalReadoutTime for demo_300192_V1_fMRI_002.mnc
'dicom_0x0019:el_0x1028' should be a number. Its value is -49b, -9b, 83b, -29b, -91b, 123b, 58b, 64b
'dicom_0x0051:el_0x100b' should be a number. Its value is
=> This is unfortunately the result of a bad dcm2mnc conversion...

@CamilleBeau
Copy link

Note: Node.js >= 18 required for bids-validator to work

@CamilleBeau
Copy link

After #1127, the output from bids-validator looks like this:

Screen Shot 2024-05-28 at 12 53 14 PM Screen Shot 2024-05-28 at 12 53 24 PM

Is this normal output or does it indicate an issue with the minc_to_bids_converter.pl?

@CamilleBeau
Copy link

Following discussion with Cecile, this script is passing tests with #1127

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

No branches or pull requests

2 participants