Commit 191e9692 authored by Vadim Pisarevsky's avatar Vadim Pisarevsky

fixed angle check in squares.py (thanks to Abid Rahman)

parent 603e3e4b
......@@ -3,7 +3,7 @@ import cv2
def angle_cos(p0, p1, p2):
d1, d2 = p0-p1, p2-p1
d1, d2 = (p0-p1).astype('float'), (p2-p1).astype('float')
return abs( np.dot(d1, d2) / np.sqrt( np.dot(d1, d1)*np.dot(d2, d2) ) )
def find_squares(img):
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment