RapidAI / RapidTable

源自PP-Structure的表格识别算法,模型转换为ONNX,推理引擎采用ONNXRuntime,部署简单,无内存泄露问题。
Apache License 2.0
80 stars 9 forks source link

Python 3.12 problem with class RapidTable #4

Open rubenaros opened 2 months ago

rubenaros commented 2 months ago

Hi

With Python 3.12 the class RapidTable missing this atributtes:

'get_boxes_recs', 'load_img', 'ocr_engine',

With Python 3.12

table_engine = RapidTable(model_path='./models/table/en_ppstructure_mobile_v2_SLANet.onnx') dir(table_engine) 2024-09-12 15:23:06,914 - rapid_layout - INFO: pp_layout_cdla contains ['table'] ['call', 'class', 'delattr', 'dict', 'dir', 'doc', 'eq', 'format', 'ge', 'getattribute', 'getstate', 'gt', 'hash', 'init', 'init_subclass', 'le', 'lt', 'module', 'ne', 'new', 'reduce', 'reduce_ex', 'repr', 'setattr', 'sizeof', 'str', 'subclasshook', 'weakref', '_ocr', 'ocr_sys', 'table_matcher', 'table_structure']

With Python 3.11 : table_engine = RapidTable(model_path='./models/table/en_ppstructure_mobile_v2_SLANet.onnx') dir(table_engine) ['call', 'class', 'delattr', 'dict', 'dir', 'doc', 'eq', 'format', 'ge', 'getattribute', 'getstate', 'gt', 'hash', 'init', 'init_subclass', 'le', 'lt', 'module', 'ne', 'new', 'reduce', 'reduce_ex', 'repr', 'setattr', 'sizeof', 'str', 'subclasshook', 'weakref', 'get_boxes_recs', 'load_img', 'ocr_engine', 'table_matcher', 'table_structure']

Any solution?

Thanks in advance

Joker1212 commented 2 months ago

is it wrong for you to run table rec with py3.12?