We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent bb80f82 commit 5666e9eCopy full SHA for 5666e9e
examples/ch2_harris_corners.py
@@ -0,0 +1,20 @@
1
+from pylab import *
2
+from numpy import *
3
+from PIL import Image
4
+
5
+from PCV.localdescriptors import harris
6
7
+"""
8
+Example of detecting Harris corner points (Figure 2-1 in the book).
9
10
11
+# open image
12
+im = array(Image.open('../data/empire.jpg').convert('L'))
13
14
+# detect corners and plot
15
+harrisim = harris.compute_harris_response(im)
16
+filtered_coords = harris.get_harris_points(harrisim, 10, threshold=0.01)
17
+harris.plot_harris_points(im, filtered_coords)
18
19
+# plot only 200 strongest
20
+harris.plot_harris_points(im, filtered_coords[:200])
0 commit comments