添加耗时到数据库,方便统计
This commit is contained in:
@@ -328,6 +328,7 @@ def main():
|
||||
for phhd in phhds:
|
||||
pk_phhd = phhd.pk_phhd
|
||||
logging.info(f"开始识别:{pk_phhd}")
|
||||
start_time = time.time()
|
||||
photo_review(pk_phhd)
|
||||
|
||||
# 识别完成更新标识
|
||||
@@ -335,7 +336,8 @@ def main():
|
||||
update_flag = (update(ZxPhhd).where(ZxPhhd.pk_phhd == pk_phhd).values(
|
||||
exsuccess_flag="8",
|
||||
ref_id1=HOSTNAME,
|
||||
checktime=util.get_default_datetime()))
|
||||
checktime=util.get_default_datetime(),
|
||||
fFSYLFY=time.time() - start_time))
|
||||
session.execute(update_flag)
|
||||
session.commit()
|
||||
session.close()
|
||||
|
||||
Reference in New Issue
Block a user