Skip to content

Define raw and resolved classification boundaries - #1852

Merged
BryonLewis merged 5 commits into
hierarchical-classification-pr5-kwcocofrom
hierarchical-classification-pr6-boundaries
Aug 18, 2026
Merged

BryonLewis merged 5 commits into
hierarchical-classification-pr5-kwcocofrom
hierarchical-classification-pr6-boundaries

Conversation

@PaulHax

@PaulHax PaulHax commented Aug 14, 2026 •

Copy link
Copy Markdown
Collaborator

Define raw and resolved classification boundaries

A track stores raw confidence pairs. The viewer can resolve a different display type from those
pairs when a hierarchy and filters are active.

This PR defines which features use the resolved display type. It also defines which features must
use the raw stored pairs.

Resolved display type

  • Track and detection attribute filters use the same resolved pair as the viewer.
  • Resolution uses hierarchy depth, checked types, and confidence thresholds.
  • Suppression regions compare their type with the resolved display type.
  • Lists, counts, and canvas code use the same suppression resolver.
  • The suppression cache includes hierarchy and filter state.
  • The cache also includes Prevent Cascade Types state.
  • Attribute-name suppression keeps its existing attribute behavior.

Raw stored pairs

  • Checked Types Only export compares checked names with raw pair names.
  • Filtered DIVE JSON removes unchecked pairs from exported vectors.
  • Full-archive export uses the same raw-name rule.
  • Export filtering does not change stored tracks.
  • Server Library labels use the raw pair with the highest confidence.
  • A tie keeps the first stored pair.

The server cannot use viewer resolution for Library labels. It does not have each viewer's checked
types or confidence thresholds.

Related corrections

  • Multicamera save keeps global attribute and filter definitions when the dataset uses named camera
    maps.
  • The bulk type-update action appears only during multi-track editing.
  • The bulk action cannot run with a hidden default during normal track selection.

Manual tests

Test data: download and extract
classification.zip. Paths
below are relative to dive-classification-test-data/.

Resolved attribute filters

  1. Create the image-sequence dataset with the files in display/resolved-attribute-filters/, add
    the documented track and detection filters for juvenile-red-snapper, then change each filter
    type to fish.

Verify: Each track and detection filter uses the resolved type without a reload.

Resolved suppression regions

  1. Create the image-sequence dataset with the files in display/resolved-suppression-regions/ and
    set the suppression region type to fish at the default 99% overlap.
  2. Uncheck juvenile-red-snapper and red-snapper, then recheck both.

Verify: Track 2 disappears and returns without a reload.

Raw confidence-pair export

  1. Create the image-sequence dataset with the files in export/raw-confidence-pair-filtering/;
    leave juvenile-red-snapper and fish checked, and uncheck red-snapper.
  2. Export with Checked Types Only and inspect track 1 in the exported DIVE JSON.

Verify: The export contains only the expected raw pair names, and the source dataset does not
change.

Stack

This is PR 9 of 9. Previous: add DIVE KWCOCO classification support.

  1. Allow devDependency imports in TypeScript spec files
  2. Preserve warnings from every Desktop import file
  3. Copy source metadata when creating a single-camera soft clone
  4. Add hierarchical track classification
  5. Centralize hierarchical classification changes
  6. Replace mutable merged tracks with read-only projections
  7. Make track lifecycle operations classification-safe
  8. Add lossless DIVE KWCOCO classification support
  9. Current — Define raw and resolved classification boundaries

This PR is stacked on hierarchical-classification-pr5-kwcoco.

Overall: 32 files, +723/-86. Commits: 90917889 through 25e427be.

BryonLewis
BryonLewis previously approved these changes Aug 18, 2026

@BryonLewis BryonLewis left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

I added one fix that was basically making sure that the display and filtered exports respect the same 0 values. Before they didn't so you would have a mis-alignment between exporting and what you saw.

@PaulHax
PaulHax force-pushed the hierarchical-classification-pr6-boundaries branch from 211b460 to b89c295 Compare August 18, 2026 18:29
PaulHax and others added 5 commits August 18, 2026 15:47
Attribute and filter definitions could be dropped after singleCam was replaced by named camera maps. Route global definitions through an available map so saving and reloading multicamera datasets preserves them.
The bulk update button remained available during ordinary track selection and could assign its hidden default. Show and execute the action only while multi-track editing is active.
@PaulHax
PaulHax force-pushed the hierarchical-classification-pr6-boundaries branch from b89c295 to 4516ade Compare August 18, 2026 19:47
@BryonLewis
BryonLewis merged commit 94d5431 into main Aug 18, 2026
3 checks passed
@BryonLewis
BryonLewis deleted the hierarchical-classification-pr6-boundaries branch August 18, 2026 20:06
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