glencoesoftware / raw2ometiff

Raw format to OME-TIFF converter
GNU General Public License v2.0
46 stars 20 forks source link

Lower resolution levels images to small #70

Closed JohanDore closed 2 years ago

JohanDore commented 2 years ago

Dear All,

Thanks for making this available. We used your tool on a set of iSyntax images and tested the resulting ome.tiff’s with our reader. The images look good, but we noted that the converter cut a few pixels on the right and bottom border for the lower resolution levels.

E.g a full resolution image of 196613 x 62469 pixel is reduced as: Scale 1::1 196613 x 62469 pixels, Scale 1::2 98304 x 31232 pixels, not 196613/2 x 62469/2 Scale 1::4 49149 x 15613 pixels, again to small Scale 1::8 24572 x 7804 pixels, which is also cut too much Scale 1::16 12284 x3900 pixels, and again a bit of cutting Scale 1::32 6140 x 1948 pixels, likewise here Scale 1::64 3068 x 972 pixels, and here Scale 1::124 1532 x 484 pixels, and also here

It is not a big deal, but we thought you wanted to know

Best regards

Johan

melissalinkert commented 2 years ago

Thanks for mentioning this, @JohanDore. If you used glencoesoftware/isyntax2raw as the first step in the conversion, then I would expect these image sizes to come directly from Philips' iSyntax SDK. Are you using the 1.2.1 or 2.0 version of the SDK?

JohanDore commented 2 years ago

It was version 2.0

melissalinkert commented 2 years ago

I can reproduce similar small differences between the reported XY size for a particular resolution and the expected size for a scale factor of 2. In all cases, the difference is only a few pixels.

I don't know of a way to force Philips' SDK to return pixels padded to the expected XY size, and I suspect we don't want to insert padding pixels on the bottom/right edges. @chris-allan / @muhanadz feel free to re-open if you have any other ideas.