Skip to content

[ENH]: BEP046, diffusion tractography#2333

Draft
arokem wants to merge 1 commit intobids-standard:masterfrom
arokem:bep046
Draft

[ENH]: BEP046, diffusion tractography#2333
arokem wants to merge 1 commit intobids-standard:masterfrom
arokem:bep046

Conversation

@arokem
Copy link
Collaborator

@arokem arokem commented Jan 31, 2026

Starting to port over information from https://docs.google.com/document/d/1ubDQ2RhgjnfGqoeukzEkPV9YEHhfYMERrj7-3b0c2HI/edit?tab=t.0

Note

We meet regularly to discuss this BEP at the IST Standardization Unit
Please reach out to @arokem ([email protected]) if you would like to join these meetings, which usually occur on the last Friday of each month at 7:30 AM PT.

@codecov
Copy link

codecov bot commented Jan 31, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 82.81%. Comparing base (1fd10bb) to head (0e0f759).

Additional details and impacted files
@@           Coverage Diff           @@
##           master    #2333   +/-   ##
=======================================
  Coverage   82.81%   82.81%           
=======================================
  Files          22       22           
  Lines        1693     1693           
=======================================
  Hits         1402     1402           
  Misses        291      291           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@kabilar
Copy link
Member

kabilar commented Feb 3, 2026

Hi @arokem and @francopestilli,

I hope you are well.

We are getting ready to release data from our NIH BRAIN CONNECTS UM1 and are reviewing BEP046. Prior to reviewing BEP046, our plan was to release the tractography data as TRK files since that is the format we use throughout most of our processing pipelines.

I see that the plan for BEP046 is to only support TRX files. We would like you to reconsider also supporting TRK files.

From our perspective, TRK and TCK represent the most widely used tractography formats. We believe BEP046 would benefit from supporting these established formats, similar to how the BIDS microscopy spec supports multiple formats (PNG, TIFF, OME-TIFF, and OME-Zarr), even through OME-Zarr appears to be the most cutting-edge option. Presumably the choice of the NIfTI format for neuroimaging data in the BIDS spec was much easier as that had been the most commonly used format for many years. Perhaps once the microscopy and tractography worlds settle on their respective formats the BIDS spec could support a single format, but in the meantime it would be beneficial to support the most commonly used formats.

Additionally, I am unclear as to why the need to use TRK version 2 as outlined in the Google Doc is a 'non-starter' and would appreciate clarification on this point.

Thanks for considering and I would be happy to join your working group meetings to discuss further.

cc @satra @ayendiki

@arokem arokem mentioned this pull request Feb 4, 2026
@arokem
Copy link
Collaborator Author

arokem commented Feb 4, 2026

Hi @kabilar: thanks for contributing to this discussion! I would also suggest to read this discussion that led to the development of TRX: nipy/nibabel#942 and the document that laid out the initial plans for its specification: https://docs.google.com/document/d/1GOOlG42rB7dlJizu2RfaF5XNj_pIaVl_6rtBSUhsgbE/edit?tab=t.0#heading=h.c6igqydj1hrf. For obvious reasons, BIDS has traditionally been quite resistant to proliferation of file formats, where that can be avoided. I believe that it can be avoided here, while TRX offers a good set of features for the community to work with and growing software support (now in Python, C++, Javascript, and even Pascal!). In the meanwhile, I will separately send you information about the meetings of the IST Standardization Unit, so you can join the conversation there.

@ayendiki
Copy link

ayendiki commented Feb 4, 2026 via email

@arokem
Copy link
Collaborator Author

arokem commented Feb 4, 2026

Surfice already supports TRX (though it seems to be a while since a release was made.) DSI Studio and MRTRIX will both be supporting trx in the near future (e.g., see PR and PR). MI-Brain eventually too, according to my understanding, but I don't exactly know what the status of support for TRX is there. Niivue opens up the possibility to relatively easily design a variety of tools for specific uses. I think that brainlife uses niivue for some of their tools, so it's possible that they already have some tools for editing tractograms in TRX (@francopestilli, can you comment?)

I realize that I forgot to cc @bids-standard/bep046 when posting this PR originally. I hope that others in that team can chime in as well.

@ayendiki
Copy link

ayendiki commented Feb 4, 2026 via email

@arokem
Copy link
Collaborator Author

arokem commented Feb 4, 2026

What are the tools that users you are referring to currently using with trk and tck files?

I forgot to mention that @mattcieslak has already implemented TRX reading for ITK (PR), so I believe that should cover some more tools (e.g., 3D slicer, I think? Maybe also Freeview? There's also a browser-based freeview that should already read/write TRX thanks to niivue)

@ayendiki
Copy link

ayendiki commented Feb 4, 2026 via email

@mattcieslak
Copy link
Contributor

You'd be able to do this in DSI Studio after frankyeh/DSI-Studio#114 is approved

@ayendiki
Copy link

ayendiki commented Feb 4, 2026 via email

@francopestilli
Copy link
Collaborator

francopestilli commented Feb 6, 2026

@ayendiki Is this repository helpful? https://github.com/tee-ar-ex/trx-python
You should be able to find example code to load TRX and r/w TEX, TRK

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants