Home Projects Pictotxt

Pictotxt

A python program which takes an image and outputs text in the form of the input image.

Github »

Tools:

Python

pictotxt is a python script which converts an image to text

pictotxt

How to use

Requirements:

git clone git@github.com:lazydancer/pictotxt.git
cd pictotxt
pip install -r requirements
python src/pictotxt.py examples/octocat.png

The result will be printed on your console/terminal

How it works

Input:

step1

The imported image is split up into ‘character sized’ images.

step2

Split of the font to get individual images of each character

For each mini-image from the imported image, compare it with all the characters and find the best match with the following function

step4

Result: