-
Notifications
You must be signed in to change notification settings - Fork 42
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
create_sphere uses MNI152_2mm template even when given mask #122
Comments
@jnecus: do you mind sharing your t1_image so we can try to fix this bug. Maybe a dropbox link, or on neurovault? |
Sure, here's a link |
Thanks @jnecus. You definitely helped us identify a couple of previously undetected bugs. We mostly use our tools on normalized data. I just pushed a fix for this bug and think it should work now #123. Though you'll have to install from github. One important thing to note is that the mask really does need to be a mask not just any nibabel instance. For your use case, you need to create a mask of your T1. Personally, I would create a mask using the skull stripped data. Here is example code using bet from fsl |
Thanks @ljchang , I downloaded the latest version from github and it works fine. Rather than using the skull stripped image I used a mask image which was the same size as my t1_w, but filled exclusively with 1's. This is because I wanted to create a spherical roi which falls outside of the brain. On that note, could you explain to be the need to include a mask in a function of which the role is ultimately to generate a mask. I cannot seems to grasp the use for this mask option? |
@jnecus: you need to pass a mask in so the function knows the space to build the rois. You're right though, that it actually doesn't need to be a mask. It could have been your original T1. It only uses the mask to get the dimensions of the image. |
The resulting mask shape does not match that of my provided mask (in this case t1_image)
Here is my code:
Results:
t1_image.shape
(180,256,256)mask.shape
(91,109,91)The text was updated successfully, but these errors were encountered: