Microsoft already has already developed an artificial intelligence application that turns images into descriptive text. For example, the software maker's Seeing AI app for Apple iOS devices turns images captured by the camera into text that is then spoken aloud to visually impaired users.
Now, the company's researchers have built a new AI system, simply dubbed "drawing bot," that can turn text descriptions into images.
Before coming full circle, Microsoft Research began its journey with CaptionBot, a machine learning technology that adds captions to photos. They then revisited the company's research on a neural network-based system that can process visual information as a human would and answers questions about a photo's content.
To flesh out the "drawing" part of the new AI app, Microsoft had to devise a technology that would essentially "imagine" or fill out details that may be missing from a caption.
That's where a technology known as a Generative Adversarial Network, or GAN, comes into play.
"The network consists of two machine learning models, one that generates images from text descriptions and another, known as a discriminator, that uses text descriptions to judge the authenticity of generated images," explained Microsoft in a Jan 18 announcement. "The generator attempts to get fake pictures past the discriminator; the discriminator never wants to be fooled. Working together, the discriminator pushes the generator toward perfection."
Microsoft trained the system using datasets comprised of image and caption pairs. It draws images much like an artistically-inclined person would, first creating a rough outline and repeatedly referring to the written description to fill out the finer details.
To turn long descriptions into detailed images, researchers created an attentional GAN, or AttnGAN, that mimics human attention and can break up a verbose sentence into individual words that are accurately represented as visual elements on-screen.
The end result, is a text-to-image system with a nearly three-fold increase in image quality compared to previous techniques, claims Microsoft. As shown in this announcement blog, it creates painterly images, in this case depicting a bird on a branch.
Microsoft's drawing bot isn't limited to visuals that are grounded in the real word. The technology can be used to generate fantastical scenes like "a floating double-decker bus," according to the company.
It can also fill in the blanks.
Returning to the bird example, the drawing bot typically draws birds perched on tree branches even if the input text doesn't even mention a branch. The system takes this liberty because many of the photos used to train the AI showed a bird sitting in a tree.
Although it may be a while before the company's text-to-image technology is used to paint masterpieces, Microsoft already foresees some practical applications. In the same way that Cortana and other virtual assistants help busy professionals plan their day and keep to a schedule, drawing bot's successors may someday act as a sketch assistant for painters or interior designers, the company said.
Microsoft published a research paper describing the AttnGAN technology behind the drawing bot.