Contenido principal

Shape Matching

R2026b
Detect and localize objects in images using edge-based shape matching
Since R2026b

Detect and localize objects in images using edge-based shape matching. Create shape models from template images, then search inspection images for object instances that match those models. Shape matching provides these capabilities:

  • 2-D pose estimation — Estimate the translation, rotation, and scale of each detected object instance.

  • Subpixel precision — Localize detected object instances with subpixel accuracy for measurement and alignment.

  • One-shot detection — Detect objects from a single visual example without additional training data.

  • Multi-class search — Search for multiple template classes in the same image.

  • Lighting invariance — Match based on edge orientation features rather than pixel intensity, robust to illumination changes.

Use shape matching when you need precise pose estimation from a single template image without large annotated data sets, such as detecting rigid objects with well-defined edges. Match results provide object locations with subpixel accuracy that you can use to position measurement tools for calibrated dimensional inspection.

Functions

expand all

shapemodelShape‑based model for object localization and image alignment
matchshapeFind and localize shape model instances in an image
showmatchesVisualize shape model matches in search image
showVisualize shape model edge features

Topics

Featured Examples