Table of Contents ▸ List of Commands ▸ Features Extraction ▸ matchpatch | ◀ patches | matchpatch_alt ▶ |
matchpatch | Built-in command |
Arguments:
- [patch_image],patch_width>=1,_patch_height>=1,_patch_depth>=1,_nb_iterations>=0,_nb_randoms>=0,_occurence_penalization,_output_score={ 0:No | 1:Yes },_[guide]
Description:
Estimate correspondence map between selected images and specified patch image, usinga patch-matching algorithm.
Each pixel of the returned correspondence map gives the location (p,q) of the closest patch in
the specified patch image. If output_score=1, the third channel also gives the corresponding
matching score for each patch as well.
If patch_penalization is >=0, SSD is penalized with patch occurrences.
If patch_penalization is <0, SSD is inf-penalized when distance between patches are less than -patch_penalization.
Default values:
patch_height=patch_width, patch_depth=1, nb_iterations=5, nb_randoms=5, occurence_penalization=0, output_score=0 and guide=(undefined).
Example of use:
image.jpg sample colorful +matchpatch[0] [1],3 +warp[-2] [-1],0