From 24940cc21fe468771edc67a23a5e233beb5e32d0 Mon Sep 17 00:00:00 2001 From: Shahul Alam Date: Thu, 10 Oct 2024 12:08:18 -0400 Subject: [PATCH] Fix logic for `anndata` import. Remove high `anndata` pin. --- pyproject.toml | 2 +- src/squidpy/gr/_utils.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/pyproject.toml b/pyproject.toml index 494a0a0c..8cc85ffd 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -47,7 +47,7 @@ maintainers = [ dependencies = [ "aiohttp>=3.8.1", - "anndata>=0.11.0rc1", + "anndata>=0.9", "cycler>=0.11.0", "dask-image>=0.5.0", "dask[array]>=2021.02.0", diff --git a/src/squidpy/gr/_utils.py b/src/squidpy/gr/_utils.py index ac334f42..5040d192 100644 --- a/src/squidpy/gr/_utils.py +++ b/src/squidpy/gr/_utils.py @@ -21,7 +21,7 @@ from squidpy._utils import NDArrayA, _unique_order_preserving CAN_USE_SPARSE_ARRAY = Version(anndata.__version__) >= Version("0.11.0") -if not CAN_USE_SPARSE_ARRAY: +if CAN_USE_SPARSE_ARRAY: from anndata._core.views import ArrayView from anndata._core.views import SparseCSCMatrixView as SparseCSCView from anndata._core.views import SparseCSRMatrixView as SparseCSRView