Python: OpenCV: FeatureDetector / DescriptorExtractor

24 11 2012

20121124

cv2

ของจุดที่น่าสนใจด้วยวิธี cv2.FeatureDetector_create(detector)
และหา descriptor ด้วย cv2.DescriptorExtractor_create(detector)

code:

import cv2
image01 = r'D:\Phanu\research\PanoData\ladybug_Panoramic_5400x2700_00000097.jpg'
img = cv2.imread(image01)
detector = "SIFT"
sd = cv2.FeatureDetector_create(detector)
surf = cv2.DescriptorExtractor_create(detector)
keypoints = sd.detect(img)
l,d = surf.compute(img, keypoints)

เท่าที่ลอง  [“SIFT”,”SURF”,”ORB”] สามอย่างนี้ใช้ได้


Actions

Information

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s




%d bloggers like this: