This commit is contained in:
Daniel 2024-11-27 20:13:22 +08:00
parent 18f68ac715
commit 7446599c0f
No known key found for this signature in database
GPG key ID: 86211BA83DF03017
18 changed files with 29 additions and 22 deletions

View file

@ -248,7 +248,7 @@ func Tesseract(imgAbsPath string) (ret []map[string]interface{}) {
ret = append(ret, dataMap)
}
tsv = gulu.Str.RemoveInvisible(tsv)
tsv = RemoveInvalid(tsv)
tsv = RemoveRedundantSpace(tsv)
msg := fmt.Sprintf("OCR [%s] [%s]", html.EscapeString(info.Name()), html.EscapeString(GetOcrJsonText(ret)))
PushStatusBar(msg)
@ -266,7 +266,7 @@ func GetOcrJsonText(jsonData []map[string]interface{}) (ret string) {
}
}
}
ret = gulu.Str.RemoveInvisible(ret)
ret = RemoveInvalid(ret)
ret = RemoveRedundantSpace(ret)
return ret
}