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

convert nii.gz to png black image.png #20

Open
hannamraha opened this issue Dec 22, 2021 · 5 comments
Open

convert nii.gz to png black image.png #20

hannamraha opened this issue Dec 22, 2021 · 5 comments

Comments

@hannamraha
Copy link

hannamraha commented Dec 22, 2021

thank you for the code
When I convert the images, I get a black image.png.
I have no idea why i am getting a black picture.
Can anyone help me?
@monjoybme & @alexlaurence
Many Thanks

@monjoybme
Copy link
Contributor

@hannamraha There could be several reasons for this. Please inspect the image to see whether it has any other pixel values. Radiological images have a wide range of grayscale pixels. As a result, there's a possibility that your images' pixel values are very close to ZERO or Black pixel intensity. There might be windowing-related issues as well. If you share an image, I can inspect that.

@hannamraha
Copy link
Author

Thank you for your reply.
Unfortunately I cannot share a picture. The images are MRI and CT.
Data Set Dimensions (voxels) : X:256; Y:256; Z:1.

@monjoybme
Copy link
Contributor

@hannamraha In that case, you have to check if your image contains any pixel values other than ZERO or not. You may try to convert it into binary.

@hannamraha
Copy link
Author

@monjoybme thank you for your message.
Ok.

@monjoybme
Copy link
Contributor

@hannamraha Please close the issue if you are satisfied with the solution.

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

2 participants