Questions about dirorder

Hi MRTrix-ers,

Hope you guys are doing well.

I would like to use dirorder to downsampling angular resolution from a multi-shell high-angular-resolution dwi. However when I used

dirorder bvecs reorder_bvecs

this command returned [ERROR] unexpected number of columns for directions file “bvecs”. But my bvecs can be successfully recognized by “dirstat”. So I need you help. Thank you very much.

Best regards,
Rui

Apologies, dirorder is indeed not very well documented. It expects as input either a 2-column matrix of [ az el ] pairs, or a 3-column matrix of [ x y z ] triplets (one row per direction). The latter is effectively the transpose of the bvecs¹.

Also, just in case: note that this implies that the directions you’re providing correspond to a single shell. You can’t provide all the directions for a multi-shell scheme and expect the output to be sensible, it won’t know which direction belongs to which shell…


¹ bearing in mind that the bvecs are defined with respect to the image axes, not the scanner / world frame as would typically be expected for MRtrix applications – though this shouldn’t make any difference here.