hezar.models.text_detection.craft.craft_utils module

CRAFT utility functions copied and modified based on https://github.com/clovaai/CRAFT-pytorch/blob/master/craft_utils.py

hezar.models.text_detection.craft.craft_utils.adjust_result_coordinates(polys, ratio_w, ratio_h, ratio_net=2)[source]
hezar.models.text_detection.craft.craft_utils.get_boxes_core(textmap, linkmap, text_threshold, link_threshold, low_text)[source]
hezar.models.text_detection.craft.craft_utils.get_detection_boxes(textmap, linkmap, text_threshold, link_threshold, low_text, poly=False)[source]
hezar.models.text_detection.craft.craft_utils.get_poly_core(boxes, labels, mapper)[source]
hezar.models.text_detection.craft.craft_utils.polys2boxes(polys: list)[source]
hezar.models.text_detection.craft.craft_utils.warp_coordinates(m_inv, pt)[source]