Skip to content

Keep nonduplicate tents out of repeated landscape layers - #115

Open
antonsoo wants to merge 1 commit into
scikit-tda:masterfrom
antonsoo:fix/duplicate-landscape-bars
Open

antonsoo wants to merge 1 commit into
scikit-tda:masterfrom
antonsoo:fix/duplicate-landscape-bars

Conversation

@antonsoo

Copy link
Copy Markdown
Contributor

For diagram [[0,2], [0,2], [3,5]], the second exact landscape currently includes the [3,5] tent even though that bar occurs only once. The duplicate-bar shortcut copies the complete first layer, including later nonduplicate features.

Keep duplicates in the ordinary sweep whenever a later bar can extend the first landscape. Retain the copying shortcut when the repeated tent is the complete layer, and consume duplicate prefixes without modifying an enumerated list. Add eighteen sorted-tent regression cases and correct two existing expectations that encoded the same error.

Update the patch version and release history to 0.4.2, following the release metadata requested for the preceding norm correction.

Validation: nine new cases fail before; all eighteen pass after. Full suite on current master: 142 passed, with the existing 19 warnings (124 passed on unchanged master). Ruff format/lint, wheel/sdist builds and metadata checks pass.

An independent ordered-tent reference checks all 3,002 multisets of up to five integer bars in [0,4]: 886 wrong diagrams before, none after. On twelve recorded handwritten-digit diagrams, this also corrects both wrong raw landscapes and all 21 affected pairwise differences; twelve approximate-landscape controls remain unchanged.

@codecov

codecov Bot commented Oct 18, 2026

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 75.00000% with 1 line in your changes missing coverage. Please review.
✅ Project coverage is 79.26%. Comparing base (00144a8) to head (ab1ee51).

Files with missing lines Patch % Lines
persim/_version.py 0.00% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master     #115      +/-   ##
==========================================
- Coverage   79.28%   79.26%   -0.02%     
==========================================
  Files          20       20              
  Lines        1477     1476       -1     
  Branches      271      271              
==========================================
- Hits         1171     1170       -1     
  Misses        229      229              
  Partials       77       77              

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

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@antonsoo

Copy link
Copy Markdown
Contributor Author

The six Python jobs, lint, documentation and package builds passed. I checked the two Codecov failures: the only uncovered changed line is the version assignment, which is also unexecuted on master. The project percentage moves from 79.28% to 79.26% because this patch removes one covered line; missing lines, covered branches and partial-branch counts are unchanged.

This branch has not been deployed

No deployments
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.

1 participant