@@ -40,13 +40,13 @@ def get_data_dims(volume):
4040
4141
4242def transform_to_affine (streams , header , affine ):
43- from dipy .tracking .utils import move_streamlines
43+ from dipy .tracking .utils import transform_tracking_output
4444
4545 rotation , scale = np .linalg .qr (affine )
46- streams = move_streamlines (streams , rotation )
46+ streams = transform_tracking_output (streams , rotation )
4747 scale [0 :3 , 0 :3 ] = np .dot (scale [0 :3 , 0 :3 ], np .diag (1.0 / header ["voxel_size" ]))
4848 scale [0 :3 , 3 ] = abs (scale [0 :3 , 3 ])
49- streams = move_streamlines (streams , scale )
49+ streams = transform_tracking_output (streams , scale )
5050 return streams
5151
5252
@@ -193,7 +193,10 @@ class MRTrix2TrackVis(DipyBaseInterface):
193193 output_spec = MRTrix2TrackVisOutputSpec
194194
195195 def _run_interface (self , runtime ):
196- from dipy .tracking .utils import move_streamlines , affine_from_fsl_mat_file
196+ from dipy .tracking .utils import (
197+ affine_from_fsl_mat_file ,
198+ transform_tracking_output ,
199+ )
197200
198201 dx , dy , dz = get_data_dims (self .inputs .image_file )
199202 vx , vy , vz = get_vox_dims (self .inputs .image_file )
@@ -243,7 +246,7 @@ def _run_interface(self, runtime):
243246 axcode = aff2axcodes (reg_affine )
244247 trk_header ["voxel_order" ] = axcode [0 ] + axcode [1 ] + axcode [2 ]
245248
246- final_streamlines = move_streamlines (transformed_streamlines , aff )
249+ final_streamlines = transform_tracking_output (transformed_streamlines , aff )
247250 trk_tracks = ((ii , None , None ) for ii in final_streamlines )
248251 trk .write (out_filename , trk_tracks , trk_header )
249252 iflogger .info ("Saving transformed Trackvis file as %s" , out_filename )
0 commit comments