diff --git a/pixelocr/page.py b/pixelocr/page.py index 5c280fd..7d9c45e 100644 --- a/pixelocr/page.py +++ b/pixelocr/page.py @@ -93,7 +93,7 @@ class Page(PageObject): @cached_property @collect_iterable def lines(self): - for line_img in self.image._iter_lines(min_space=2): + for line_img in self.image._iter_lines(min_space=2, min_height=10): yield Line(line_img) @@ -226,7 +226,7 @@ class Glyph(PageObject): self.top - 5, self.right + 5, self.top + 10, - ) and glyph.height > 3: + ) and glyph.height > 3 and self.optical_distance(glyph) < 4: return True # dot in ? and !