def __init__(self, descriptor_type):
self.rootsift = False
lists = ['sift','rootsift','orb','surf']
if descriptor_type is 'sift':
self.lfe = cv2.SIFT()
elif descriptor_type is 'surf':
self.lfe = cv2.SURF()
elif descriptor_type is 'rootsift':
self.lfe = cv2.SIFT()
elif descriptor_type is 'orb':
self.lfe = cv2.ORB()
else:
assert(descriptor_type in lists)
评论列表
文章目录