×

Document image segmentation based on pixel classification

  • US 9,715,624 B1
  • Filed: 03/29/2016
  • Issued: 07/25/2017
  • Est. Priority Date: 03/29/2016
  • Status: Active Grant
First Claim
Patent Images

1. A method implemented in a data processing apparatus for segmenting a document image containing a plurality of types of contents into multiple image segments, each image segment containing only one type of content, the method comprising:

  • (a) initializing a segmentation map having a size identical to that of the document image, by classifying each pixel of the document image into one of a plurality of pixel types based on content of the document image and assigning each pixel of the segmentation map a pixel type identical to the pixel type of the corresponding pixel of the document image, wherein the plurality of pixel types include at least a background pixel type, a first pixel type, and a second pixel type;

    (b) defining a working map, the working map being identical to the segmentation map as initialized in step (a);

    (c) for each of a plurality of pixel blocks in the working map, evaluating the pixels in the block, and based on the evaluation, assigning a pixel value to a pixel of a combined map corresponding to the block of the working map and assigning pixel values to pixels of a pixel block of the segmentation map that corresponds to the pixel of the combined map, including;

    (c1) when the plurality of pixels in the block of the working map include only the background pixel type, assigning the background pixel type to the corresponding pixel of the combined map, and keeping the pixel type of each pixel in the corresponding block of the segmentation map unchanged,(c2) when the plurality of pixels in the block of the working map include only the first pixel type or include only the first pixel type and the background pixel type, assigning the first pixel type to the corresponding pixel of the combined map, and assigning the first pixel type to each pixel in the corresponding block of the segmentation map,(c3) when the plurality of pixels in the block of the working map include only the second pixel type or include only the second pixel type and the background pixel type, assigning the second pixel type to the corresponding pixel of the combined map, and assigning the second pixel type to each pixel in the corresponding block of the segmentation map, and(c4) when the plurality of pixels in the block of the working map include both the first pixel type and the second pixel type or include an unknown pixel type, assigning the unknown pixel type to the corresponding pixel of the combined map, and keeping the pixel type of each pixel in the corresponding block of the segmentation map unchanged,whereby the combined map is generated and the segmentation map is modified;

    (d) repeatedly performing step (c) a number of rounds, each round using the combined map obtained from the last round as the working map, wherein in each round that step (c) is performed, the combined map is smaller in size than in the last round and each pixel block of the segmentation map that corresponds to a pixel of the combined map is larger in size than in the last round;

    (e) after step (d), changing pixel types of any pixels of the segmentation map that have the background type to one of the other types of the plurality of pixel types; and

    (f) segmenting the document image into the multiple image segments based on the segmentation map obtained in step (e), wherein each image segment corresponds to an area in the segmentation map that has only one type of pixels.

View all claims
  • 1 Assignment
Timeline View
Assignment View
    ×
    ×