diff --git a/test/data/sample.subifd.ome.tif.sha512 b/test/data/sample.subifd.ome.tif.sha512 new file mode 100755 index 000000000..e4774c67d --- /dev/null +++ b/test/data/sample.subifd.ome.tif.sha512 @@ -0,0 +1 @@ +35ec252c94b1ad0b9d5bd42c89c1d15c83065d6734100d6f596237ff36e8d4495bcfed2c9ea24ab0b4a35aef59871da429dbd48faf0232219dc4391215ba59ce diff --git a/test/test_source_ometiff.py b/test/test_source_ometiff.py index e02761bd0..2dbd267d9 100644 --- a/test/test_source_ometiff.py +++ b/test/test_source_ometiff.py @@ -29,6 +29,24 @@ def testTilesFromOMETiff(): utilities.checkTilesZXY(source, tileMetadata) +def testTilesFromOMETiffWithSubIFD(): + imagePath = utilities.externaldata('data/sample.subifd.ome.tif.sha512') + source = large_image_source_ometiff.OMETiffFileTileSource(imagePath) + tileMetadata = source.getMetadata() + + assert tileMetadata['tileWidth'] == 256 + assert tileMetadata['tileHeight'] == 256 + assert tileMetadata['sizeX'] == 2106 + assert tileMetadata['sizeY'] == 2016 + assert tileMetadata['levels'] == 5 + assert len(tileMetadata['frames']) == 3 + assert tileMetadata['frames'][1]['Frame'] == 1 + assert tileMetadata['frames'][1]['Index'] == 0 + assert tileMetadata['frames'][1]['IndexC'] == 1 + assert tileMetadata['IndexRange'] == {'IndexC': 3} + utilities.checkTilesZXY(source, tileMetadata) + + def testTilesFromStripOMETiff(): imagePath = utilities.externaldata('data/DDX58_AXL_EGFR_well2_XY01.ome.tif.sha512') source = large_image_source_ometiff.OMETiffFileTileSource(imagePath)