Google Cloud Vision API : OCR text detection giving inaccurate result- Node JS

Viewed 140

I have used the below code to perform text detection on the image.

const client = await new vision.ImageAnnotatorClient({ credentials });
const [result] = await client.textDetection(path);
console.log(result.textAnnotations);

the intended result is BBTPB9999Q but the program output is BBTPB9999C

Is there any way to improve the accuracy?

1 Answers

From my experience the quality of the pictures matters. So I think improving quality of analyzed image is only way to improve results of detection when it comes to descriptions similar to your example, like serial numbers etc. Once I had an idea to try to convert images before, ex. make them monochrome, however I never got test results worth implementing. You may try this...

At the moment, in Google Cloud Vision, only way to improve the the result for the same picture is to Specify the language, however this will work only when you want to detect text in already known language.

Related