Skip to content

[Issue] — Add configurable max_age per zone #65

@Devnil434

Description

@Devnil434

Description

Currently all tracks share the same global tracker max_age.

However, different surveillance zones require different persistence behavior.

Example:

  • tracks in restricted_door should persist longer
  • tracks in safe_corridor should expire faster

Implement configurable per-zone max_age overrides.


YAML Extension

Extend:

config/zones.yaml

with:

zones:
  - name: restricted_door
    max_age_override: 60

  - name: safe_corridor
    max_age_override: 15

Expected Behavior

  • LOST tracks in sensitive zones remain alive longer
  • safe zones expire aggressively
  • fallback to global value when override absent

Files to Touch

config/zones.yaml
services/tracking/tracker.py
tests/test_tracker.py

Requirements

  • Read override from zone config
  • Apply dynamically during LOST handling
  • Maintain backward compatibility
  • Preserve existing tracker behavior if override missing

Acceptance Criteria

  • Zone-specific max_age applied correctly
  • Global fallback still works
  • Unit tests validate both behaviors
  • Existing tests remain green

Helpful Context

Relevant modules:

services/tracking/tracker.py
services/detection/zones.py
libs/config/zone_loader.py

Metadata

Metadata

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions