mobassir94 / Multilingual-Reader

in this repository we will share our works related to multilingual document reading (english,bangla and arabic).this is a work in progress,we will gradually update the repo inshaa allah
4 stars 0 forks source link

High Accuracy but Slow inference #1

Open rm-asif-amin opened 5 months ago

rm-asif-amin commented 5 months ago

Hi, Thanks for sharing this. The architecture seems to have good accuracy but I'm getting very slow inference speed on GPU. (Changed on Easyocr and paddle settings to gpu).

For example extracting this text from an NID takes 53 seconds. Isn't ONNX supposed to be much faster(milliseconds)?

['RHrAT SEH',
 'গণপ্রজাতস্ত্রী বাংলাদেশ সরকার',
 "Govemm en OL the People's Republic of Bangladesh",
 'জাতায় পারচয়পত্র National ID Card',
 '12ay 1975',
 'EEN',
 'রোমানী রহমান',
 'Name',
 'ROMANA RAHMAN',
 'সোহরাব উদ্দীন খান',
 'Rret',
 'ফিরোজ্া বেগম',
 'Date NIDNO of Sinth 12May 867 367 1975 4936']
mobassir94 commented 5 months ago

Sorry,i Don't know how to make the inference much more faster

rm-asif-amin commented 5 months ago

Okay. It seems like the classifcation model is taking a while. Here's a breakdown -

Image loading time: 0.02506279945373535 Text detection time: 0.5832889080047607 Processing boxes time: 0.017578125 100%|██████████| 5/5 [01:22<00:00, 16.57s/it] Language classification time: 82.87071657180786 English processing time: 1.7918636798858643 Bangla processing time: 9.191173553466797