Skip to content
Draft
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
11 changes: 11 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -61,3 +61,14 @@ node_modules/
uv.lock
pixi.lock

# local hatch config
hatch.toml

# Kilo and plans
.kilo/
plans/

# test coverage
.coverage
htmlcov/

1 change: 1 addition & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,7 @@ extra = [
[dependency-groups]
dev = [
"bump2version",
"pandas-stubs>=3.0.3.260530",
]
test = [
"pytest",
Expand Down
7 changes: 7 additions & 0 deletions src/spatialdata/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,8 @@
# _core.query.spatial_query
"bounding_box_query": "spatialdata._core.query.spatial_query",
"polygon_query": "spatialdata._core.query.spatial_query",
# _core.transformation_manager
"TransformationManager": "spatialdata._core.transformation_manager",

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No need for the user to instantiate it. It can be removed.

# _core.spatialdata
"SpatialData": "spatialdata._core.spatialdata",
# _io._utils
Expand Down Expand Up @@ -115,6 +117,8 @@
# _core.query.spatial_query
"bounding_box_query",
"polygon_query",
# _core.transformation_manager
"TransformationManager",

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same here, to be removed.

# _core.spatialdata
"SpatialData",
# _io._utils
Expand Down Expand Up @@ -208,6 +212,9 @@ def __dir__() -> list[str]:
# _core.spatialdata
from spatialdata._core.spatialdata import SpatialData

# _core.transformation_manager
from spatialdata._core.transformation_manager import TransformationManager
Comment on lines +215 to +216

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same here.


# _io._utils
from spatialdata._io._utils import get_dask_backing_files

Expand Down
2 changes: 2 additions & 0 deletions src/spatialdata/_core/spatialdata.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@
from zarr.errors import GroupNotFoundError

from spatialdata._core._elements import Images, Labels, Points, Shapes, Tables
from spatialdata._core.transformation_manager import TransformationManager
from spatialdata._core.validation import (
check_all_keys_case_insensitively_unique,
check_target_region_column_symmetry,
Expand Down Expand Up @@ -130,6 +131,7 @@ def __init__(
self._shapes: Shapes = Shapes(shared_keys=self._shared_keys)
self._tables: Tables = Tables(shared_keys=self._shared_keys)
self.attrs = attrs if attrs else {} # type: ignore[assignment]
self.transformation_manager = TransformationManager() # Initialize the TransformationManager

element_names = list(chain.from_iterable([e.keys() for e in [images, labels, points, shapes] if e is not None]))

Expand Down
Loading