Add mapmycells - #1947
Open
rsc3 wants to merge 18 commits into
Open
Conversation
|
Remember to squash merge! |
🔍Version Validation Results: |
🔍Changelog Validation Results: |
|
Remember to squash merge! |
🔍Version Validation Results: |
🔍Changelog Validation Results: |
- Collapse the dead query_markers ternary (Human_MTG and the catch-all both resolved to custom_query_markers) into a single condition - Fail fast via ErrorWithMessage when reference_atlas=="Custom" but custom_precomputed_stats is unset, instead of an opaque select_first error - Repin docker to the tag actually published for this branch (add-mapmycells); the previous default was never built - Add pipeline_version + MapMyCells.changelog.md (0.1.0, initial release) - Register MapMyCells and TestMapMyCells in .dockstore.yml - Move test_inputs into test_inputs/Plumbing per AGENTS.md layout - Add verification/test-wdls/TestMapMyCells.wdl, verification/VerifyMapMyCells.wdl, and .github/workflows/test_mapmycells.yml following the scANVI CI trio as a template Note: five gs://broad-gotc-test-storage/mapmycells/* asset paths referenced by the pipeline (both precomputed_stats files, gene_mapping_db, mouse_markers, and both test query.h5ad files) do not exist yet, so CI cannot pass or seed truth until real reference data is staged. See MapMyCells.changelog.md / follow-up discussion. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
The gs://broad-gotc-test-storage/mapmycells/ paths for precomputed_stats, gene_mapping_db, and mouse markers never actually existed (verified 404 via GCS metadata lookups). Per the upstream cell_type_mapper docs (running_online_taxonomies_locally.md), these are real, publicly hosted Allen Institute assets -- just not on GCS. Move them into the docker image built in warp-tools instead of trying to host a copy ourselves. - Task now selects precomputed_stats/query_markers by reference_atlas via a bash case statement pointing at baked-in container paths for Human_MTG and Mouse_WMB; Custom mode still takes real File inputs, localized normally - Dropped the gene_mapping_db default entirely (its source, gs://.../mmc_gene_mapper.2025-08-04.db, also never existed); building it via mmc_gene_mapper needs a 15GB NCBI taxonomy download, deliberately deferred -- see warp-tools commit - Removed the now-unneeded workflow-level select_first/ternary plumbing Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
gs://broad-gotc-test-storage/mapmycells/mmc_gene_mapper.2025-08-04.db is now populated with Allen Institute's pre-built gene-symbol-to-Ensembl-ID mapping db (~15GB). Default gene_mapping_db to it for every reference_atlas (select_first against custom_gene_mapping_db), matching the original author's intent -- the file just didn't exist at that path until now. Kept it GCS-hosted rather than baked into the mapmycells docker image: audited warp-tools and found no precedent for baking reference data this large into an image (every other large reference asset -- imputation panels, gnomAD data -- is a runtime File input hosted on GCS, never a docker layer), and baking it in would tax every task's docker pull by ~15GB regardless of whether that run needs gene mapping. Bumped disk_size default 100->150 to cover localizing the db on every run. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
…g tests test_human.json / test_mouse.json pointed at gs://broad-gotc-test-storage/mapmycells/query.h5ad and query_mouse.h5ad, neither of which ever existed. scANVI already has small, known-good gene-expression h5ads in its own test_inputs (verified via GCS metadata: ~31-36MB each, cheap enough for a Plumbing test regardless of which scANVI tier they were filed under). MapMyCells only consumes gene expression, so only each case's gex_h5ad is reused -- not the atac_h5ad or ref_h5ad: - Human_MTG: scANVI/input/scientific/10k_PBMC/10k_PBMC_gex.h5ad - Mouse_WMB: scANVI/input/plumbing/Mouse_Hippocampus_AIT/Mouse_Hippocampus_AIT_plumbing_gex.h5ad Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
|
Remember to squash merge! |
🔍Version Validation Results: |
🔍Changelog Validation Results: |
|
Remember to squash merge! |
🔍Version Validation Results: |
🔍Changelog Validation Results: |
Verified via PubMed/Europe PMC (PMID 41958981, PMCID PMC13060854) rather than trusting a web-search snippet: Daniel SF, Lee C, Mollenkopf T, et al., "High-performance mapping of unlabeled cell-by-gene data to reference brain taxonomies," bioRxiv 2026, doi:10.64898/2026.03.06.710160. Also links the cell_type_mapper source repo. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
|
Remember to squash merge! |
🔍Changelog Validation Results: |
🔍Version Validation Results: |
|
Remember to squash merge! |
🔍Version Validation Results: |
🔍Changelog Validation Results: |
UpdateTestInputs.py infers Plumbing vs Scientific by checking the input filename first, then falling back to substring-searching the whole input JSON for "plumbing"/"scientific" if the filename doesn't say. test_human's query h5ad path (borrowed from scANVI) contains "scientific", which fooled the fallback into seeding its truth under gs://.../MapMyCells/truth/scientific/... instead of .../plumbing/... -- confirmed by inspecting the actual GCS truth layout after the seed run. Renaming to *_plumbing.json short-circuits the fallback instead of relying on an accidental path substring match. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
No other WARP pipeline uses a _plumbing filename suffix (checked Optimus, Multiome, ATAC, PairedTag, SlideSeq, SlideTags, PeakCalling) -- scANVI, which this was copied from, is the outlier. Back to test_human.json / test_mouse.json. The tier-mislabeling this was working around (test_human's truth landing under .../truth/scientific/... because its borrowed query h5ad path contains that word) is real but cosmetic -- truth_path is computed identically at seed- and compare-time, so it's self-consistent and doesn't fail the test. Left as a known issue in the changelog for a real fix later. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
New, smaller Plumbing tests to follow separately. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
|
Remember to squash merge! |
🔍Version Validation Results: |
🔍Changelog Validation Results: |
Fetched from https://brain-map.org/bkp/analyze/mapmycells/files (verified both URLs resolve): a 1k-cell human MTG example and a 10k-cell whole-mouse- brain example, both small enough for a fast/cheap smoke test. Staged at gs://pd-test-storage-public/MapMyCells/input/plumbing/{human,mouse}/, matching the <Pipeline>/input/{plumbing,scientific}/ layout other WARP pipelines use. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
|
Remember to squash merge! |
🔍Version Validation Results: |
🔍Changelog Validation Results: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Give your PR a concise yet descriptive title.
Please explain the changes you made here.
Explain the motivation for making this change. What existing problem does the pull request solve?
Mention any issues fixed, addressed, or otherwise related to this pull request, including issue numbers or hard links for issues in other repos.
You can delete these instructions once you have written your PR description.
Checklist
If you can answer "yes" to the following items, please add a checkmark next to the appropriate checklist item(s) and notify our WARP team by tagging @broadinstitute/warp-admins in a comment on this PR.