Files
effectcraft/crates
1ac3315ac4 SAM 2 tracking: prompt frames in frame order, no second fetch for the size check (#3030) (#3034)
* SAM 2 tracking: prompt frames in frame order, size-check frame reused (#3030)

With several objects prompted on three or more frames, the prompts went to
the tracker object by object. The tracker keeps features for two frames, so
every prompt after the first object fetched and encoded its frame again.
Each prompt frame was also fetched once only to check its size and then
fetched again for the encoder.

Prompts now go to the tracker in frame order (then object order), and the
frame fetched for the size check is handed to the tracker the first time it
asks for that frame (up to 256 MB of pixel data kept; beyond that the frame
is fetched again as before). Objects do not influence each other, so the
results are unchanged.

Tests cover the prompt order, one host fetch per prompt frame, the order of
several prompts of one object on one frame, and the memory cap.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>

* SAM 2 tracking test: the held-frame cap is cumulative

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>

---------

Co-authored-by: Claude Sonnet 5.5 <noreply@anthropic.com>
Co-authored-by: FredApps <153173854+FredApps@users.noreply.github.com>
2026-11-06 23:22:19 +01:00
..
2026-11-03 09:05:06 -05:00