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
4b845ca1
Commit
4b845ca1
authored
Feb 08, 2021
by
tink2123
Browse files
fix attn encode
parent
895d44bc
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 addition
and
1 deletion
+1
-1
ppocr/data/imaug/label_ops.py
ppocr/data/imaug/label_ops.py
+1
-1
No files found.
ppocr/data/imaug/label_ops.py
View file @
4b845ca1
...
...
@@ -215,7 +215,7 @@ class AttnLabelEncode(BaseRecLabelEncode):
return
None
data
[
'length'
]
=
np
.
array
(
len
(
text
))
text
=
[
0
]
+
text
+
[
len
(
self
.
character
)
-
1
]
+
[
0
]
*
(
self
.
max_text_len
-
len
(
text
)
-
1
)
-
len
(
text
)
-
2
)
data
[
'label'
]
=
np
.
array
(
text
)
return
data
...
...
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