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

memento #918

Draft
wants to merge 83 commits into
base: main
Choose a base branch
from
Draft

memento #918

wants to merge 83 commits into from

Conversation

atolopko-czi
Copy link
Collaborator

@atolopko-czi atolopko-czi commented Jan 4, 2024

For #847

- Migrated code from
https://github.com/mincheoly/memento-cxg/blob/atol/codify-and-compare-notebooks/
- Reorganized code to fit this repo, splitting api and builder into api/ and
tools/ dirs, repsectively
- Added type hints
- Updated docs
- add all Census obs metadata attributes as cube dimensions

- remove unused estimator columns

- add test fixture code to extract a small subset of a Census Experiment for
local testing of the memento estimators cube
- use TileDB categorical types
- fix TileDB handling of Pandas categoricals
- fix approx_size_factors filtering
- add assertion sanity checks for debugging
- add cube validator
- add validation for "all obs dims present"
- cleanup debug assertions
- add missing suspension_type dim
- compute for all features
- add regression test for cube builder, testing against a previously built and
committed cube

- add parameterized build() method

- add CLI entrypoint for cube builder
- Ensure the size_factors for obs group is created correctly, with one row per
obs row
- add validation check for n_obs
too noisy as warnings, and not useful during production runs
- use single concat() call instead of a join
- factor out code into sub-methods for better profiling insight
If starting with a new cube, do not bother to check whether obs group needs to
be computed; assume it does
This avoids having to return result to parent process
Obs groups (i.e., cube rows) are now represented by an obs_group_joinid that
can be used to join the estimators to the original obs dimension
columns. This saves considerable space, as the obs dimension values do not
need to be repeated for each feature (gene). Also, Group By operations should
be more efficient now that grouping can occur on a single value.
Copy link

codecov bot commented Jan 30, 2024

Codecov Report

Attention: Patch coverage is 55.55556% with 72 lines in your changes are missing coverage. Please review.

Project coverage is 80.59%. Comparing base (06ee454) to head (e726acb).

Files Patch % Lines
...e_census/experimental/diffexp/memento/diff_expr.py 48.57% 72 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main     #918      +/-   ##
==========================================
- Coverage   81.32%   80.59%   -0.74%     
==========================================
  Files          73       75       +2     
  Lines        5553     5715     +162     
==========================================
+ Hits         4516     4606      +90     
- Misses       1037     1109      +72     
Flag Coverage Δ
unittests 80.59% <55.55%> (-0.74%) ⬇️

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

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

atolopko-czi and others added 6 commits February 1, 2024 17:40
* Defer python package version pinning for memento cube builder

* Add unit test for memento differential expression

* Fix markdown lint complaints

* Regenerate test fixtures

* Update unit test

* Use a different default covariate list

---------

Co-authored-by: atarashansky <[email protected]>
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.

3 participants