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

DOC: number of seeds per voxel, inconsistent documentation? #330

Closed
mekman opened this Issue Feb 24, 2014 · 2 comments

Comments

Projects
None yet
2 participants
@mekman
Contributor

mekman commented Feb 24, 2014

You guys are amazing! :) Every time I come back to have a look at this project I see major improvements. Very exciting stuff is happening here.

Walking through some of the new examples I noticed this small inconsistency on how to interpret the density parameter in utils.seeds_from_mask().

seeds = utils.seeds_from_mask(mask, density=2)

The docstring states density=2 will result "in a total of 8 seeds per voxel".

The example here tells me that the same code will result in 1 seed per voxel.
https://github.com/nipy/dipy/blob/master/doc/examples/streamline_tools.py#L50

I still have to have a closer look, but I think the later is not correct?

BTW, Congratulations also on the recent publication.

regards,
Matthias

@MrBago

This comment has been minimized.

Contributor

MrBago commented Feb 24, 2014

Sorry for the confusion, the density is best described in the doc-string
for seeds_from_mask:

"""

density : int or array_like (3,)
    Specifies the number of seeds to place along each dimension. A
    ``density`` of `2` is the same as ``[2, 2, 2]`` and will result in a
    total of 8 seeds per voxel.

"""

The example is clearly wrong, I believe we wrote the example intending to
use a density of 1, then changed it to 2 to debug some stuff. That change
should have never been merged into master, thanks for catching it.

Bago

On Mon, Feb 24, 2014 at 10:45 AM, Matthias Ekman
notifications@github.comwrote:

You guys are amazing! :) Every time I come back to have a look at this
project I see major improvements. Very exciting stuff is happening here.

Walking through some of the new examples I noticed this small
inconsistency on how to interpret the density parameter in
utils.seeds_from_mask().

seeds = utils.seeds_from_mask(mask, density=2)

The docstring states density=2 will result "in a total of 8 seeds per
voxel".

The example here tells me that the same code will result in 1 seed per
voxel.

https://github.com/nipy/dipy/blob/master/doc/examples/streamline_tools.py#L50

I still have to have a closer look, but I think the later is not correct?

BTW, Congratulations also on the recent publication.

regards,
Matthias

Reply to this email directly or view it on GitHubhttps://github.com//issues/330
.

@mekman

This comment has been minimized.

Contributor

mekman commented Feb 25, 2014

Thanks a lot for clarifying this!

@mekman mekman closed this Feb 25, 2014

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