Remove background of scanned foot

alright, those aren’t determined by the bounding box as such… but they are the minimal and maximal points with respect to x or y, of all the points of a contour.

so you take a contour and you use python’s min or max with an appropriate key= predicate