Commit
·
c71d0c1
1
Parent(s):
f5b6c1b
AWS Comprehend query numbers in logs should now add up correctly
Browse files- tools/file_redaction.py +1 -2
tools/file_redaction.py
CHANGED
@@ -952,7 +952,7 @@ def redact_image_pdf(file_path:str,
|
|
952 |
score_threshold=score_threshold
|
953 |
)
|
954 |
|
955 |
-
comprehend_query_number = comprehend_query_number_new
|
956 |
|
957 |
# redaction_bboxes = choose_redaction_method_and_analyse_pii(line_level_ocr_results,
|
958 |
# line_level_ocr_results_with_children,
|
@@ -1385,7 +1385,6 @@ def redact_text_pdf(
|
|
1385 |
'''
|
1386 |
|
1387 |
tic = time.perf_counter()
|
1388 |
-
comprehend_query_number_new = 0
|
1389 |
|
1390 |
# Open with Pikepdf to get text lines
|
1391 |
pikepdf_pdf = Pdf.open(filename)
|
|
|
952 |
score_threshold=score_threshold
|
953 |
)
|
954 |
|
955 |
+
comprehend_query_number = comprehend_query_number + comprehend_query_number_new
|
956 |
|
957 |
# redaction_bboxes = choose_redaction_method_and_analyse_pii(line_level_ocr_results,
|
958 |
# line_level_ocr_results_with_children,
|
|
|
1385 |
'''
|
1386 |
|
1387 |
tic = time.perf_counter()
|
|
|
1388 |
|
1389 |
# Open with Pikepdf to get text lines
|
1390 |
pikepdf_pdf = Pdf.open(filename)
|