'Computer-generated Handwriting

Are there any practical libraries for generating simulated handwriting from a string of text?

This does not mean using a handwriting-like font. Rather, I'm referring to handwriting where each letters is rendered slightly differently and connected as in the normal rhythm of human handwriting.



Solution 1:[1]

I've had some success using RNNLIB (original, Github fork) which uses AI neural networks.

There's a demo link on the Github readme and also at http://www.cs.toronto.edu/~graves/handwriting.html

Sample:

12345

Note that neither demo has particularly good support for numbers (mostly unreadable) and capital letters aren't as well covered as their lowercase counterparts. Sometimes the generated images can be missing letters or just trail off.

Since it's neural network based, it's likely that some of these problems are a result of or could be improved by training data.

Solution 2:[2]

You can take a look at Muse-CGH, an open source tool for stylish Computer Generated Handwritings.

Muse can synthesize stylish English handwriting from plain texts. Its algorithm carefully connects strokes of adjacent characters to create cursive words and uses random perturbations to ensure that every character is unique in the rendering results. Moreover, it can also generate handwriting animations!

Solution 3:[3]

Calligrapher AI lets you easily generate synthetic handwriting, with options to choose among several different styles:

screenshot

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1
Solution 2
Solution 3 GirkovArpa