Skip to content

[python] Add cell and transcript ingestion for Xenium #3893

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

Closed
wants to merge 9 commits into from

Conversation

XanthosXanthopoulos
Copy link
Collaborator

Issue and/or context: sc-52730

Changes:

Notes for Reviewer:

Copy link
Collaborator

@jp-dark jp-dark left a comment

Choose a reason for hiding this comment

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

This overall looks good. I have a couple small suggestions, mostly nits.

I'm going to wait to approve it until the PR #3835 gets merged to main so we don't accidentally combine them when we squash the PR commits.

Comment on lines +1592 to +1604
if isinstance(platform_config, dict):
platform_config.setdefault("tiledb", dict())
if isinstance(platform_config["tiledb"], dict):
platform_config["tiledb"].setdefault("create", dict())
if isinstance(platform_config["tiledb"]["create"], dict):
platform_config["tiledb"]["create"].setdefault(
"allows_duplicates", True
)
Copy link
Collaborator

Choose a reason for hiding this comment

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

I think you want to get rid of the isinstance checks in here. I might be mistaken, but I think they should always evaluate to True since you setdefault first. If not, then you are failing to set allows_duplicates to True by default.

return xenium_path


@pytest.mark.skip(reason="Missing test dataset")
Copy link
Collaborator

Choose a reason for hiding this comment

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

We need to add the test data to the test data repo before we fully release the Xenium reader. I added a shortcut story for this.

@@ -8,7 +8,9 @@ namespace tiledbsoma {

class OutlineTransformer : public Transformer {
public:
OutlineTransformer(SOMACoordinateSpace coordinate_space);
OutlineTransformer(
Copy link
Collaborator

Choose a reason for hiding this comment

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

Could you add some docs either here or above the columns private member on what columns is and how it is used?

Base automatically changed from dark/sc-63795 to main April 7, 2025 15:57
Copy link

codecov bot commented May 6, 2025

Codecov Report

Attention: Patch coverage is 28.57143% with 215 lines in your changes missing coverage. Please review.

Project coverage is 66.29%. Comparing base (a5487e1) to head (33f79e9).
Report is 71 commits behind head on main.

Additional details and impacted files
@@             Coverage Diff             @@
##             main    #3893       +/-   ##
===========================================
- Coverage   89.18%   66.29%   -22.90%     
===========================================
  Files          57      156       +99     
  Lines        6901    20627    +13726     
  Branches        0     1205     +1205     
===========================================
+ Hits         6155    13674     +7519     
- Misses        746     6543     +5797     
- Partials        0      410      +410     
Flag Coverage Δ
libtiledbsoma 55.37% <83.82%> (?)
python 86.97% <12.44%> (-2.22%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

Components Coverage Δ
python_api 86.97% <12.44%> (-2.22%) ⬇️
libtiledbsoma 46.58% <82.53%> (∅)
🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Comment on lines +11 to +27
from .ingest import (
VisiumPaths,
XeniumPaths,
from_visium,
from_xenium,
register_visium_datasets,
)
from .outgest import to_spatialdata

__all__ = ["to_spatialdata", "from_visium", "register_visium_datasets", "VisiumPaths"]
__all__ = [
"to_spatialdata",
"from_visium",
"register_visium_datasets",
"VisiumPaths",
"from_xenium",
"XeniumPaths",
]
Copy link
Collaborator

Choose a reason for hiding this comment

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

Let's not add from_xenium and XeniumPaths to the module until it's fully implemented.

@jp-dark
Copy link
Collaborator

jp-dark commented Jun 12, 2025

De-prioritized for now. We can re-open later when we have more resources to dedicate towards spatial io.

@jp-dark jp-dark closed this Jun 12, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants