open-intelligence-backend icon indicating copy to clipboard operation
open-intelligence-backend copied to clipboard

Runtime error: Unable to run the code

Open drnko opened this issue 2 years ago • 0 comments

Getting below errors while running the following CLI:

python3 table_transformer.py --table-type borderless -i datasets/all_tables/2.png

======================================================================================================================== D:\OCRProjects\TableExtract> & 'C:\Program Files\Python310\python.exe' table_transformer.py --table-type borderless -i datasets/all_tables/2.png Traceback (most recent call last): File "D:\OCRProjects\TableExtract\table_transformer.py", line 35, in table = table_processor.get_table_from_image(image_path) File "D:\OCRProjects\TableExtract\domain\table_analysis\borderless_table_processor.py", line 15, in get_table_from_image text_boxes = self.get_text_boxes(preprocessed_image) File "D:\OCRProjects\TableExtract\domain\table_analysis\table_processor.py", line 33, in get_text_boxes boxes["conf"] = boxes["conf"].apply(lambda x: int(x)) File "C:\Users\Zahid\AppData\Roaming\Python\Python310\site-packages\pandas\core\series.py", line 4433, in apply return SeriesApply(self, func, convert_dtype, args, kwargs).apply() File "C:\Users\Zahid\AppData\Roaming\Python\Python310\site-packages\pandas\core\apply.py", line 1088, in apply return self.apply_standard() File "C:\Users\Zahid\AppData\Roaming\Python\Python310\site-packages\pandas\core\apply.py", line 1143, in apply_standard mapped = lib.map_infer( File "pandas_libs\lib.pyx", line 2870, in pandas._libs.lib.map_infer File "D:\OCRProjects\TableExtract\domain\table_analysis\table_processor.py", line 33, in boxes["conf"] = boxes["conf"].apply(lambda x: int(x)) ValueError: invalid literal for int() with base 10: '95.000000'

=========================================================================================================================

drnko avatar Dec 27 '22 14:12 drnko