Skip to content

Conversation

@fg-mindee
Copy link
Contributor

This PR introduces the following modifications:

  • fixes the crop extraction in OCRPredictor: the test is not always failing because this part is not executed if it didn't find any box. Fixed it by checking whether there is some, and if so removing the objectness before passing it
  • fixes the coord condition in unittesting: rarely but they can take the values 0 & 1, so the strict inequalities were changed to looser conditions.

Any feedback is welcome!

@fg-mindee fg-mindee added critical High priority module: models Related to doctr.models ext: tests Related to tests folder labels Jan 28, 2021
@fg-mindee fg-mindee added this to the 0.1.0 milestone Jan 28, 2021
@fg-mindee fg-mindee self-assigned this Jan 28, 2021
@codecov
Copy link

codecov bot commented Jan 28, 2021

Codecov Report

Merging #44 (db92989) into main (3868d9e) will increase coverage by 0.19%.
The diff coverage is 100.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##             main      #44      +/-   ##
==========================================
+ Coverage   97.75%   97.94%   +0.19%     
==========================================
  Files          20       20              
  Lines         534      536       +2     
==========================================
+ Hits          522      525       +3     
+ Misses         12       11       -1     
Impacted Files Coverage Δ
doctr/models/core.py 97.22% <100.00%> (+2.77%) ⬆️
doctr/models/detection/core.py 93.33% <100.00%> (ø)
...tr/models/detection/differentiable_binarization.py 98.18% <100.00%> (ø)
doctr/models/recognition/core.py 92.59% <100.00%> (ø)
doctr/models/recognition/crnn.py 100.00% <100.00%> (ø)
doctr/models/recognition/sar.py 100.00% <100.00%> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 5e467b7...db92989. Read the comment docs.

@charlesmindee charlesmindee merged commit df639ec into main Jan 28, 2021
@charlesmindee charlesmindee deleted the test-fix branch January 28, 2021 15:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

critical High priority ext: tests Related to tests folder module: models Related to doctr.models

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants