mirror of
https://github.com/LmeSzinc/AzurLaneAutoScript.git
synced 2025-01-07 07:47:07 +08:00
Fix: jp commission suffix pre_process (#4435)
This commit is contained in:
parent
27b92c9b58
commit
52a29aa288
@ -41,8 +41,9 @@ class SuffixOcr(Ocr):
|
||||
# will need to pad white background for better recognization
|
||||
image = image[8:-10, :]
|
||||
cv2.normalize(image, image, -55, 255, cv2.NORM_MINMAX)
|
||||
image = (image > 128).astype(np.uint8) * 255
|
||||
image = np.pad(image, ((4, 4), (0, 0)), mode='constant', constant_values=255)
|
||||
image = (image > 80).astype(np.uint8) * 255
|
||||
image = np.pad(image, ((0, 1), (0, 0)), mode='edge')
|
||||
image = np.pad(image, ((4, 3), (0, 0)), mode='constant', constant_values=255)
|
||||
return image
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user