Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

save single char boxes #35

Open
wangwangww opened this issue Apr 22, 2020 · 6 comments
Open

save single char boxes #35

wangwangww opened this issue Apr 22, 2020 · 6 comments

Comments

@wangwangww
Copy link

In your code,it save words boxes. I want to save char boxes,how to do.

@Tetsujinfr
Copy link

the function to display bboxes and label text is actually in the code, look for function vis().
I just called it from the main function loop to output the post processed images as well as the text files.

@Tetsujinfr
Copy link

I attach a slightly modified inference file named test_net_bboxes.py , which calls the bounding box function and will output the text files as well as the images with bounding boxes with recognized text labels next to those.
Here is a video example of the result.

Hope this helps. Ciao
test_net_bboxes.zip

@wangwangww
Copy link
Author

I attach a slightly modified inference file named test_net_bboxes.py , which calls the bounding box function and will output the text files as well as the images with bounding boxes with recognized text labels next to those.
Here is a video example of the result.

Hope this helps. Ciao
test_net_bboxes.zip

ok,thank!

@Tetsujinfr
Copy link

I realise I read this issue a bit too quickly, I guess you meant to draw boxes for each character of a given word instead of a box for the full word.
That is not of interest to me but I guess you can tweak a bit the code, e.g. do a loop for a given word and divide the word box size by the number or letters of the word for the longest of the dimension of the parallelogram, and draw a box for each of those smaller parallelogram. If you want to leave a little gap between each box you will have to make an assumption for the margin to use.
This is a bit of a geometric hack but I would be surprised that the model returns character level information but I did not check that.

@harshdhamecha
Copy link

In case required, I have implemented it at here

@minyuping
Copy link

minyuping commented Jun 10, 2024 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants