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
40c49a7c
authored
2024-09-30 10:59:24 +0800
by
冯轩
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
MOD
1 parent
8a08f33f
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
1 deletions
src/apps/doc/management/commands/ocr_process.py
src/apps/doc/management/commands/ocr_process.py
View file @
40c49a7
...
...
@@ -1653,6 +1653,7 @@ class Command(BaseCommand, LoggerMixin):
'[error={4}]'
.
format
(
self
.
log_base
,
times
,
url
,
img_path
,
traceback
.
format_exc
()))
else
:
self
.
online_log
.
info
(
'{0} [ocr_1 start] [img={1}] [url={2}]'
.
format
(
self
.
log_base
,
img_path
,
url
))
ocr_1_res
=
ocr_1_response
.
json
()
end_time
=
time
.
time
()
speed_time
=
int
(
end_time
-
start_time
)
...
...
@@ -1699,8 +1700,9 @@ class Command(BaseCommand, LoggerMixin):
self
.
online_log
.
info
(
'{0} [res_2_wb] [get task] [queue running] [finish_queue_size={1}]'
.
format
(
self
.
log_base
,
finish_queue
.
qsize
()))
while
len
(
error_list
)
==
0
or
not
img_queue
.
empty
()
or
not
finish_queue
.
empty
():
try
:
self
.
online_log
.
info
(
'{0} [res_2_wb] [finish_queue.get1] [finish_queue_size={1}] [img_queue_size={2}]'
.
format
(
self
.
log_base
,
finish_queue
.
qsize
(),
img_queue
.
qsize
()))
task_str
=
finish_queue
.
get
(
block
=
False
)
self
.
online_log
.
info
(
'{0} [res_2_wb] [finish_queue.get]'
.
format
(
self
.
log_base
))
self
.
online_log
.
info
(
'{0} [res_2_wb] [finish_queue.get
2
]'
.
format
(
self
.
log_base
))
except
Exception
as
e
:
self
.
online_log
.
info
(
'{0} [res_2_wb] [queue empty]'
.
format
(
self
.
log_base
))
time
.
sleep
(
self
.
sleep_time_task_get
)
...
...
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