Skip to content

Remove Tau from Pixelator - #445

Merged
johandahlberg merged 4 commits into
devfrom
cursor/remove-tau-pna-1953-v2-7397
Aug 17, 2026
Merged

Remove Tau from Pixelator#445
johandahlberg merged 4 commits into
devfrom
cursor/remove-tau-pna-1953-v2-7397

Conversation

@johandahlberg

@johandahlberg johandahlberg commented Aug 14, 2026

Copy link
Copy Markdown
Contributor

Description

Remove the retired Tau aggregate-calling implementation from Pixelator and stop writing tau, tau_type, and tau_thresholds to newly generated AnnData objects.

  • Delete pixelator.common.annotate.aggregates (specificity_tau, call_aggregates) and the TAU_* constants.
  • Drop the call_aggregates calls in the PNA graph, denoise, and sample calling paths, so new AnnData no longer carries Tau fields.
  • Remove the Tau-derived aggregate metrics from GraphStatistics / GraphSampleReport and the graph report snapshot, since they were computed solely from tau_type.
  • Exclude legacy tau / tau_type columns in add_missing_adata_info, which otherwise copies them from an old AnnData back into a rebuilt one during denoise and sample calling. _add_missing_adata_info in sample calling was a duplicate of that helper and now delegates to it.

Replaces #444, which was based on dev before the MPX removal in #439. The MPX portions of that branch (annotate step, --aggregate-calling CLI flag, scatter_umi_per_upia_vs_tau plot, annotate report fields) are obsolete now that the MPX tree is gone.

This branch has since been merged up to current dev. The only conflict was src/pixelator/pna/graph_legacy/connected_components.py, which #443 deleted while this branch had edited it to remove its Tau usage; resolved by accepting the deletion.

Linear: PNA-1953

Type of change

  • Breaking change (fix or feature that would cause existing functionality to not work as expected)

Existing PXL files remain readable; their stored Tau columns are simply no longer produced or propagated on rewrite.

How Has This Been Tested?

  • uv run ruff format --check src tests and uv run ruff check src tests — all pass
  • uv run pytest tests — 644 passed, 3 skipped, 1 failed
  • The single failure is tests/cli/test_integration.py::test_command_line_interface, which is pre-existing on dev and unrelated to this PR: #443 removed the graph_legacy CLI command but left it listed in that test's expected commands. It reproduces identically (AssertionError: graph_legacy) on an unmodified dev checkout, so it is not fixed here.
  • Assertions were added that newly written AnnData omits tau, tau_type, and tau_thresholds in tests/common/data_generator/test_pixelfile.py and tests/pna/denoise/test_denoise.py, plus a regression test that add_missing_adata_info does not restore legacy Tau columns.

PR checklist:

  • This comment contains a description of changes (with reason).
  • I have performed a self-review of my own code
  • My changes generate no new warnings
  • I have added tests that prove my fix is effective or that my feature works
  • I have checked my code and documentation and corrected any misspellings
Open in Web Open in Cursor 

cursoragent and others added 2 commits August 14, 2026 17:11
Co-authored-by: Johan Dahlberg <johan.dahlberg@pixelgen.com>
Co-authored-by: Johan Dahlberg <johan.dahlberg@pixelgen.com>
@johandahlberg
johandahlberg force-pushed the cursor/remove-tau-pna-1953-v2-7397 branch 2 times, most recently from 57a2cca to a5f2dbc Compare August 14, 2026 15:18
@johandahlberg
johandahlberg force-pushed the cursor/remove-tau-pna-1953-v2-7397 branch from a5f2dbc to 39ddf7a Compare August 14, 2026 15:20
@johandahlberg
johandahlberg marked this pull request as ready for review August 14, 2026 15:22

@cursor cursor Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Cursor Bugbot has reviewed your changes using high effort and found 1 potential issue.

Fix All in Cursor

❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.

Reviewed by Cursor Bugbot for commit 19ee885. Configure here.

Comment thread src/pixelator/pna/analysis/denoise.py
@johandahlberg
johandahlberg force-pushed the cursor/remove-tau-pna-1953-v2-7397 branch from 19ee885 to 6a04a8b Compare August 14, 2026 15:32
@johandahlberg
johandahlberg merged commit ff259e4 into dev Aug 17, 2026
15 checks passed
@johandahlberg
johandahlberg deleted the cursor/remove-tau-pna-1953-v2-7397 branch August 17, 2026 05:41
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