From 0ed70edd3ed699e7b1617050e150d8e0fec996c2 Mon Sep 17 00:00:00 2001 From: "w.pomp" Date: Wed, 22 Jul 2026 15:43:12 +0200 Subject: [PATCH] - small updates --- .gitignore | 5 ++++- Cargo.toml | 2 +- py/ndbioimage/__init__.py | 6 +++++- pyproject.toml | 3 ++- src/py.rs | 4 ++++ 5 files changed, 16 insertions(+), 4 deletions(-) diff --git a/.gitignore b/.gitignore index 8989cbf..c5bd81c 100644 --- a/.gitignore +++ b/.gitignore @@ -74,4 +74,7 @@ docs/_build/ /tests/files/* AGENTS.md -.agentbridge \ No newline at end of file +.agentbridge + +py/ndbioimage/jassets +py/ndbioimage/deps \ No newline at end of file diff --git a/Cargo.toml b/Cargo.toml index daf2713..04cddcf 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -33,7 +33,7 @@ libczirw-sys = { path = "../libczirw-sys", optional = true } ndarray = { version = "0.17", features = ["serde"] } num = "0.4" numpy = { version = "0.29", optional = true } -ome-metadata = { path = "../ome-metadata/ome-metadata" } +ome-metadata = "0.5" ordered-float = { version = "5", optional = true } phf = { version = "0.14", features = ["macros"] } postcard = { version = "1", features = ["use-std"], optional = true } diff --git a/py/ndbioimage/__init__.py b/py/ndbioimage/__init__.py index e08fcc4..c787a00 100755 --- a/py/ndbioimage/__init__.py +++ b/py/ndbioimage/__init__.py @@ -15,9 +15,13 @@ os.environ["COLORBT_SHOW_HIDDEN"] = "1" from . import ndbioimage_rs as rs # noqa from .ndbioimage_rs import View as Imread -from .ndbioimage_rs import batch_to_tiff from .transforms import Transform, Transforms # noqa: F401 +try: + from .ndbioimage_rs import batch_to_tiff +except ImportError: + pass + try: import ome_metadata # noqa except ModuleNotFoundError: diff --git a/pyproject.toml b/pyproject.toml index 08a59a9..77773bd 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -35,7 +35,8 @@ ndbioimage_generate_stub = "ndbioimage:ndbioimage_generate_stub" [tool.maturin] python-source = "py" -features = ["python", "default"] +features = ["python", "bioformats_java", " tiffwrite", "movie"] +no-default-features = true module-name = "ndbioimage.ndbioimage_rs" include = ["py/ndbioimage/jassets/j4rs*", "py/ndbioimage/deps/libj4rs*"] diff --git a/src/py.rs b/src/py.rs index 0980ff7..6364815 100644 --- a/src/py.rs +++ b/src/py.rs @@ -1796,6 +1796,10 @@ impl PyView { self.view.save_as_movie(file, &options)?; Ok(()) } + + /// backwards compatibility + #[allow(unused_variables)] + fn set_cache_size(&self, size: usize) {} } submit! {