GEN_3 Positional Tracking: Memory Growth Issue

Thanks to the Stereolabs team for the great SDK, and for always being responsive to these reports — really appreciate the support.

I want to use POSITIONAL_TRACKING_MODE::GEN_3 for VIO only (DEPTH_MODE::NONE,
enable_area_memory=false, no spatial mapping). After running it for a few
minutes the pose output frequency keeps dropping. I investigated and found
that process memory (RSS) keeps climbing at the same time.

Setup

  • ZED2i, SDK 5.5.0
  • Jetson AGX Orin 32GB, JetPack 6.2.1 (L4T R36.4.4)
  • InitParameters: depth_mode=NONE
  • PositionalTrackingParameters: mode=GEN_3, enable_area_memory=false,
    enable_imu_fusion=true (default)
  • Loop: grab() + get_position() only, nothing else retrieved

Result (3 min, static camera, low-texture scene)

  • RSS: 143.6 MB → 253.0 MB, and the growth rate itself accelerates
    (0.48 MB/s in the first half → 0.82 MB/s in the second half)
  • Hz: 57.5 → 55.2, still declining (Although this isn’t a precise measurement, I have previously observed instances where the 120 Hz dropped to 30 Hz..)
  • get_positional_tracking_keyframes()/get_positional_tracking_landmarks()
    show the internal map growing the whole time: keyframes 4→274, landmarks
    55→365

Ruled out

  • Negative control (tracking disabled, grab() only): RSS stays flat
  • enable_imu_fusion=false: no improvement

Only mitigation I found: periodically calling reset_positional_tracking()
cuts the steady-state growth rate by ~90% (0.6–0.8 MB/s → ~0.05 MB/s) and
stops the Hz decline, at the cost of a brief (~2-4s) re-acquisition dip each
time. That’s a workaround, not a fix — and ideally I’d like to avoid it
entirely, since reset_positional_tracking() also resets the VIO coordinate
frame back to the origin each time (I passed an identity Transform in my
test). Is there a way to clear the internal map/keyframes without
discarding the current pose reference frame, or does passing the last known
pose as the Transform argument avoid that jump?

Questions:

  1. Is it expected/by-design for keyframes and landmarks to keep accumulating
    even with enable_area_memory=false, or should the internal map stay
    empty/bounded in this mode?
  2. Is there any way to get GEN_3 VIO (no area memory) with flat memory,
    without periodic resets?