whatisgithub

What is mmocr?

open-mmlab/mmocr — explained in plain English

Analysis updated 2026-06-26

4,730PythonAudience · researcherComplexity · 4/5Setup · hard

In one sentence

A Python toolkit for finding, reading, and extracting structured data from text in images, covering text detection, text recognition, and key info extraction from documents.

Mindmap

mindmap
  root((MMOCR))
    What it does
      Find text in images
      Read text content
      Extract document data
    Tech Stack
      Python
      PyTorch
      OpenMMLab libraries
    Use Cases
      Receipt processing
      Document analysis
      Research experiments
    Audience
      Researchers
      ML developers
    Models
      DBNet PSENet
      CRNN ABINet
Click or tap to explore — scroll the page freely

Code map

Detail Auto

An interactive map of this repo's files and how they connect — its source is parsed live in your browser. Click Visualize to build it.

filefunction / class

What do people build with it?

USE CASE 1

Detect and read text in photos, scanned documents, or screenshots using pre-trained research models.

USE CASE 2

Extract structured data from receipts or forms, names, dates, totals, without manually typing them.

USE CASE 3

Run experiments comparing text-detection algorithms like DBNet and PSENet side-by-side using the same data pipeline.

USE CASE 4

Fine-tune or adapt published OCR models on your own labelled dataset.

What is it built with?

PythonPyTorch

How does it compare?

open-mmlab/mmocrqix-/better-exceptionscookiecutter-flask/cookiecutter-flask
Stars4,7304,7294,727
LanguagePythonPythonPython
Setup difficultyhardeasyeasy
Complexity4/51/52/5
Audienceresearcherdeveloperdeveloper

Figures from each repo's GitHub metadata at analysis time.

How do you get it running?

Difficulty · hard Time to first run · 1h+

Requires a conda environment and installing multiple OpenMMLab dependencies in a specific order before MMOCR itself.

So what is it?

MMOCR is a Python toolbox for reading and understanding text in images. It handles three related tasks: finding where text appears in an image (text detection), reading what the text says (text recognition), and pulling out structured information from documents like receipts or forms (key information extraction). The project is part of OpenMMLab, a research organization that builds open-source tools for computer vision tasks. The toolbox is built on top of PyTorch, which is a machine learning framework, along with several other OpenMMLab libraries. Because it depends on these specific frameworks, it is aimed at researchers and developers who already work in that ecosystem. Installation involves setting up a conda environment, installing the dependencies in a specific order, and then installing MMOCR itself. One of the main appeals of the toolbox is the range of published algorithms it includes. For text detection, it supports methods like DBNet, PSENet, PANet, TextSnake, and several others, many of which were published at major academic conferences. For text recognition, it includes CRNN, ABINet, SATRN, and more. These are research models that developers can use directly or adapt for their own data. A model zoo page in the documentation lists all supported algorithms with links to the original papers. The design is modular, meaning individual pieces such as the data loader, the model backbone, and the training loss function can be swapped out or replaced. This makes it easier to run experiments comparing different approaches without rewriting everything from scratch. Utility tools are included for visualizing what the model detects and for converting datasets into the format the toolbox expects. Version 1.0.0 was released in April 2023. Anyone coming from the older 0.6.3 version needs to follow a migration guide because the internal structure changed significantly. Documentation, tutorials, and a Jupyter notebook for getting started are all linked from the README.

Copy-paste prompts

Prompt 1
Using MMOCR, how do I run text detection on a folder of receipt images and export the bounding boxes to a CSV?
Prompt 2
Show me how to set up MMOCR with conda and run the DBNet text detector on a single image.
Prompt 3
I want to extract key fields like total amount and date from invoices using MMOCR's key information extraction. Walk me through the pipeline.
Prompt 4
How do I convert my custom labeled dataset into the format MMOCR expects for training a text recognition model?

Frequently asked questions

What is mmocr?

A Python toolkit for finding, reading, and extracting structured data from text in images, covering text detection, text recognition, and key info extraction from documents.

What language is mmocr written in?

Mainly Python. The stack also includes Python, PyTorch.

How hard is mmocr to set up?

Setup difficulty is rated hard, with roughly 1h+ to a first successful run.

Who is mmocr for?

Mainly researcher.

Open on GitHub → Ask about another repo

This repo across BitVibe Labs

Verify against the repo before relying on details.