psychoinformatics-de / datalad-hirni

DataLad extension for (semi-)automated, reproducible processing of (medical/neuro)imaging data
http://datalad.org
Other
5 stars 8 forks source link

File size as a criteria #110

Open TobiasKadelka opened 5 years ago

TobiasKadelka commented 5 years ago

Is it possible, to read the size of the niftis, that hirni should create, before creating the bids-dataset? We had different cases, where nobody provided information about which is the correct data (some might be localizer or tests with problems). In these cases, my task was, to select the nifti with the biggest file-size and choose this as the relevant one, the other ones weren't wanted.

mih commented 5 years ago

That can be approximated (xyztdtype), but in general DICOM metadata (even in its simplest form) should have information that makes selection possible in a variety of other ways. If you can point out an example (private channel, if needed), we could have a look.

bpoldrack commented 5 years ago

Sorry, @TobiasKadelka , my response somehow wasn't send. Trying again ...

First off, the size of the niftii images cannot be a criteria in the sense of the rule system to deduce a specification (i.e. the BIDS terms in it) from the DICOMS, simply because there is no niftii yet. So, this would need to be injected in the conversion routine itself. Generally possible, since for the conversion you can define a list of procedures to execute. So an additional procedure after the conversion from DICOM to Nifti could possibly deal with that. However, this might be difficult to implement, since the converted files to need to go somewhere and you want to avoid to end up with the same path. And by default that path is the BIDS compliant one and there you go: circular logic. Better to distinguish them before the conversion. And finally, file size is likely to be a "derivative criteria" anyway as Michael pointed out. The actual reasoning behind it certainly isn't about the file size, but data type, scan length, etc. which might lead to bigger files. This should be made explicit and based on what you know about the DICOMS instead.

From my point of view, this needs double-checking with whoever told you to select based on size, to figure out, what it is about and come up with a better criteria.