mirror of
https://github.com/LmeSzinc/AzurLaneAutoScript.git
synced 2025-01-07 07:07:15 +08:00
Fix: Add atomic OCR method on client side
This commit is contained in:
parent
4e469098e2
commit
5aca54d438
@ -87,7 +87,6 @@ class Ocr:
|
||||
"""
|
||||
start_time = time.time()
|
||||
|
||||
self.cnocr.set_cand_alphabet(self.alphabet)
|
||||
if direct_ocr:
|
||||
image_list = [self.pre_process(i) for i in image]
|
||||
else:
|
||||
@ -96,7 +95,7 @@ class Ocr:
|
||||
# This will show the images feed to OCR model
|
||||
# self.cnocr.debug(image_list)
|
||||
|
||||
result_list = self.cnocr.ocr_for_single_lines(image_list)
|
||||
result_list = self.cnocr.atomic_ocr_for_single_lines(image_list, self.alphabet)
|
||||
result_list = [''.join(result) for result in result_list]
|
||||
result_list = [self.after_process(result) for result in result_list]
|
||||
|
||||
@ -254,4 +253,3 @@ class Duration(Ocr):
|
||||
|
||||
class DurationYuv(Duration, OcrYuv):
|
||||
pass
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user