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

How to access MIRAX files's image orientation, position and pixel spacing. #318

Open
DanielaSchacherer opened this issue Mar 6, 2025 · 2 comments

Comments

@DanielaSchacherer
Copy link

Slide format

MRXS

Issue details

Hello together,

I am currently converting MIRAX WSI slides that go along with annotations using wsidicomizer (see imi-bigpicture/wsidicomizer#126)

I have bounding boxes that were generated with QuPath using the original MIRAX slides (which means they refer to MIRAX image coordinates: 0,0 at the top-left corner of a pixel). I was thinking the most clean and reproducible way to transfer those annotations to the converted DICOM slides is to use highdicom's ImageToImageTransformer. For that,
I need to extract the orientation (for DICOM ImageOrientationSlide), position (for DICOM TotalPixelMatrixOriginSequence), and pixel spacing (for DICOM SharedFunctionalGroupsSequence[0].PixelMeasuresSequence[0].PixelSpacing).

Since wsidiomizer uses openslide-python for handling MIRAX files, I wondered if you can you tell me how to access orientation, position and pixel spacing from the MIRAX slide.

Best regards,
Daniela

@bgilbert
Copy link
Member

bgilbert commented Mar 7, 2025

Everything OpenSlide knows about MIRAX slide metadata is included in the slide properties. You can get pixel spacing from openslide.mpp-x and openslide.mpp-y. I'm not aware that the MIRAX metadata encodes the other information you're looking for, but you can look through the properties and see if you find anything useful.

@DanielaSchacherer
Copy link
Author

@bgilbert thank you very much for the quick answer. I know about slide properties and that it contains pixel spacing(s). I couldn't find anything about the image orientation and position and was thus hoping that you'd know more.

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

No branches or pull requests

2 participants