diff --git a/README.md b/README.md index bfb3724..d6d929d 100644 --- a/README.md +++ b/README.md @@ -78,7 +78,7 @@ Conformance for validating OME-Zarr data and metadata can be tested at several l ### parse_attributes These cases exercise levels 1 and 2 validation; -whether a single Zarr attributes object containing OME-Zarr can be represented and validated. +whether a single Zarr attributes object containing OME-Zarr metadata can be represented and validated. See [cases/parse_attributes/README.md](./cases/parse_attributes/README.md) for more details. diff --git a/cases/validate_zarr/v0.6/core/valid/well/minimal_acquisitions.ome.zarr/0/0/zarr.json b/cases/validate_zarr/v0.6/core/invalid/well/duplicate_images.ome.zarr/0/0/zarr.json similarity index 100% rename from cases/validate_zarr/v0.6/core/valid/well/minimal_acquisitions.ome.zarr/0/0/zarr.json rename to cases/validate_zarr/v0.6/core/invalid/well/duplicate_images.ome.zarr/0/0/zarr.json diff --git a/cases/validate_zarr/v0.6/core/valid/well/minimal_acquisitions.ome.zarr/0/zarr.json b/cases/validate_zarr/v0.6/core/invalid/well/duplicate_images.ome.zarr/0/zarr.json similarity index 100% rename from cases/validate_zarr/v0.6/core/valid/well/minimal_acquisitions.ome.zarr/0/zarr.json rename to cases/validate_zarr/v0.6/core/invalid/well/duplicate_images.ome.zarr/0/zarr.json diff --git a/cases/validate_zarr/v0.6/core/invalid/well/duplicate_images.ome.zarr/zarr.json b/cases/validate_zarr/v0.6/core/invalid/well/duplicate_images.ome.zarr/zarr.json index 7749c53..83767b3 100644 --- a/cases/validate_zarr/v0.6/core/invalid/well/duplicate_images.ome.zarr/zarr.json +++ b/cases/validate_zarr/v0.6/core/invalid/well/duplicate_images.ome.zarr/zarr.json @@ -1,14 +1,17 @@ { "attributes": { - "well": { - "images": [ - { - "path": "0" - }, - { - "path": "0" - } - ] + "ome": { + "version": "0.6", + "well": { + "images": [ + { + "path": "0" + }, + { + "path": "0" + } + ] + } } }, "node_type": "group", diff --git a/cases/validate_zarr/v0.6/core/invalid/well/empty_images.ome.zarr/zarr.json b/cases/validate_zarr/v0.6/core/invalid/well/empty_images.ome.zarr/zarr.json index b2c7bcd..10ed97a 100644 --- a/cases/validate_zarr/v0.6/core/invalid/well/empty_images.ome.zarr/zarr.json +++ b/cases/validate_zarr/v0.6/core/invalid/well/empty_images.ome.zarr/zarr.json @@ -1,7 +1,10 @@ { "attributes": { - "well": { - "images": [] + "ome": { + "version": "0.6", + "well": { + "images": [] + } } }, "node_type": "group", diff --git a/cases/validate_zarr/v0.6/core/invalid/well/forbidden_path_1.ome.zarr/0/0/zarr.json b/cases/validate_zarr/v0.6/core/invalid/well/forbidden_path_1.ome.zarr/0/0/zarr.json new file mode 100644 index 0000000..c29b2c3 --- /dev/null +++ b/cases/validate_zarr/v0.6/core/invalid/well/forbidden_path_1.ome.zarr/0/0/zarr.json @@ -0,0 +1,32 @@ +{ + "attributes": {}, + "chunk_grid": { + "configuration": { + "chunk_shape": [ + 10, + 10 + ] + }, + "name": "regular" + }, + "chunk_key_encoding": { + "configuration": { + "separator": "/" + }, + "name": "default" + }, + "codecs": [ + { + "name": "bytes" + } + ], + "data_type": "uint8", + "fill_value": 0, + "node_type": "array", + "shape": [ + 10, + 10 + ], + "storage_transformers": [], + "zarr_format": 3 +} diff --git a/cases/validate_zarr/v0.6/core/invalid/well/forbidden_path_1.ome.zarr/0/zarr.json b/cases/validate_zarr/v0.6/core/invalid/well/forbidden_path_1.ome.zarr/0/zarr.json new file mode 100644 index 0000000..ff02734 --- /dev/null +++ b/cases/validate_zarr/v0.6/core/invalid/well/forbidden_path_1.ome.zarr/0/zarr.json @@ -0,0 +1,50 @@ +{ + "attributes": { + "ome": { + "multiscales": [ + { + "coordinateSystems": [ + { + "axes": [ + { + "name": "y", + "type": "space", + "unit": "micrometer" + }, + { + "name": "x", + "type": "space", + "unit": "micrometer" + } + ], + "name": "intrinsic" + } + ], + "datasets": [ + { + "coordinateTransformations": [ + { + "input": { + "path": "0" + }, + "output": { + "name": "intrinsic" + }, + "scale": [ + 1, + 1 + ], + "type": "scale" + } + ], + "path": "0" + } + ] + } + ], + "version": "0.6" + } + }, + "node_type": "group", + "zarr_format": 3 +} diff --git a/cases/validate_zarr/v0.6/core/invalid/well/forbidden_path_1.ome.zarr/zarr.json b/cases/validate_zarr/v0.6/core/invalid/well/forbidden_path_1.ome.zarr/zarr.json new file mode 100644 index 0000000..dbbd70d --- /dev/null +++ b/cases/validate_zarr/v0.6/core/invalid/well/forbidden_path_1.ome.zarr/zarr.json @@ -0,0 +1,16 @@ +{ + "attributes": { + "ome": { + "version": "0.6", + "well": { + "images": [ + { + "path": "." + } + ] + } + } + }, + "node_type": "group", + "zarr_format": 3 +} diff --git a/cases/validate_zarr/v0.6/core/invalid/well/forbidden_path_2.ome.zarr/0/0/zarr.json b/cases/validate_zarr/v0.6/core/invalid/well/forbidden_path_2.ome.zarr/0/0/zarr.json new file mode 100644 index 0000000..c29b2c3 --- /dev/null +++ b/cases/validate_zarr/v0.6/core/invalid/well/forbidden_path_2.ome.zarr/0/0/zarr.json @@ -0,0 +1,32 @@ +{ + "attributes": {}, + "chunk_grid": { + "configuration": { + "chunk_shape": [ + 10, + 10 + ] + }, + "name": "regular" + }, + "chunk_key_encoding": { + "configuration": { + "separator": "/" + }, + "name": "default" + }, + "codecs": [ + { + "name": "bytes" + } + ], + "data_type": "uint8", + "fill_value": 0, + "node_type": "array", + "shape": [ + 10, + 10 + ], + "storage_transformers": [], + "zarr_format": 3 +} diff --git a/cases/validate_zarr/v0.6/core/invalid/well/forbidden_path_2.ome.zarr/0/zarr.json b/cases/validate_zarr/v0.6/core/invalid/well/forbidden_path_2.ome.zarr/0/zarr.json new file mode 100644 index 0000000..ff02734 --- /dev/null +++ b/cases/validate_zarr/v0.6/core/invalid/well/forbidden_path_2.ome.zarr/0/zarr.json @@ -0,0 +1,50 @@ +{ + "attributes": { + "ome": { + "multiscales": [ + { + "coordinateSystems": [ + { + "axes": [ + { + "name": "y", + "type": "space", + "unit": "micrometer" + }, + { + "name": "x", + "type": "space", + "unit": "micrometer" + } + ], + "name": "intrinsic" + } + ], + "datasets": [ + { + "coordinateTransformations": [ + { + "input": { + "path": "0" + }, + "output": { + "name": "intrinsic" + }, + "scale": [ + 1, + 1 + ], + "type": "scale" + } + ], + "path": "0" + } + ] + } + ], + "version": "0.6" + } + }, + "node_type": "group", + "zarr_format": 3 +} diff --git a/cases/validate_zarr/v0.6/core/invalid/well/forbidden_path_2.ome.zarr/zarr.json b/cases/validate_zarr/v0.6/core/invalid/well/forbidden_path_2.ome.zarr/zarr.json new file mode 100644 index 0000000..a1a8803 --- /dev/null +++ b/cases/validate_zarr/v0.6/core/invalid/well/forbidden_path_2.ome.zarr/zarr.json @@ -0,0 +1,16 @@ +{ + "attributes": { + "ome": { + "version": "0.6", + "well": { + "images": [ + { + "path": ".." + } + ] + } + } + }, + "node_type": "group", + "zarr_format": 3 +} diff --git a/cases/validate_zarr/v0.6/core/invalid/well/forbidden_path_3.ome.zarr/0/0/zarr.json b/cases/validate_zarr/v0.6/core/invalid/well/forbidden_path_3.ome.zarr/0/0/zarr.json new file mode 100644 index 0000000..c29b2c3 --- /dev/null +++ b/cases/validate_zarr/v0.6/core/invalid/well/forbidden_path_3.ome.zarr/0/0/zarr.json @@ -0,0 +1,32 @@ +{ + "attributes": {}, + "chunk_grid": { + "configuration": { + "chunk_shape": [ + 10, + 10 + ] + }, + "name": "regular" + }, + "chunk_key_encoding": { + "configuration": { + "separator": "/" + }, + "name": "default" + }, + "codecs": [ + { + "name": "bytes" + } + ], + "data_type": "uint8", + "fill_value": 0, + "node_type": "array", + "shape": [ + 10, + 10 + ], + "storage_transformers": [], + "zarr_format": 3 +} diff --git a/cases/validate_zarr/v0.6/core/invalid/well/forbidden_path_3.ome.zarr/0/zarr.json b/cases/validate_zarr/v0.6/core/invalid/well/forbidden_path_3.ome.zarr/0/zarr.json new file mode 100644 index 0000000..ff02734 --- /dev/null +++ b/cases/validate_zarr/v0.6/core/invalid/well/forbidden_path_3.ome.zarr/0/zarr.json @@ -0,0 +1,50 @@ +{ + "attributes": { + "ome": { + "multiscales": [ + { + "coordinateSystems": [ + { + "axes": [ + { + "name": "y", + "type": "space", + "unit": "micrometer" + }, + { + "name": "x", + "type": "space", + "unit": "micrometer" + } + ], + "name": "intrinsic" + } + ], + "datasets": [ + { + "coordinateTransformations": [ + { + "input": { + "path": "0" + }, + "output": { + "name": "intrinsic" + }, + "scale": [ + 1, + 1 + ], + "type": "scale" + } + ], + "path": "0" + } + ] + } + ], + "version": "0.6" + } + }, + "node_type": "group", + "zarr_format": 3 +} diff --git a/cases/validate_zarr/v0.6/core/invalid/well/forbidden_path_3.ome.zarr/zarr.json b/cases/validate_zarr/v0.6/core/invalid/well/forbidden_path_3.ome.zarr/zarr.json new file mode 100644 index 0000000..7194a77 --- /dev/null +++ b/cases/validate_zarr/v0.6/core/invalid/well/forbidden_path_3.ome.zarr/zarr.json @@ -0,0 +1,16 @@ +{ + "attributes": { + "ome": { + "version": "0.6", + "well": { + "images": [ + { + "path": "__something" + } + ] + } + } + }, + "node_type": "group", + "zarr_format": 3 +} diff --git a/cases/validate_zarr/v0.6/core/invalid/well/forbidden_path_4.ome.zarr/0/0/zarr.json b/cases/validate_zarr/v0.6/core/invalid/well/forbidden_path_4.ome.zarr/0/0/zarr.json new file mode 100644 index 0000000..c29b2c3 --- /dev/null +++ b/cases/validate_zarr/v0.6/core/invalid/well/forbidden_path_4.ome.zarr/0/0/zarr.json @@ -0,0 +1,32 @@ +{ + "attributes": {}, + "chunk_grid": { + "configuration": { + "chunk_shape": [ + 10, + 10 + ] + }, + "name": "regular" + }, + "chunk_key_encoding": { + "configuration": { + "separator": "/" + }, + "name": "default" + }, + "codecs": [ + { + "name": "bytes" + } + ], + "data_type": "uint8", + "fill_value": 0, + "node_type": "array", + "shape": [ + 10, + 10 + ], + "storage_transformers": [], + "zarr_format": 3 +} diff --git a/cases/validate_zarr/v0.6/core/invalid/well/forbidden_path_4.ome.zarr/0/zarr.json b/cases/validate_zarr/v0.6/core/invalid/well/forbidden_path_4.ome.zarr/0/zarr.json new file mode 100644 index 0000000..ff02734 --- /dev/null +++ b/cases/validate_zarr/v0.6/core/invalid/well/forbidden_path_4.ome.zarr/0/zarr.json @@ -0,0 +1,50 @@ +{ + "attributes": { + "ome": { + "multiscales": [ + { + "coordinateSystems": [ + { + "axes": [ + { + "name": "y", + "type": "space", + "unit": "micrometer" + }, + { + "name": "x", + "type": "space", + "unit": "micrometer" + } + ], + "name": "intrinsic" + } + ], + "datasets": [ + { + "coordinateTransformations": [ + { + "input": { + "path": "0" + }, + "output": { + "name": "intrinsic" + }, + "scale": [ + 1, + 1 + ], + "type": "scale" + } + ], + "path": "0" + } + ] + } + ], + "version": "0.6" + } + }, + "node_type": "group", + "zarr_format": 3 +} diff --git a/cases/validate_zarr/v0.6/core/invalid/well/forbidden_path_4.ome.zarr/zarr.json b/cases/validate_zarr/v0.6/core/invalid/well/forbidden_path_4.ome.zarr/zarr.json new file mode 100644 index 0000000..43c8f03 --- /dev/null +++ b/cases/validate_zarr/v0.6/core/invalid/well/forbidden_path_4.ome.zarr/zarr.json @@ -0,0 +1,16 @@ +{ + "attributes": { + "ome": { + "version": "0.6", + "well": { + "images": [ + { + "path": "!@#$%^&*()+={}[]" + } + ] + } + } + }, + "node_type": "group", + "zarr_format": 3 +} diff --git a/cases/validate_zarr/v0.6/core/invalid/well/non_integer_acquisition_id.ome.zarr/A/1/0/0/zarr.json b/cases/validate_zarr/v0.6/core/invalid/well/non_integer_acquisition_id.ome.zarr/A/1/0/0/zarr.json new file mode 100644 index 0000000..c29b2c3 --- /dev/null +++ b/cases/validate_zarr/v0.6/core/invalid/well/non_integer_acquisition_id.ome.zarr/A/1/0/0/zarr.json @@ -0,0 +1,32 @@ +{ + "attributes": {}, + "chunk_grid": { + "configuration": { + "chunk_shape": [ + 10, + 10 + ] + }, + "name": "regular" + }, + "chunk_key_encoding": { + "configuration": { + "separator": "/" + }, + "name": "default" + }, + "codecs": [ + { + "name": "bytes" + } + ], + "data_type": "uint8", + "fill_value": 0, + "node_type": "array", + "shape": [ + 10, + 10 + ], + "storage_transformers": [], + "zarr_format": 3 +} diff --git a/cases/validate_zarr/v0.6/core/invalid/well/non_integer_acquisition_id.ome.zarr/A/1/0/zarr.json b/cases/validate_zarr/v0.6/core/invalid/well/non_integer_acquisition_id.ome.zarr/A/1/0/zarr.json new file mode 100644 index 0000000..ff02734 --- /dev/null +++ b/cases/validate_zarr/v0.6/core/invalid/well/non_integer_acquisition_id.ome.zarr/A/1/0/zarr.json @@ -0,0 +1,50 @@ +{ + "attributes": { + "ome": { + "multiscales": [ + { + "coordinateSystems": [ + { + "axes": [ + { + "name": "y", + "type": "space", + "unit": "micrometer" + }, + { + "name": "x", + "type": "space", + "unit": "micrometer" + } + ], + "name": "intrinsic" + } + ], + "datasets": [ + { + "coordinateTransformations": [ + { + "input": { + "path": "0" + }, + "output": { + "name": "intrinsic" + }, + "scale": [ + 1, + 1 + ], + "type": "scale" + } + ], + "path": "0" + } + ] + } + ], + "version": "0.6" + } + }, + "node_type": "group", + "zarr_format": 3 +} diff --git a/cases/validate_zarr/v0.6/core/valid/well/minimal_acquisitions.ome.zarr/zarr.json b/cases/validate_zarr/v0.6/core/invalid/well/non_integer_acquisition_id.ome.zarr/A/1/zarr.json similarity index 87% rename from cases/validate_zarr/v0.6/core/valid/well/minimal_acquisitions.ome.zarr/zarr.json rename to cases/validate_zarr/v0.6/core/invalid/well/non_integer_acquisition_id.ome.zarr/A/1/zarr.json index c2e2011..49e199f 100644 --- a/cases/validate_zarr/v0.6/core/valid/well/minimal_acquisitions.ome.zarr/zarr.json +++ b/cases/validate_zarr/v0.6/core/invalid/well/non_integer_acquisition_id.ome.zarr/A/1/zarr.json @@ -5,7 +5,7 @@ "well": { "images": [ { - "acquisition": 1, + "acquisition": "0", "path": "0" } ] diff --git a/cases/validate_zarr/v0.6/core/invalid/well/non_integer_acquisition_id.ome.zarr/A/zarr.json b/cases/validate_zarr/v0.6/core/invalid/well/non_integer_acquisition_id.ome.zarr/A/zarr.json new file mode 100644 index 0000000..a7d1b29 --- /dev/null +++ b/cases/validate_zarr/v0.6/core/invalid/well/non_integer_acquisition_id.ome.zarr/A/zarr.json @@ -0,0 +1,5 @@ +{ + "attributes": {}, + "node_type": "group", + "zarr_format": 3 +} diff --git a/cases/validate_zarr/v0.6/core/invalid/well/non_integer_acquisition_id.ome.zarr/zarr.json b/cases/validate_zarr/v0.6/core/invalid/well/non_integer_acquisition_id.ome.zarr/zarr.json index 41d610b..1a27880 100644 --- a/cases/validate_zarr/v0.6/core/invalid/well/non_integer_acquisition_id.ome.zarr/zarr.json +++ b/cases/validate_zarr/v0.6/core/invalid/well/non_integer_acquisition_id.ome.zarr/zarr.json @@ -1,12 +1,31 @@ { "attributes": { - "well": { - "images": [ - { - "acquisition": "0", - "path": "0" - } - ] + "ome": { + "plate": { + "acquisitions": [ + { + "id": 0 + } + ], + "columns": [ + { + "name": "1" + } + ], + "rows": [ + { + "name": "A" + } + ], + "wells": [ + { + "columnIndex": 0, + "path": "A/1", + "rowIndex": 0 + } + ] + }, + "version": "0.6" } }, "node_type": "group", diff --git a/pyproject.toml b/pyproject.toml index 827e671..cf10ac8 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,7 +1,7 @@ [project] name = "oztest" version = "0.1.0" -description = "Add your description here" +description = "Conformance test cases and tooling for OME-Zarr" readme = "README.md" authors = [{ name = "Chris Barnes", email = "chris.barnes@gerbi-gmb.de" }] requires-python = ">=3.11,<4.0"