-
Notifications
You must be signed in to change notification settings - Fork 71
ENH: better bundle endpoints maps #1047
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
|
Hello @AntoineTheb, Thank you for updating ! There are currently no PEP 8 issues detected in this Pull Request. Cheers! 🍻 Comment last updated at 2024-11-08 16:17:31 UTC |
| point_to_select: int | ||
| Instead of computing the density based on the first and last points, | ||
| select more than one at each end. To support compressed streamlines, | ||
| a resampling to 0.5mm per segment is performed. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Narrator: this actually wasn't performed.
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## master #1047 +/- ##
==========================================
+ Coverage 68.79% 68.89% +0.10%
==========================================
Files 432 434 +2
Lines 22454 22646 +192
Branches 3041 3078 +37
==========================================
+ Hits 15448 15603 +155
- Misses 5706 5727 +21
- Partials 1300 1316 +16
|
| " of the streamlines. [%(default)s]") | ||
| p.add_argument('--mm', action='store_true', | ||
| help='Compute the endpoints in mm instead of nb. of ' | ||
| 'points. Useful for compressed streamlines.') |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think this could be a little clearer. Like, if user adds --mm, but not --nb_points, is it clear to them that it will take 1mm?
Maybe.... If set, the value --nb_points will instead be understood as the length, in mm. But I'm not sure that's perfect either.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
How about now ?
arnaudbore
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
Quick description
This PR improves bundle endpoint maps computation. Before, the map was only computed on streamline points exactly, which may be problematic if the step size is too large (see fig. 1 for ref). Now, the map includes every voxel traversed by the endpoints (however many points are selected). Moreover, the user can now select
nmillimeters instead of points, which makes much more sense when dealing with compressed streamlines.Breaking change: the arguments of
scil_bundle_compute_endpoint_maps.pyare now slightly different.Type of change
Check the relevant options.
Provide data, screenshots, command line to test (if relevant)
Fig 1.: Before, 3 points
Fig. 2: After, 3 points
Fig. 3: After, 10mm.
Checklist