Fix: bypass all doc_type

This commit is contained in:
dx-tan 2024-02-06 16:31:50 +07:00
parent 210ef22c64
commit 746cc0ce2b

View File

@ -117,7 +117,10 @@ def process_csv_feedback(csv_file_path, feedback_id):
_predict_result = copy.deepcopy(predict_result_to_ready(sub_rq.predict_result)) _predict_result = copy.deepcopy(predict_result_to_ready(sub_rq.predict_result))
_feedback_result = copy.deepcopy(sub_rq.feedback_result) _feedback_result = copy.deepcopy(sub_rq.feedback_result)
_reviewed_result = copy.deepcopy(sub_rq.reviewed_result) _reviewed_result = copy.deepcopy(sub_rq.reviewed_result)
image.processing_time = time_cost.get(image.doc_type, [0 for _ in range(image.index_in_request)])[image.index_in_request] try:
image.processing_time = time_cost.get(image.doc_type, [0 for _ in range(image.index_in_request)])[image.index_in_request]
except Exception as e:
print(f"[ERROR] image.doc_type: {image.doc_type} - image.index_in_request: {image.index_in_request} - time_cost: {time_cost} - {e}")
if not validate_feedback_file(_feedback_result, _predict_result): if not validate_feedback_file(_feedback_result, _predict_result):
status[request_id] = "Missalign imei number between feedback and predict" status[request_id] = "Missalign imei number between feedback and predict"
continue continue