docs: describe optional crop protocol and gallery cache
This commit is contained in:
parent
0d0e9f82b9
commit
2de5740922
2 changed files with 48 additions and 1 deletions
|
|
@ -64,6 +64,15 @@ cp "$HOME/.cache/huggingface/hub/models--timm--vit_small_patch14_dinov2.lvd142m/
|
|||
|
||||
`DORAYAKI_DINOV2_WEIGHTS` overrides that path. A file with any other sha256 is refused.
|
||||
|
||||
With the gallery identity backend, enrolled views are embedded into an ignored
|
||||
`stock-dir/.gallery_cache_<image_size>.npz` feature cache. The cache is reused
|
||||
only when its key matches the preprocessing version, image size, pinned DINOv2
|
||||
SHA-256, catalog CSV, enrolled SKU/view order and image bytes; its matrix shape,
|
||||
numeric finite values and row identities are also checked. A stale or malformed
|
||||
cache is rebuilt. A cache hit still checks the local model file's SHA-256, and
|
||||
gallery startup refuses readiness if the pinned weights or usable gallery are
|
||||
missing. OCR continues on the separate tag worker (`tag_executor`).
|
||||
|
||||
(`requirements-dev.txt` = `requirements.txt` + `httpx` cho test.)
|
||||
|
||||
### Bước 4: Khởi chạy recognition server
|
||||
|
|
@ -100,6 +109,11 @@ Camera trên điện thoại chỉ hoạt động khi trang mở bằng **https*
|
|||
|
||||
Server có REST + WebSocket đầy đủ, tài liệu chi tiết trong [`docs/API.md`](docs/API.md). Swagger UI: **http://127.0.0.1:8080/docs**.
|
||||
|
||||
Live WebSocket protocol `1` also supports an optional full-resolution crop lane:
|
||||
clients advertise `capabilities`, then answer per-track `crop_request` messages
|
||||
from their buffered capture. Clients without the capability are unchanged; wire
|
||||
examples, byte limits, expiry and errors are in [`docs/API.md`](docs/API.md#websocket-v1stream).
|
||||
|
||||
```bash
|
||||
# Nhận diện một ảnh kệ
|
||||
curl -X POST --data-binary @image.jpg -H 'Content-Type: image/jpeg' \
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue