Out-of bounds detection of a document in a live camera feed
First Claim
1. A computer-implemented method for processing digital images of a document, comprising:
- segmenting a first digital image of a document into pixels associated with a foreground of the first digital image and pixels associated with a background of the first digital image to produce a segmented first digital image;
detecting a plurality of contours in the segmented first digital image;
deciding, for each respective contour of the plurality of contours, whether the respective contour is an open contour or a closed contour;
creating a bounding rectangle for each respective contour of the plurality of contours;
computing an area of the bounding rectangle for each respective contour of the plurality of contours to identity a largest bounding rectangle;
determining that a side of a plurality of sides of the document is out-of-bounds based on whether the largest bounding rectangle bounds a respective contour of the plurality of contours that is an open contour;
informing a user that the document is out-of-bounds;
informing the user of which particular side of the plurality of sides of the document is out-of-bounds; and
directing the user to capture at least one additional image of the document.
1 Assignment
0 Petitions
Accused Products
Abstract
Aspects of the present disclosure provide methods and apparatuses for processing a digital image of a document, for example, to determine whether the document is a long document. An exemplary method generally includes obtaining a plurality of digital images of the document, segmenting at least a first digital image of the plurality of images into pixels associated with a foreground of the first digital image and pixels associated with a background of the first digital image, detecting a plurality of contours in the segmented first digital image, deciding, for each detected contour of the plurality of contours, whether that contour is an open contour or a closed contour, and determining that one or more sides of the document is out-of-bounds based, at least in part, on the decisions.
20 Citations
20 Claims
-
1. A computer-implemented method for processing digital images of a document, comprising:
-
segmenting a first digital image of a document into pixels associated with a foreground of the first digital image and pixels associated with a background of the first digital image to produce a segmented first digital image; detecting a plurality of contours in the segmented first digital image; deciding, for each respective contour of the plurality of contours, whether the respective contour is an open contour or a closed contour; creating a bounding rectangle for each respective contour of the plurality of contours; computing an area of the bounding rectangle for each respective contour of the plurality of contours to identity a largest bounding rectangle; determining that a side of a plurality of sides of the document is out-of-bounds based on whether the largest bounding rectangle bounds a respective contour of the plurality of contours that is an open contour; informing a user that the document is out-of-bounds; informing the user of which particular side of the plurality of sides of the document is out-of-bounds; and directing the user to capture at least one additional image of the document. - View Dependent Claims (2, 3, 4, 5, 6, 7, 8)
-
-
9. An apparatus for processing digital images of a document, comprising:
-
a processor; and a memory having instructions which, when executed by the processor, performs an operation for processing a digital image, the operation comprising; segmenting a first digital image of a document into pixels associated with a foreground of the first digital image and pixels associated with a background of the first digital image to produce a segmented first digital image; detecting a plurality of contours in the segmented first digital image; deciding, for each respective contour of the plurality of contours, whether the respective contour is an open contour or a closed contour; creating a bounding rectangle for each respective contour of the plurality of contours; computing an area of the bounding rectangle for each respective contour of the plurality of contours to identify a largest bounding rectangle; determining that a side of a plurality of sides of the document is out-of-bounds based on whether the largest bounding rectangle bounds a contour of the plurality of contours that is an open contour; informing a user that the document is out-of-bounds; informing the user of which particular side of the plurality of sides of the document is out-of-bounds; and directing the user to capture at least one additional image of the document. - View Dependent Claims (10, 11, 12, 13, 14, 15, 16)
-
-
17. A non-transitory computer-readable medium comprising instructions which, when executed on one or more processors, performs an operation for processing a digital image of a document, comprising:
-
segmenting a first digital image of a document into pixels associated with a foreground of the first digital image and pixels associated with a background of the first digital image to produce a segmented first digital image; detecting a plurality of contours in the segmented first digital image; deciding, for each respective contour of the plurality of contours, whether that the respective contour is an open contour or a closed contour; creating a bounding rectangle for each respective contour of the plurality of contours; computing an area of the bounding rectangle for each respective contour of the plurality of contours to identify a largest bounding rectangle; determining that a side of a plurality of sides of the document is out-of-bounds based on whether the largest bounding rectangle bounds a contour of the plurality of contours that is an open contour; informing a user that the document is out-of-bounds; informing the user of which particular side of the plurality of sides of the document is out-of-bounds; and directing the user to capture at least one additional image of the document. - View Dependent Claims (18, 19, 20)
-
Specification