taigw / brats17

Brain tumor segmentation for MICCAI 2017 BraTS challenge
BSD 3-Clause "New" or "Revised" License
324 stars 130 forks source link

Missing appropriate orientation and origin for prediction results #1

Closed fordanic closed 6 years ago

fordanic commented 6 years ago

When running test.py the saved prediction results are missing appropriate orientation and origin since the output files are initiated with eye(4). This will cause issues when viewing the image data and the segmentation masks in most viewing software. Suggestion would be to remember the orientation and origin from the image volumes and to use this when initiating the output files, e.g. use img.get_affine() when reading the image data.

taigw commented 6 years ago

Thanks for your suggestion. I have fixed this issue by copying the orientation and origin information of the input image to the segmentation output.