Merge pull request #75 from bertsky/recurse-regions

descend to all available TextRegions recursively
fix/readme-no-checkpoint
Mike Gerber 2 years ago committed by GitHub
commit 395e43c074
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -85,7 +85,7 @@ class CalamariRecognize(Processor):
page_image, page_coords, page_image_info = self.workspace.image_from_page( page_image, page_coords, page_image_info = self.workspace.image_from_page(
page, page_id, feature_selector=self.features) page, page_id, feature_selector=self.features)
for region in page.get_TextRegion(): for region in page.get_AllRegions(classes=['Text']):
region_image, region_coords = self.workspace.image_from_segment( region_image, region_coords = self.workspace.image_from_segment(
region, page_image, page_coords, feature_selector=self.features) region, page_image, page_coords, feature_selector=self.features)

Loading…
Cancel
Save