imi-bigpicture / wsidicom

Python package for reading DICOM WSI file sets.
Apache License 2.0
34 stars 6 forks source link

Implementing BOT support #31

Closed erikogabrielsson closed 2 years ago

erikogabrielsson commented 2 years ago

When opening a WsiDicomFile the basic offset table (BOT) is parsed for frame offsets and lengths. Parsing of PixelData is used as fallback if BOT is empty. When saving a file (Using WsiDicomFilewriter) a BOT is written.

Parsing of extended offset table is not yet implemented.

erikogabrielsson commented 2 years ago

In addition to comments, if it is common with a broken BOT table, should there be some user option to skip it when reaing a specific file? I will check if it is actually common with broken BOTs. It might be that my previous implementation was the problem... If we do encounter broken BOTs I think we should find a way to fix the problem (i.e. fallback to parsing pixeldata).