MCPcopy Create free account
hub / github.com/PyImageSearch/imutils / __init__

Method __init__

imutils/feature/rootsift.py:8–15  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

6
7class RootSIFT:
8 def __init__(self):
9 # initialize the SIFT feature extractor for OpenCV 2.4
10 if is_cv2():
11 self.extractor = cv2.DescriptorExtractor_create("SIFT")
12
13 # otherwise initialize the SIFT feature extractor for OpenCV 3+
14 else:
15 self.extractor = cv2.xfeatures2d.SIFT_create()
16
17 def compute(self, image, kps, eps=1e-7):
18 # compute SIFT descriptors

Callers

nothing calls this directly

Calls 1

is_cv2Function · 0.85

Tested by

no test coverage detected