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
47d0927f
Unverified
Commit
47d0927f
authored
May 24, 2021
by
Double_V
Committed by
GitHub
May 24, 2021
Browse files
Merge pull request #2859 from WenmuZhou/fix_dataset
fix lable parse error when \r in the end of line
parents
7fd8d6a2
9497580d
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 addition
and
1 deletion
+1
-1
ppocr/data/simple_dataset.py
ppocr/data/simple_dataset.py
+1
-1
No files found.
ppocr/data/simple_dataset.py
View file @
47d0927f
...
...
@@ -74,7 +74,7 @@ class SimpleDataSet(Dataset):
data_line
=
self
.
data_lines
[
file_idx
]
try
:
data_line
=
data_line
.
decode
(
'utf-8'
)
substr
=
data_line
.
strip
(
"
\n
"
).
split
(
self
.
delimiter
)
substr
=
data_line
.
strip
(
"
\n
"
).
strip
(
"
\r
"
).
split
(
self
.
delimiter
)
file_name
=
substr
[
0
]
label
=
substr
[
1
]
img_path
=
os
.
path
.
join
(
self
.
data_dir
,
file_name
)
...
...
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