Offline CLIP image search for manufacturing defect photos: full pipeline walkthrough
OkShirt9372 · reddit · 2026-10-21
The author built a fully offline image search system for manufacturing inspection photos using CLIP ViT-B/32 + VectorAI DB, supporting queries by text description (e.g. "scratch on a metal component") or example photo, with MVTec AD as test data.
Pipeline: local setup (Docker DB, downloaded weights, runs offline) → CLIP image encoder produces normalized 512-dim vectors → stored with image path, part category and defect label → query via image or text encoder with metadata filtering → evaluation starts with whether top-5 results contain another image with the same defect label.
Key caveat: within a label like "scratch", size, location, orientation and severity vary widely, so relevance depends on multiple characteristics. A promising extension is localizing defect regions and embedding crops with varying context. The walkthrough also includes a FAISS comparison.
More from coding & agent
- Indie hacker ships 8 email product features in one drop with Opus, shares inbox open-rate data — marclou · 2026-10-21
- Solo dev runs 6,000+ unattended news episodes in 19 months — eval loops, not models — jwdNyc · 2026-10-21
- Free AI Search course covers Late Interaction, MUVERA scaling and Wormhole vectors — CShorten30 · 2026-10-21
- Reddit idea: a skills-equipped desktop client for ChinaAPI/SiliconFlow with 10-50% margins — Struggle_Wise · 2026-10-21
- Jac team rewrites compiler errors to link language docs, helping coding agents fix bugs — JaseciLabs · 2026-10-21
- NVIDIA's NOOA paper: agents as plain Python objects, combining six model-facing ideas in one surface — omarsar0 · 2026-10-21