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

Text Recognition: Add script to evaluate text recognition by ICDAR2003 #71

Merged
merged 3 commits into from
Sep 7, 2022

Conversation

Charles-258
Copy link
Contributor

No description provided.

@zihaomu zihaomu added the GSoC Google Summer of Code projected related label Jul 13, 2022
Copy link
Member

@zihaomu zihaomu left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for your contribution.
Some benchmark result should be added in README file.
Please refer to another PR #70.

tools/eval/datasets/icdar.py Outdated Show resolved Hide resolved
tools/eval/eval.py Show resolved Hide resolved
@fengyuentau fengyuentau added feature New feature or request evaluation adding tools for evaluation or bugs of eval scripts and removed feature New feature or request labels Jul 13, 2022
tools/eval/README.md Outdated Show resolved Hide resolved
@zihaomu zihaomu changed the title Add script to evaluate text recognition by ICDAR2003 OCR Recognition: Add script to evaluate text recognition by ICDAR2003 Jul 20, 2022
@zihaomu zihaomu changed the title OCR Recognition: Add script to evaluate text recognition by ICDAR2003 Text Recognition: Add script to evaluate text recognition by ICDAR2003 Jul 20, 2022
@@ -7,6 +7,15 @@ Notes:
- For details on training this model, please visit https://github.com/ShiqiYu/libfacedetection.train.
- This ONNX model has fixed input shape, but OpenCV DNN infers on the exact shape of input image. See https://github.com/opencv/opencv_zoo/issues/44 for more information.

Results of accuracy evaluation with [tools/eval](../../tools/eval).
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why do we change this file?

models/text_recognition_crnn/README.md Outdated Show resolved Hide resolved
@@ -54,7 +54,7 @@ def _preprocess(self, image, rbbox):
rotationMatrix = cv.getPerspectiveTransform(vertices, self._targetVertices)
cropped = cv.warpPerspective(image, rotationMatrix, self._inputSize)

if 'CN' in self._model_path:
if 'CN' in self._model_path or 'CH' in self._model_path:
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please add some comments about the difference between CN and CH.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@Charles-258 Kindly remainder.

@@ -53,3 +56,56 @@ Run evaluation with the following command:
python eval.py -m mobilenet -d imagenet -dr /path/to/imagenet
```

## WIDERFace
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please rebase, the PR of WIDERFace has been merged.

def __init__(self, root):
self.root = root
self.acc = -1
self.inputSize = [100, 32] #
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What does # mean?

@@ -54,7 +54,7 @@ def _preprocess(self, image, rbbox):
rotationMatrix = cv.getPerspectiveTransform(vertices, self._targetVertices)
cropped = cv.warpPerspective(image, rotationMatrix, self._inputSize)

if 'CN' in self._model_path:
if 'CN' in self._model_path or 'CH' in self._model_path:
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@Charles-258 Kindly remainder.

tools/eval/README.md Show resolved Hide resolved
tools/eval/datasets/__init__.py Show resolved Hide resolved
Copy link
Member

@zihaomu zihaomu left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM! 👍

@zihaomu zihaomu merged commit 370f75a into opencv:master Sep 7, 2022
@zihaomu zihaomu mentioned this pull request Sep 8, 2022
fengyuentau pushed a commit that referenced this pull request Jun 8, 2023
#71)

* update readme

* add another script

* revise details for this pr
@fengyuentau fengyuentau added this to the 4.9.0 (first release) milestone Dec 28, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
evaluation adding tools for evaluation or bugs of eval scripts GSoC Google Summer of Code projected related
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants