I am trying to do a simple area calculation of contours I get from findContours. My openCv version is 3.1.0
My code is:
cc = cv2.findContours(im_bw.c
In Opencv 3 API version the cv2.findContours() returns 3 objects
cv2.findContours()
So you need to rewrite your statement as:
image, contours, hierarchy = cv2.findContours(im_bw.copy(), cv2.RETR_TREE, cv2.CHAIN_APPROX_SIMPLE)