-
Notifications
You must be signed in to change notification settings - Fork 100
Open
Description
Report
Handle cases explicitly for KeyError or ValueError in _make_tiles. For example in
squidpy/src/squidpy/experimental/im/_make_tiles.py
Lines 840 to 851 in d4f256f
| def _get_primary_coordinate_system(element: SpatialElement) -> str | None: | |
| """Return the first available coordinate system, preferring 'global'.""" | |
| try: | |
| transformations = get_transformation(element, get_all=True) | |
| except (KeyError, ValueError): | |
| return None | |
| if not transformations: | |
| return None | |
| # Prefer 'global' if present | |
| if "global" in transformations: | |
| return "global" | |
| return next(iter(transformations.keys())) |
Seperating this issue to speed up development
Metadata
Metadata
Assignees
Labels
No labels