diff --git a/samples/python2/asift.py b/samples/python2/asift.py index 35c542e0e8242e983da77715dce8190c4e61286c..e7c2e7c1c214eb8ef150e4342233e3557c501c5d 100644 --- a/samples/python2/asift.py +++ b/samples/python2/asift.py @@ -3,8 +3,8 @@ Affine invariant feature-based image matching sample. This sample is similar to find_obj.py, but uses the affine transformation space sampling technique, called ASIFT [1]. While the original implementation -is based on SIFT, can try to use SURF or ORB detectors instead. Homography RANSAC -is used to reject outliers. Threaing is used for faster affine sampling. +is based on SIFT, you can try to use SURF or ORB detectors instead. Homography RANSAC +is used to reject outliers. Threading is used for faster affine sampling. [1] http://www.ipol.im/pub/algo/my_affine_sift/ @@ -101,11 +101,11 @@ if __name__ == '__main__': import sys, getopt opts, args = getopt.getopt(sys.argv[1:], '', ['feature=']) opts = dict(opts) - feature_name = opts.get('--feature', 'sift') + feature_name = opts.get('--feature', 'sift-flann') try: fn1, fn2 = args except: - fn1 = 'data/t4_0deg.png' - fn2 = 'data/t4_60deg.png' + fn1 = 'data/aero1.jpg' + fn2 = 'data/aero3.jpg' img1 = cv2.imread(fn1, 0) img2 = cv2.imread(fn2, 0) diff --git a/samples/python2/data/t4_0deg.png b/samples/python2/data/t4_0deg.png deleted file mode 100644 index 33b39e7400fa9fbb05e0301ca27f90d2c127c8e5..0000000000000000000000000000000000000000 Binary files a/samples/python2/data/t4_0deg.png and /dev/null differ diff --git a/samples/python2/data/t4_60deg.png b/samples/python2/data/t4_60deg.png deleted file mode 100644 index f906c43ae56da0a046c0bed57e83fded9f3e53f1..0000000000000000000000000000000000000000 Binary files a/samples/python2/data/t4_60deg.png and /dev/null differ diff --git a/samples/python2/find_obj.py b/samples/python2/find_obj.py index 1bbc93934826c1da6525b0772630a3bb8f14a9a9..bdc7e93b2299fc74986568231199f268e4765d47 100644 --- a/samples/python2/find_obj.py +++ b/samples/python2/find_obj.py @@ -118,6 +118,7 @@ def explore_match(win, img1, img2, kp_pairs, status = None, H = None): cv2.imshow(win, cur_vis) cv2.setMouseCallback(win, onmouse) + return vis if __name__ == '__main__':