摘要 |
PROBLEM TO BE SOLVED: To provide a method for removing horizontal and vertical lines in a document image while preserving integrity of the character strokes that intersect the lines.SOLUTION: For each detected horizontal line, a vertical run length profile is calculated. Areas of the run length profile having two adjacent peaks with a valley in between are detected, the areas corresponding to intersections of the horizontal line with non-vertical lines. A first derivative curve is used to detect such peaks and valleys. Areas of the run length profile with a large run length value for consecutive pixel locations are also detected, the areas corresponding to intersections of the horizontal line with near vertical lines. The horizontal line is removed outside the intersection areas, with pixels inside the intersection areas being preserved. Vertical line removal may be done similarly. This template-free method can remove lines in tables and forms and underlines and extract handwriting or printed characters. |