SlicerDMRI / whitematteranalysis

White matter tractography clustering and more...
https://dmri.slicer.org/whitematteranalysis/
Other
69 stars 34 forks source link

ENH: Add streamline concatenation script #150

Closed jhlegarreta closed 1 year ago

jhlegarreta commented 1 year ago

Add streamline concatenation script and the necessary methods into the appropriate module.

jhlegarreta commented 1 year ago

These 2 scripts may be doing exactly what is proposed here: https://github.com/SlicerDMRI/whitematteranalysis/blob/master/bin/wm_append_clusters_to_anatomical_tracts.py https://github.com/SlicerDMRI/whitematteranalysis/blob/master/bin/wm_append_clusters.py

Maybe they can be refactored so that the "append" operation can be reused across modules.

jhlegarreta commented 1 year ago

OK, so wm_append_clusters.py does this job (thanks Fan); the point-wise data is also preserved; the only scalar that is not preserved is the cluster idx, which is generated again and considers each tractogram as one cluster (whereas each input tractogram may contain different clusters). Refactoring the concatenation/append operation into a method is left for future work. So closing the PR for now.