Repository navigation
Merged genes: document why counts are summed, add check_merged_genes.py - #128
Merged
Merged
Conversation
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Compares each merged gene's input genes cell by cell, reading the matrices as build_expression.py does; fails on identical values with expression. Added to the build steps and the FlyBase release issue's commands. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
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.
Explains in DESIGN.md's gene-id rules why summing the counts of merged genes is safe here: count pipelines assign each read to at most one gene. vfb-EPseq-ontology (VirtualFlyBrain/vfb-EPseq-ontology#2) works from bulk TPM, where overlapping models get identical rows. There, identical rows count once and merges with differing rows are dropped.
Adds
scripts/check_merged_genes.py(--project/--all). It reads each project's matrices asbuild_expression.pydoes and compares the input genes behind each merged gene cell by cell. It fails on a pair with expression and identical values. It is not in CI, since it needs the matrices in.cache. It is now a build step (DESIGN.md, README) and in the commands of the FlyBase release issue.All 17 projects pass at FB2026_03. No merged pair has identical values in any cell with expression, and the pairs whose models overlap completely (CG30497 / CG45093, stg1 / CG11566) are zero in every cell.
Tests:
tests/test_check_merged_genes.py;test_ci_checks.pyupdated for the issue text.🤖 Generated with Claude Code