Generative zoology with neural networks

image



A couple of years ago, there was an article on my reading list called GAN Progress and Evolution to Improve Quality, Stability, and Increase Variation . It describes the gradual growth of generative adversarial networks that started out with low-resolution imagery and increased the granularity as learning progressed. Many publications have been devoted to this topic as the authors used their idea to create realistic and unique images of human faces.



image


Sample images generated by GAN



Looking at these images, it seems that other neural networks will need to study many examples to be able to create what GANs produce. Some factors seem to be relatively simple and well-founded in fact - for example, that the color of both eyes must match. But the other aspects are fantastically complex and very difficult to articulate. So, for example, what details are needed to tie the eyes, mouth and skin together into a complete facial image? Of course, I'm talking about the statistical machine as a person, and our intuition can deceive us - it may turn out that there are relatively few working variations, and the solution space is more limited than we imagine. Probably the most interesting thing is not the images themselves, but the terrible effect they have on us.



Some time later , my favorite podcast mentioned PhyloPic , a database of silhouette images of animals, plants, and other life forms. Reflecting on these lines, I wondered - what would happen if you train a system like the one described in the article "Progressive GANs" on a very diverse set of similar data? Will we end up with many varieties of several known types of animals, or will we have many variations that will give rise to speculative zoology driven by neural networks? No matter how it worked out, I was confident that I could get some good drawings from this for my study wall, so I decided to satisfy my curiosity with an experiment.





I adapted the code from the Progressive GAN article and trained the model through 12,000 iterations using the power of Google Cloud (8 NVIDA K80 GPUs) and the entire PhyloPic dataset. The total training time, including some mistakes and experiments, was 4 days. I used the final trained model to create 50K individual images and then spent hours looking through the results, categorizing, filtering, and matching the images. I also tweaked some of the images a bit, rotating them so that all the creatures face the same direction (to achieve visual satisfaction). This hands-on approach means that what you see below is a kind of collaboration between me and the neural network - it was creative work, and I made my own edits to it.



image







The first thing that surprised me was how aesthetically pleasing the results were. Much of this is certainly a reflection of the good taste of the artists who created the original images. However, there were also pleasant surprises. For example, it seems that whenever a neural network enters an area of ​​uncertainty - be it small pieces it hasn't mastered yet, or flights of blurry biological fantasy - chromatic aberrations appear in the image. This is curious because the input set is completely black and white, which means that color cannot be a solution to any generative problem that was adopted when training the model. Any color is a pure artifact of the machine mind. Surprisingly, one of the factors constantly causing chromatic aberration is the wings of flying insects. This leads to the factthat the model generates hundreds of variations of brightly colored "butterflies" like the ones shown above. I wonder if this could be a useful observation - if you train a model using only grayscale images and still require full color images to be output, then colored spots can be a useful way to show areas where the model is unable to accurately display the training set.



The bulk of the output is a huge variety of completely recognizable silhouettes - birds, various tetrapods, many small graceful carnivorous dinosaurs, lizard-legged, fish, beetles, arachnoids and humanoids.



image



Birds



image



Quadruped



image



Dinosaurs



image



Pisces



image



Beetles



image



Hominids



Weird things





As soon as the creatures we know end up, we are faced with unfamiliar things. One of the questions that came to me was this: Will there be plausible body plans of animals that do not exist in nature (perhaps hybrids of creatures included in the input dataset)? Through careful search and a little pareidolia, I discovered hundreds of four-legged birds, snake-headed deer and other fantastic monsters.



image



Monsters



Going even further into obscurity, the model gave rise to strange abstract patterns and unidentifiable entities that create a certain sense of their "liveliness".



image



Abstract creatures



image



Unidentifiable



Random sampling



What is not visible in the above images is the abundance of variation in the results. I have printed and and framed several of these sets of images, and the effect of hundreds of small, detailed images side by side at scale is quite amazing. To give some idea of ​​the scale of the full dataset, I include one of the printout examples below - this is a random sample from an unfiltered corpus of images.



image



image



Find out the details of how to get a high-profile profession from scratch or Level Up in skills and salary by taking SkillFactory's paid online courses:











All Articles