Let’s dive in

In order to get a complete picture of where both of these libraries perform better, we need to analyze the results of these libraries comparatively.

Success for both — Total 164 (-43%)

A total of 164 images were recognized perfectly by both of these libraries. That's 43% less than iOS.

Failure for both — Total 161 (+20%)

161 image were detected with text, but neither libraries was able to recognize the text perfectly. ML Kit was better in this case, as it had a higher correctness rate.

Misery for both — Total 185 (-1233%)

In 185 images, neither of these libraries was able to detect the text in the image. This number is much higher when compared to iOS, and this can be alarming for mobile ML developers working on OCR tasks. We’ll produce another comparison concerning Firebase’s ML Kit, showing how its performance differs on both platforms.

Firebase was better — Total 130 (-58%)

In 130 images, Firebase’s ML Kit performed perfectly while Tesseract OCR was unable to recognize the text correctly or wasn’t able to detect text in an image.

Tesseract took the lead — Total 106 (+706%)

In 106 images, Tesseract OCR performed perfectly while Firebase’s ML Kit was unable to recognize text correctly. This show a massive boost in performance for Tesseract on Android as compared to iOS.

Some other aspects

As we discussed in our previous blog about the comparison on iOS, it’s not just about how well a library performed — at times there are parameters that might influence one’s decision to choose one library over the other.

App Size

Though we’re living in an age where manufacturers’ focus is on making devices more AI-efficient, there are a lot of people who still have low-end devices that don’t have a lot of space. Tesseract OCR adds more size to your app as compared to Firebase’s ML Kit. The DeltaML app using only Firebase’s ML Kit was 9.8MB while with Tesseract OCR it was 23.1MB. DeltaML is built using react native so this size includes the size of RN as well.

Custom Models

Just like on iOS, Tesseract OCR has its own set of models you can import into your project, as per your requirements. ML Kit, on the other hand, comes with its own pre-built models. However, if none of those meet your needs, you can use a custom TensorFlow model that requires a little bit of prior machine learning experience.

MICR Detections

While working on financial apps, one might need to read MICR (magnetic ink character recognition) from checks in their app. In Tesseract OCR, you can do it quite easily by importing this MICR model into your app and using it for detection. If you’re using ML Kit, you’ll have to employ TensorFlow along with a custom model to get it done.