Skip to content
Toggle navigation
Toggle navigation
This project
Loading...
Sign in
周伟奇
/
bmw-ocr
Go to a project
Toggle navigation
Toggle navigation pinning
Projects
Groups
Snippets
Help
Project
Activity
Repository
Graphs
Network
Create a new issue
Commits
Issue Boards
Files
Commits
Network
Compare
Branches
Tags
5c54f39e
authored
2021-04-16 12:32:28 +0800
by
周伟奇
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
fix bug
1 parent
e9d30c77
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
1 deletions
src/celery_compare/tasks.py
src/celery_compare/tasks.py
View file @
5c54f39
...
...
@@ -85,6 +85,7 @@ def field_compare(info_dict, ocr_res_dict, ocr_field, compare_list, res_set, has
def
usedcar_info_compare
(
info_dict
,
ocr_res_dict
,
ocr_field
,
compare_list
,
res_set
):
no_match_vino
=
[]
is_find
=
False
key_right
=
False
ocr_res_str
=
ocr_res_dict
.
get
(
ocr_field
)
if
ocr_res_str
is
not
None
:
ocr_res_list
=
json
.
loads
(
ocr_res_str
)
...
...
@@ -114,6 +115,8 @@ def usedcar_info_compare(info_dict, ocr_res_dict, ocr_field, compare_list, res_s
if
length
>
1
:
break
is_find
=
True
if
idx
==
0
and
compare_res
==
consts
.
RESULT_Y
:
key_right
=
True
info_dict
[
compare_tuple
[
4
]]
=
compare_res
if
input_str
is
not
None
:
if
idx
!=
0
:
...
...
@@ -130,7 +133,7 @@ def usedcar_info_compare(info_dict, ocr_res_dict, ocr_field, compare_list, res_s
continue
if
compare_tuple
[
0
]
in
info_dict
:
del
info_dict
[
compare_tuple
[
0
]]
return
is_find
,
no_match_vino
return
is_find
and
key_right
,
no_match_vino
@app.task
...
...
Write
Preview
Styling with
Markdown
is supported
Attach a file
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 post a comment