Neural Network Fonts

Tolle Arbeit von Erik Bernhardsson: 50k Fonts runterladen und ein Neural Network drüberjagen, woraus die AI schließlich eigene Schriftsätze generiert. Erinnert natürlich an die AI-Kanji vor ein paar Wochen, nur mit lateinischen Lettern.

To start with, let’s recreate real font characters with characters generated from the network. Let’s plot the real character together with the model outputs. For each pair below, the real character is on the left, the model output on the right.


These are all characters drawn from the test set, so the network hasn’t seen any of them during training. All we’re telling the network is (a) what font it is (b) what character it is. The model has seen other characters of the same font during training, so what it does is to infer from those training examples to the unseen test examples.

The network does a decent job at most of the characters, but gives up on some of the more difficult ones. For instance, characters with thin black lines are very hard to predict for the model, since if it renders the line just a few pixel to the side, that’s twice the loss of just rendering whitespace.

We can also interpolate between different fonts in continuous space. Since every font is a vector, we can create arbitrary font vectors and generate output from it. Let’s sample four fonts and put them in the corners of a square, then interpolate between them!