Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
wangsen
paddle_dbnet
Commits
8f7eb086
Unverified
Commit
8f7eb086
authored
May 29, 2020
by
Double_V
Committed by
GitHub
May 29, 2020
Browse files
Merge pull request #106 from LDOUBLEV/fixocr
fix multi-line txt display
parents
93601ec4
9058e002
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 addition
and
1 deletion
+1
-1
tools/infer/utility.py
tools/infer/utility.py
+1
-1
No files found.
tools/infer/utility.py
View file @
8f7eb086
...
...
@@ -227,7 +227,7 @@ def text_visual(texts, scores, img_h=400, img_w=600, threshold=0.):
first_line
=
False
else
:
new_txt
=
' '
+
txt
draw_txt
.
text
((
0
,
gap
*
(
count
+
1
)
),
new_txt
,
txt_color
,
font
=
font
)
draw_txt
.
text
((
0
,
gap
*
count
),
new_txt
,
txt_color
,
font
=
font
)
txt
=
tmp
[
img_w
//
font_size
-
4
:]
if
count
>=
img_h
//
gap
-
1
:
txt_img_list
.
append
(
np
.
array
(
blank_img
))
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment