Releases: machinefi/trio-retina
v0.3.0 — the world-model release
pip install -U trio-retina
The state layer of the world-model stack — now with shipped latent producers and a front-to-back demo, a CLI, a typed package, and a pre-launch hardening pass.
Added
- Latent producers ship —
DinoV2Embedder(per-objectentity.vec) andVJepa2Embedder(scene-levelws.scene): bring any encoder, out comes one standardizedWorldState.pip install 'trio-retina[dino]'/[vjepa]. - The world-model stack, end to end — swap the encoder (YOLO · DINOv2 · V-JEPA 2 → same schema), a small transformer imagines the future off that state, front+back compose through one standard (
examples/world_model/,BENCHMARK.md). Flagship soccer demo: real footage → WorldState → predicted player runs. retinaCLI —retina demo/run/validate/bench(stdlib-only).- Typed package (
py.typed) + concise__repr__s; sample assets (retina.sample_events()/sample_video()); deeper docs (concepts · cookbook · cli · extend · faq).
Fixed (pre-launch hardening)
WorldState.from_frameno longer crashes on extravec/scenekeys;LineRulepending-state leak + debounce/direction edge cases;schema.validaterejectsbool-as-number / badbox/ non-object input;Detection.from_supervisionshort-class_nameIndexError;WebhookSinkrejects non-http(s)schemes.
Changed
[all]now includesmatplotlib; honesty/wording fixes across docs.
Full notes: CHANGELOG.md
v0.2.1
Polish + edge-hardening release. pip install trio-retina
Changed
- RTSP/edge hardening —
video_framesno longer dies on a transient live (rtsp:///live=True/ webcam) read failure: it reconnects with exponential backoff and drops to the latest frame under back-pressure. Finite files unchanged (real EOF still ends the stream, every frame delivered). - README/docs headline quickstart now runs on a bare
pip install trio-retina(numpy only, no model/GPU/video) — the YOLO + video form moved to a labeled secondary block. CountRule(3)works (threshold is now positional);CountRule(threshold=3)unchanged.
Added
examples/bench_overhead.py— honest numpy-only micro-benchmark of the Retina-layer overhead (tracker + rules + event build, detector excluded): ~0.08 ms/frame at 20 tracks.tests/test_sources.py— live-source reconnect / drop-to-latest tested via a fake-capture seam (no cv2, no real RTSP).- Colab notebooks (
notebooks/) and the docs site synced.
Full notes: CHANGELOG.md
v0.2.0
Trio Retina — the model-agnostic state layer for world models. Turn any detector (YOLO · VLM · DINO) into one standard, queryable stream of events + latent state. numpy-only core.
📦 First PyPI release:
pip install trio-retina
Added
Detection.from_supervision()— ingest a Roboflowsv.Detections(duck-typed, nosupervisionimport), so Supervision pipelines plug straight into Retina's event layer.LineRule(min_frames=...)— confirm a crossing only after N frames on the new side, suppressing jitter near the tripwire.- Hero examples (run with no model / GPU / network):
examples/rtsp_to_webhook.py(camera → restricted-zone alert → webhook),examples/from_supervision.py, andexamples/latent_vec.py(populate the latentvecchannel yourself).
Changed
- Distribution renamed to
trio-retina(import staysimport retina). [all]extra now installs every optional adapter (incl. Grounding DINO).- Honesty pass: dropped the unreproducible forecast number; latent channel documented as a shipped interface with producers on the roadmap.
Full notes: CHANGELOG.md
v0.1.0 — first public release
Trio Retina is the model-agnostic state layer for world models: turn any detector (YOLO · VLM · DINO) into one standard, queryable stream of events + latent state. numpy-only core, runs on CPU at the edge.
pip install "retina-sdk @ git+https://github.com/machinefi/trio-retina" # core: numpy onlyA PyPI
retina-sdkrelease is landing shortly.
Highlights
- The
retina.eventstandard — tiny, JWT-like; ships a JSON Schema + pure-Python validator. - Composable pipeline — wire detectors/trackers/rules/gates/enrichers/sinks with
|, a node list, or a JSON workflow. - Detectors: YOLO (Ultralytics), open-vocab (Grounding DINO), any VLM, or any
callable(image)->[Detection]. Trackers: IoU (pure-Python) + Norfair. - Rules:
zone.enter/line.cross/dwell/count— now withexit_grace_s(rides out detection blips / id flicker) andanchor(center/feet/head). - Dual state — symbolic events plus an optional latent (
Vec) channel, never collapsed. - Demos (all run with no model / no GPU): forecast (dynamics on
WorldState) and a live iTwin.js digital-twin overlay.
Developer experience
pytestruns on a bare checkout (justpip install numpy pytest).make test / lint / format / docs / build; pre-commit config; CI across Python 3.10–3.13.
Full notes in CHANGELOG.md.