OCR Tools

Machine Learning in Linux: EasyOCR – OCR that reads natural scene text and dense text in documents

Our Machine Learning in Linux series focuses on apps that make it easy to experiment with machine learning.

EasyOCR is a Python module for extracting text from images. It is a general OCR that can read both natural scene text and dense text in documents. The software supports more than 80 languages. It’s free and open source software.

Installation

We tested EasyOCR with PCs running Ubuntu and Manjaro including a machine with an NVIDIA GeForce RTX 3060 Ti dedicated graphics card, and an Intel NUC 13 Pro which only has onboard Intel Iris Xe. We’ll go through installing the GPU and CPU versions of PyTorch.

There are a variety of ways of installing EasyOCR without polluting our machines. We’ll install EasyOCR in a isolated Python environment.

$ sudo apt install python3-venv -y

$ mkdir pytorch_env
$ cd pytorch_env

Create the environment:

$ python3 -m venv pytorch_env
$ source pytorch_env/bin/activate

To install PyTorch with GPU support, issue the command:

$ pip install torch torchvision torchaudio

If your machine doesn’t have a dedicated graphics card, issue the following command instead.

$ pip install torch torchvision torchaudio --index-url https://download.pytorch.org/whl/cpu

We can now install EasyOCR with the command:

$ pip install easyocr

Here’s the final page of the installation.

Installing EasyOCR

Next page: Page 2 – In Operation and Summary

Pages in this article:
Page 1 – Introduction and Installation
Page 2 – In Operation and Summary

Subscribe
Notify of
guest

This site uses Akismet to reduce spam. Please read our FAQ before making a comment.

0 Comments
Oldest
Newest Most Voted
Inline Feedbacks
View all comments