feature matching between image and video python

Solutions on MaxInterview for feature matching between image and video python by the best coders in the world

showing results for - "feature matching between image and video python"
Guadalupe
23 Nov 2020
1# create BFMatcher object
2bf = cv2.BFMatcher(cv2.NORM_HAMMING, crossCheck=True)
3
4# Match descriptors.
5matches = bf.match(des1,des2)
6
7# Sort them in the order of their distance.
8matches = sorted(matches, key = lambda x:x.distance)
9
10# Draw first 10 matches.
11img3 = cv2.drawMatches(img1,kp1,img2,kp2,matches[:10], flags=2)
12
13plt.imshow(img3),plt.show()
14