Any way to convert the track.tck file to fixel vectors?

Dear all,

Is there any way to calculate fixels direction file from track.tck file?


Hi Zifei,

I’ll interpret your question as best I can, but I can’t guarantee that I’m correctly interpreting what you’re looking for based on the brevity of the question.

If I assume that the only information you have as input is:

  • a track file;
  • by necessity, also a template image voxel grid;

, and what you are looking to generate is:

  • a fixel directions file;
  • by necessity, also a fixel index file (since a directions file in isolation means nothing; it would be quite strange to already have an index file but simply want to change an existing directions file based on streamlines information)

, then the only thing I’m aware of that kind of resembles this idea is one of the intermediate stages of this tractogram clustering method from way back during my PhD. It’s not described as “fixels” because that term hadn’t been invented yet, but it was nevertheless a determination of the number and directions of discrete fixels in each image voxel based on the tangents of streamlines intersecting each voxel.

This is ooooold code and is nowhere to be seen in MRtrix3; but it might nevertheless get your noggin’ joggin’ in terms of what you’re actually trying to achieve.

Of course if I’m way off the mark, you’ll need to elaborate further.


Hey Zifei,

This is pretty straightforward; I’ve had this question come up recently even a few times for different people: you can first create a track orientation distribution (TOD) image from the track .tck file, and then simply run fod2fixel on this. Only thing to take into account is that the TOD amplitudes (in magnitude) might live in a different range than your average typical FOD image. Take this into account by using the -fmls_peak_value option with fod2fixel, yet provide your own experimental thresholds. These will depend on how many streamlines are in your .tck file in each voxel. Start with a very low value (e.g. -fmls_peak_value 1) to test, for a normally dense tractogram. Increase from there if the fixel image is too noisy, with too many fixels reflecting spurious streamlines, or decrease if you’re missing bits. So in summary, something like this goes:

tckmap track.tck tod.mif -tod 8 -template template.mif

The template.mif can be any image: it’s voxel grid will be used to map the TOD, and in the next step also the fixels on. If you don’t have an image for which you want to use the existing voxel grid, a voxel grid will still have to come from somewhere of course. You can alternatively supply the -vox option to this command to define a voxel size then, and it’ll generate a new voxel grid for you.

You can then open this TOD image in the ODF viewer tool in mrview to check, but you’ll have to likely scale it down (in the viewer), as the TOD ODFs might look massive. So it’ll look a bit like FODs, but only for your streamlines.


fod2fixel tod.mif fixelfolder -fmls_peak_value 1

That’ll generate a fresh fixel folder with index.mif and directions.mif, based on the TOD that derived from the .tck tractogram in the step before.

If you need some background info on TOD images, or a reference for this step; see this one: .

Feel free to provide a screenshot of your output if you want it checked. I’ve done this just recently; very straightforward and I know what to expect to see as output. Lots of people who want to check their quantitative tractograms these days.

Cheers & all the best,

OK, Thanks a lot. I will try this. This is pretty useful to me.

Thanks, all.