Skip to content

Re-fit the view-dependent settings to the camera's zoom step from 2 to 3 - #200

Merged
ciaran-finnegan merged 1 commit into
masterfrom
camera/zoom-3-refit
Oct 9, 2026
Merged

ciaran-finnegan merged 1 commit into
masterfrom
camera/zoom-3-refit

Conversation

@ciaran-finnegan

Copy link
Copy Markdown
Owner

Why

The camera's zoom was stepped from position 2 to 3 at 08:45 today, to put more pixels on a plate at the stop. The silver pickup (172L66) stops with its plate 197–274 px wide, and on 6 Oct it waited about 50 s with 66 misread as 68/88/61. Settings fitted to the old view need re-fitting.

Measured

A 4K still at each position, matched with ORB features and a RANSAC similarity fit (1436 of 1500 matches were inliers). The analysis recovers a synthetic ×1.06 exactly.

zoom 2 zoom 3
focus (autofocus) 78 97
sharpness 0.233 0.234
scale 1 ×1.0556, centred at (0.501, 0.480), no rotation

What

  • GATE_LOCAL_SWEEP_CLOUD_MIN_PLATE_PX default 220 → 232 (×1.056).
  • GATE_EARLY_TRIGGER_PATCH default → 0,0.248,0.338,0.338: the same square, scaled and started at the left edge.
  • GATE_PLATE_REGION unchanged, on purpose. The sweep crops at native 4K and then scales to 1920. Mapping the band outward would cancel the gain exactly; keeping it in place passes the 5.6 % through. The ~2.5 % of scenery lost at each edge holds no measured plate position.
  • Camera notes: a new "Zoom step to position 3" section, covering the measurements, why each setting moved or didn't, the camera's own detection zone (unchanged, the lane stays inside it), the refocus nudge (now 3 → 4 → 3), and rollback.

Testing

Full suite 2489 OK (6 skipped). Defaults tests updated deliberately.

🤖 Generated with Claude Code

The zoom went from position 2 to 3 at 08:45 on 2026-10-09 to put more pixels
on a plate at the stop. Measured from a 4K still at each position (ORB
features, RANSAC similarity, 1436/1500 inliers): x1.0556 about frame point
(0.501, 0.480), no rotation; autofocus settled at 97 (was 78) and sharpness is
0.234 (was 0.233).

- GATE_LOCAL_SWEEP_CLOUD_MIN_PLATE_PX default 220 -> 232: every plate is
  5.6 % wider, so the same line between approach and stop is 232.
- GATE_EARLY_TRIGGER_PATCH default -> 0,0.248,0.338,0.338: the original
  square scaled by the same factor and started at the left edge, so its
  thumbnail keeps its 160x90 shape.
- GATE_PLATE_REGION deliberately unchanged: the sweep crops the band at
  native 4K and scales it to 1920, so mapping the band outward to the same
  scenery would cancel the gain; kept in place it passes the 5.6 % through,
  and the ~2.5 % of scenery it gives up at each edge holds no plate position
  measured so far.

Recorded in docs/reolink-rlc-811a.md ("Zoom step to position 3"), with the
camera's own detection zone (unchanged), the refocus nudge (now 3 -> 4 -> 3)
and the rollback.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@ciaran-finnegan
ciaran-finnegan merged commit c08040b into master Oct 9, 2026
5 checks passed
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 9, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-10-09T07:59:24.426328Z aa3e231 PR opened
🔒 Security Review ✅ Completed 2026-10-09T07:59:28.024592Z aa3e231 PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@coderabbitai

coderabbitai Bot commented Oct 9, 2026

Copy link
Copy Markdown

Review in Change Stack →

Note

Currently processing new changes in this PR. This may take a few minutes, please wait...

⚙️ Run configuration
  • Configuration used: defaults
  • Review profile: CHILL
  • Plan: Essentials
  • Run ID: 6ae29c68-717a-4160-8b64-9a2248dc3432

📥 Commits

Reviewing files that changed from the base of the PR and between 7bb189d and aa3e231.


📒 Files selected for processing (8)
  • .env.example
  • docs/early-trigger.md
  • docs/local-recognition.md
  • docs/reolink-rlc-810a.md
  • docs/reolink-rlc-811a.md
  • gate_controller/early_trigger.py
  • gate_controller/trigger_capture.py
  • tests/test_local_sweep.py

 _______________________________________________________________________________________________________________________________________________________________
< English is just a programming language. Write documents as you would write code: honor the DRY principle, use metadata, MVC, automatic generation, and so on. >
 ---------------------------------------------------------------------------------------------------------------------------------------------------------------
  \
   \   \
        \ /\
        ( )
      .( o ).
✨ Finishing Touches
📝 Generate docstrings
  • Commit to this branch
  • Create a new PR

🧪 Generate unit tests (beta)
  • Commit to this branch
  • Create a new PR


  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Comment @coderabbitai help to get the list of available commands.

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.

1 participant