Skip to content

Commit

Permalink
Merge pull request dipy#1684 from skoudoro/issue-1679-target-lb
Browse files Browse the repository at this point in the history
[FIX] testing line-based target function
  • Loading branch information
arokem authored Dec 11, 2018
2 parents 52cb7c6 + 8318aa7 commit bec8163
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions dipy/tracking/tests/test_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -269,8 +269,10 @@ def _target(target_f, streamlines, voxel_both_true, voxel_one_true,
assert_raises(ValueError, list, new)

# Test smaller voxels
affine = np.random.random((4, 4)) - .5
affine[3] = [0, 0, 0, 1]
affine = np.array([[.3, 0, 0, 0],
[0, .2, 0, 0],
[0, 0, .4, 0],
[0, 0, 0, 1]])
streamlines = list(move_streamlines(streamlines, affine))
new = list(target_f(streamlines, mask, affine=affine))
assert_equal(len(new), 1)
Expand Down

0 comments on commit bec8163

Please sign in to comment.