Skip to content

Commit adff0f5

Browse files
fix: update TIFF compression from zlib to jpeg in tests for consistency
1 parent 5bbc4d9 commit adff0f5

2 files changed

Lines changed: 6 additions & 2 deletions

File tree

pyproject.toml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@ requires-python = ">=3.12"
2121
dependencies = [
2222
"numpy",
2323
"tifffile",
24+
"imagecodecs",
2425
"czifile",
2526
"zarr",
2627
"dask[array]",

tests/test_omio.py

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -297,7 +297,7 @@ def test_read_tif_paginated_returns_lists_and_contains_expected_xy_shapes(tmp_pa
297297
options = dict(
298298
photometric='rgb',
299299
tile=(16, 16),
300-
compression='zlib',
300+
compression='jpeg',
301301
resolutionunit='CENTIMETER',
302302
maxworkers=2)
303303
tif.write(
@@ -322,6 +322,9 @@ def test_read_tif_paginated_returns_lists_and_contains_expected_xy_shapes(tmp_pa
322322

323323
images, metadatas = read_tif(str(f), verbose=False)
324324

325+
# # for this test function, we clear the captured output:
326+
# capsys.readouterr()
327+
325328
assert not isinstance(images, list)
326329
assert metadatas["axes"] == "TZCYX"
327330
assert images.shape[-2:] == (20, 20)
@@ -1741,7 +1744,7 @@ def _write_pyramid_ome_tif(path: Path, shape=(8, 2, 20, 20, 3), subresolutions=2
17411744
options = dict(
17421745
photometric="rgb",
17431746
tile=(16, 16),
1744-
compression="zlib",
1747+
compression="jpeg",
17451748
resolutionunit="CENTIMETER",
17461749
maxworkers=2,
17471750
)

0 commit comments

Comments
 (0)