Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

xarray bump #159

Merged
merged 3 commits into from
Nov 29, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ jobs:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.9", "3.10", "3.11.8"]
python-version: ["3.10", "3.11.8"]
steps:
#----------------------------------------------
# check-out repo and set-up python
Expand Down
4,953 changes: 2,607 additions & 2,346 deletions poetry.lock

Large diffs are not rendered by default.

6 changes: 3 additions & 3 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,9 @@ classifiers = [
sopa = "sopa.main:app"

[tool.poetry.dependencies]
python = ">=3.9,<3.12"
spatialdata = ">=0.2.0"
spatialdata-io = ">=0.1.3"
python = ">=3.10,<3.13"
spatialdata = ">=0.2.6"
spatialdata-io = ">=0.1.6"
scanpy = ">=1.9.8"
botocore = "1.34.19"
typer = ">=0.9.0"
Expand Down
3 changes: 1 addition & 2 deletions sopa/_sdata.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,10 @@
import geopandas as gpd
import pandas as pd
from anndata import AnnData
from datatree import DataTree
from spatialdata import SpatialData
from spatialdata.models import SpatialElement
from spatialdata.transformations import Identity, get_transformation, set_transformation
from xarray import DataArray
from xarray import DataArray, DataTree

from ._constants import SopaAttrs, SopaFiles, SopaKeys

Expand Down
3 changes: 1 addition & 2 deletions sopa/io/explorer/images.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,12 +6,11 @@

import numpy as np
import tifffile as tf
from datatree import DataTree
from multiscale_spatial_image import to_multiscale
from spatialdata import SpatialData
from spatialdata.transformations import Affine, set_transformation
from tqdm import tqdm
from xarray import DataArray
from xarray import DataArray, DataTree

from ..._sdata import get_intrinsic_cs, get_spatial_image
from ...utils.image import resize_numpy, scale_dtype
Expand Down
3 changes: 1 addition & 2 deletions sopa/io/reader/wsi.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,10 @@
from typing import Any

import xarray
from datatree import DataTree
from spatialdata import SpatialData
from spatialdata.models import Image2DModel
from spatialdata.transformations import Identity, Scale
from xarray import DataArray
from xarray import DataArray, DataTree


def wsi(
Expand Down
3 changes: 1 addition & 2 deletions sopa/patches/infer.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,11 +12,10 @@

import numpy as np
import tqdm
from datatree import DataTree
from spatialdata import SpatialData
from spatialdata.models import Image2DModel
from spatialdata.transformations import Scale
from xarray import DataArray
from xarray import DataArray, DataTree

from .._constants import SopaKeys
from .._sdata import get_intrinsic_cs, get_spatial_image
Expand Down
3 changes: 1 addition & 2 deletions sopa/patches/patches.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,12 +10,11 @@
import numpy as np
import pandas as pd
from dask.diagnostics import ProgressBar
from datatree import DataTree
from shapely.geometry import GeometryCollection, MultiPolygon, Polygon, box
from spatialdata import SpatialData
from spatialdata.models import ShapesModel
from spatialdata.transformations import get_transformation
from xarray import DataArray
from xarray import DataArray, DataTree

from .._constants import EPS, ROI, SopaFiles, SopaKeys
from .._sdata import (
Expand Down
3 changes: 1 addition & 2 deletions sopa/segmentation/tissue.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,10 @@
import geopandas as gpd
import numpy as np
import spatialdata
from datatree import DataTree
from shapely.geometry import Polygon
from spatialdata import SpatialData
from spatialdata.models import ShapesModel
from xarray import DataArray
from xarray import DataArray, DataTree

from .._constants import ROI, SopaAttrs
from .._sdata import get_intrinsic_cs, get_spatial_element
Expand Down
3 changes: 1 addition & 2 deletions sopa/utils/image.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,8 @@
import dask.array as da
import dask_image.ndinterp
import numpy as np
from datatree import DataTree
from spatialdata import SpatialData
from xarray import DataArray
from xarray import DataArray, DataTree


def resize(xarr: DataArray, scale_factor: float) -> da.Array:
Expand Down