Skip to content
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

Re-spacing of Prostate dataset to take 80x80x80 patches #4

Open
Neo2854 opened this issue Jan 2, 2023 · 4 comments
Open

Re-spacing of Prostate dataset to take 80x80x80 patches #4

Neo2854 opened this issue Jan 2, 2023 · 4 comments

Comments

@Neo2854
Copy link

Neo2854 commented Jan 2, 2023

I am trying to reproduce the results for prostate dataset. But i am unable to do it because of below issue.

In one of the issue you told that, after re-spacing, the shape of the MRI volumes is around [256, 256, 128]. I didn't get this. Can you just tell how the re-spacing is done exactly?

@HongzhengYang
Copy link
Collaborator

Hi, thanks for your question. Since the in/through plane resolution for each case is different, you need to assign different spacing size for each case to make the volume shape [256,256,128]. So you can define the volume shape first and calculate the spacing size for each case to make the spacing_size*volume_size constant after re-spacing.

@indranarendra
Copy link

I also have the same doubt. In the prostate dataset, each image volume is of a different shape.

For example, when I'm doing preprocessing using your code, one image volume of shape [40, 384, 384] is converted into
[25, 384, 384, 3]. How can we convert this into [256, 256, 128]?

@Neo2854
Copy link
Author

Neo2854 commented Jan 3, 2023

I am also struggling with the same problem. The thing is i don't know much about medical images.

@HongzhengYang
Copy link
Collaborator

You can follow this (https://github.com/amanbasu/3d-prostate-segmentation/blob/master/resizing.py) to re-size the 3D volume.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants