Skip to content

Limit file extension test

INFO programm version: 1.4.0 INFO bids version: 1.2.0

At the moment, all file extensions are tested in bidsme.Modules.base (MRI/hmriNIFTI), leading to a huge amount of non interesting DEBUG info when testing json files, for example:

bidsme.Modules.base(302) - DEBUG MRI/hmriNIFTI: Testing file /home/ghammad/Work/CogNap_BIDSME/prepared/sub-COGNAP007/ses-V3/MRI/018-cmrr_mbep2d_bold_mb2_rest/f1973-0018-00048-000048-01.json
bidsme.Modules.base(322) - DEBUG MRI/hmriNIFTI: Unaccepted extention

Would it be possible to restrict, via passing arguments to bidsme, to restrict the file extensions to be tested.

Ex:

bidsme.init(file_ext=['.nii'])

or in the specific bidsme.prepare function. Whatever works best.

This would suppress around 2500 x 2 lines of useless log debug info from my logs...

Edited by Grégory Hammad