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

[python] Add unit tests for obsm, obsp, and to_anndata #1934

Merged
merged 7 commits into from
Dec 4, 2023

Conversation

ebezzi
Copy link
Member

@ebezzi ebezzi commented Nov 29, 2023

Issue and/or context:
Resolves #1930 together with single-cell-data/SOMA#179. Requires the latter to be released before tests can pass, so this is still marked as draft.

Changes:
This PR only contains the unit tests. All the code changes are in the SOMA repo.

Notes for Reviewer:

@ebezzi ebezzi marked this pull request as draft November 30, 2023 19:55
query.obsm("baz").tables().concat()
== soma_experiment.ms["RNA"]
.obsm["baz"]
.read((obs_slice, range(50)))
Copy link
Member

Choose a reason for hiding this comment

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

magic number 50 is in a few places. Would be good to at least use a constant variable (e.g., N_FEAT or some such)

Copy link
Member Author

Choose a reason for hiding this comment

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

Good point, let me add it to a constant.

@codecov-commenter
Copy link

codecov-commenter commented Dec 4, 2023

Codecov Report

Merging #1934 (7703529) into main (04ab23e) will increase coverage by 26.62%.
The diff coverage is n/a.

❗ Your organization needs to install the Codecov GitHub app to enable full functionality.

Additional details and impacted files
@@             Coverage Diff             @@
##             main    #1934       +/-   ##
===========================================
+ Coverage   63.11%   89.74%   +26.62%     
===========================================
  Files         106       34       -72     
  Lines       10056     3598     -6458     
===========================================
- Hits         6347     3229     -3118     
+ Misses       3709      369     -3340     
Flag Coverage Δ
python 89.74% <ø> (-0.03%) ⬇️
r ?

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

Components Coverage Δ
python_api 89.74% <ø> (-0.03%) ⬇️
libtiledbsoma ∅ <ø> (∅)

Copy link
Member

@bkmartinjr bkmartinjr left a comment

Choose a reason for hiding this comment

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

one minor nit in a comment - otherwise LGTM

Copy link
Contributor

@thetorpedodog thetorpedodog left a comment

Choose a reason for hiding this comment

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

Looks great! One thing I would recommend to make dev/review a bit easier is to substitute in the development revision into the setup.py file for the duration of the review, so it can be more easily evaluated during the review process, but once the upstream is released, you can cut it over to the final version and fully integrate everything.

@ebezzi ebezzi marked this pull request as ready for review December 4, 2023 21:18
@ebezzi ebezzi merged commit 8bf00f9 into main Dec 4, 2023
9 checks passed
@ebezzi ebezzi deleted the ebezzi/obsm-obsp-unit-tests branch December 4, 2023 21:41
johnkerl added a commit that referenced this pull request Dec 4, 2023
johnkerl added a commit that referenced this pull request Dec 4, 2023
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.

[python] obsm and varm in ExperimentQuery
4 participants