{"id":500,"date":"2017-04-04T13:17:42","date_gmt":"2017-04-04T13:17:42","guid":{"rendered":"http:\/\/liipetti.net\/erratic\/?p=500"},"modified":"2018-05-06T09:41:37","modified_gmt":"2018-05-06T09:41:37","slug":"learning-multiple-styles","status":"publish","type":"post","link":"https:\/\/liipetti.net\/erratic\/2017\/04\/04\/learning-multiple-styles\/","title":{"rendered":"Learning multiple styles at the same time?"},"content":{"rendered":"<p>New innovative GAN implementations are published every week. A particularly interesting one is <a href=\"https:\/\/github.com\/junyanz\/CycleGAN\" target=\"_blank\">CycleGAN<\/a>, which promises to learn to do transformations, similar to\u00a0what <a href=\"https:\/\/github.com\/phillipi\/pix2pix\" target=\"_blank\">pix2pix<\/a> does, but without needing pairs of corresponding images. In other words, it claims to be able to transform horses to zebras using a training set consisting of a) any horses and b) any zebras.\u00a0Also it also appears to manage transform a painting by Monet into a photo image.<\/p>\n<p>As the task of assembling a dataset of matching image pairs is often huge, being able to compose the datasets more freely feels a great advance. I was tempted to try what it can achieve if given a set of modern paintings of greatly varying style. So I assembled a set of 2000+ images of modern works of art, mostly but not exclusively paintings, and trained a CycleGAN using my own landscape photos as the other set, with the goal of seeing what this GAN would make of my photos. Will it make them look like art, and if so, in what style.<\/p>\n<p>The results are interesting, and many of them have the look of\u00a0works of art. Moreover, the style varies from image to image. One is tempted to think that the GAN has succeeded to match each image to those paintings which are most suitable as style models. Yet I am hesitant to make such a claim.<\/p>\n<p>The results as a whole do not look so modern as the dataset did. In particular, the abstract works seem to have had no visible effect. This is understandable, because even the authors of CycleGAN write that it performs well with transformations of color and texture, but fails when expected to transform larger structures (such as shape, I assume). This appears to be a general handicap with neural network based image transforms.<\/p>\n<p><a href=\"http:\/\/liipetti.net\/erratic\/wp-content\/uploads\/2017\/04\/Image079.png\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-501\" src=\"http:\/\/liipetti.net\/erratic\/wp-content\/uploads\/2017\/04\/Image079.png\" alt=\"Image079\" width=\"256\" height=\"256\" srcset=\"https:\/\/liipetti.net\/erratic\/wp-content\/uploads\/2017\/04\/Image079.png 256w, https:\/\/liipetti.net\/erratic\/wp-content\/uploads\/2017\/04\/Image079-150x150.png 150w\" sizes=\"auto, (max-width: 256px) 100vw, 256px\" \/><\/a> <a href=\"http:\/\/liipetti.net\/erratic\/wp-content\/uploads\/2017\/04\/Image087.png\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-large wp-image-502\" src=\"http:\/\/liipetti.net\/erratic\/wp-content\/uploads\/2017\/04\/Image087.png\" alt=\"Image087\" width=\"256\" height=\"256\" srcset=\"https:\/\/liipetti.net\/erratic\/wp-content\/uploads\/2017\/04\/Image087.png 256w, https:\/\/liipetti.net\/erratic\/wp-content\/uploads\/2017\/04\/Image087-150x150.png 150w\" sizes=\"auto, (max-width: 256px) 100vw, 256px\" \/><\/a> <a href=\"http:\/\/liipetti.net\/erratic\/wp-content\/uploads\/2017\/04\/IMG_0323.jpg\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-large wp-image-503\" src=\"http:\/\/liipetti.net\/erratic\/wp-content\/uploads\/2017\/04\/IMG_0323.jpg\" alt=\"IMG_0323\" width=\"256\" height=\"256\" srcset=\"https:\/\/liipetti.net\/erratic\/wp-content\/uploads\/2017\/04\/IMG_0323.jpg 256w, https:\/\/liipetti.net\/erratic\/wp-content\/uploads\/2017\/04\/IMG_0323-150x150.jpg 150w\" sizes=\"auto, (max-width: 256px) 100vw, 256px\" \/><\/a> <a href=\"http:\/\/liipetti.net\/erratic\/wp-content\/uploads\/2017\/04\/IMG_2809.jpg\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-large wp-image-504\" src=\"http:\/\/liipetti.net\/erratic\/wp-content\/uploads\/2017\/04\/IMG_2809.jpg\" alt=\"IMG_2809\" width=\"256\" height=\"256\" srcset=\"https:\/\/liipetti.net\/erratic\/wp-content\/uploads\/2017\/04\/IMG_2809.jpg 256w, https:\/\/liipetti.net\/erratic\/wp-content\/uploads\/2017\/04\/IMG_2809-150x150.jpg 150w\" sizes=\"auto, (max-width: 256px) 100vw, 256px\" \/><\/a> <a href=\"http:\/\/liipetti.net\/erratic\/wp-content\/uploads\/2017\/04\/IMG_2856.jpg\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-large wp-image-505\" src=\"http:\/\/liipetti.net\/erratic\/wp-content\/uploads\/2017\/04\/IMG_2856.jpg\" alt=\"IMG_2856\" width=\"256\" height=\"256\" srcset=\"https:\/\/liipetti.net\/erratic\/wp-content\/uploads\/2017\/04\/IMG_2856.jpg 256w, https:\/\/liipetti.net\/erratic\/wp-content\/uploads\/2017\/04\/IMG_2856-150x150.jpg 150w\" sizes=\"auto, (max-width: 256px) 100vw, 256px\" \/><\/a> <a href=\"http:\/\/liipetti.net\/erratic\/wp-content\/uploads\/2017\/04\/IMG_4054.jpg\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-large wp-image-506\" src=\"http:\/\/liipetti.net\/erratic\/wp-content\/uploads\/2017\/04\/IMG_4054.jpg\" alt=\"IMG_4054\" width=\"256\" height=\"256\" srcset=\"https:\/\/liipetti.net\/erratic\/wp-content\/uploads\/2017\/04\/IMG_4054.jpg 256w, https:\/\/liipetti.net\/erratic\/wp-content\/uploads\/2017\/04\/IMG_4054-150x150.jpg 150w\" sizes=\"auto, (max-width: 256px) 100vw, 256px\" \/><\/a> <a href=\"http:\/\/liipetti.net\/erratic\/wp-content\/uploads\/2017\/04\/k0709-115.png\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-large wp-image-507\" src=\"http:\/\/liipetti.net\/erratic\/wp-content\/uploads\/2017\/04\/k0709-115.png\" alt=\"k0709-115\" width=\"256\" height=\"256\" srcset=\"https:\/\/liipetti.net\/erratic\/wp-content\/uploads\/2017\/04\/k0709-115.png 256w, https:\/\/liipetti.net\/erratic\/wp-content\/uploads\/2017\/04\/k0709-115-150x150.png 150w\" sizes=\"auto, (max-width: 256px) 100vw, 256px\" \/><\/a> <a href=\"http:\/\/liipetti.net\/erratic\/wp-content\/uploads\/2017\/04\/k2006-491.png\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-large wp-image-508\" src=\"http:\/\/liipetti.net\/erratic\/wp-content\/uploads\/2017\/04\/k2006-491.png\" alt=\"k2006-491\" width=\"256\" height=\"256\" srcset=\"https:\/\/liipetti.net\/erratic\/wp-content\/uploads\/2017\/04\/k2006-491.png 256w, https:\/\/liipetti.net\/erratic\/wp-content\/uploads\/2017\/04\/k2006-491-150x150.png 150w\" sizes=\"auto, (max-width: 256px) 100vw, 256px\" \/><\/a> <a href=\"http:\/\/liipetti.net\/erratic\/wp-content\/uploads\/2017\/04\/k2006-559.png\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-large wp-image-509\" src=\"http:\/\/liipetti.net\/erratic\/wp-content\/uploads\/2017\/04\/k2006-559.png\" alt=\"k2006-559\" width=\"256\" height=\"256\" srcset=\"https:\/\/liipetti.net\/erratic\/wp-content\/uploads\/2017\/04\/k2006-559.png 256w, https:\/\/liipetti.net\/erratic\/wp-content\/uploads\/2017\/04\/k2006-559-150x150.png 150w\" sizes=\"auto, (max-width: 256px) 100vw, 256px\" \/><\/a> <a href=\"http:\/\/liipetti.net\/erratic\/wp-content\/uploads\/2017\/04\/m09-081.png\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-large wp-image-510\" src=\"http:\/\/liipetti.net\/erratic\/wp-content\/uploads\/2017\/04\/m09-081.png\" alt=\"m09-081\" width=\"256\" height=\"256\" srcset=\"https:\/\/liipetti.net\/erratic\/wp-content\/uploads\/2017\/04\/m09-081.png 256w, https:\/\/liipetti.net\/erratic\/wp-content\/uploads\/2017\/04\/m09-081-150x150.png 150w\" sizes=\"auto, (max-width: 256px) 100vw, 256px\" \/><\/a> <a href=\"http:\/\/liipetti.net\/erratic\/wp-content\/uploads\/2017\/04\/m09-129.png\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-large wp-image-511\" src=\"http:\/\/liipetti.net\/erratic\/wp-content\/uploads\/2017\/04\/m09-129.png\" alt=\"m09-129\" width=\"256\" height=\"256\" srcset=\"https:\/\/liipetti.net\/erratic\/wp-content\/uploads\/2017\/04\/m09-129.png 256w, https:\/\/liipetti.net\/erratic\/wp-content\/uploads\/2017\/04\/m09-129-150x150.png 150w\" sizes=\"auto, (max-width: 256px) 100vw, 256px\" \/><\/a> <a href=\"http:\/\/liipetti.net\/erratic\/wp-content\/uploads\/2017\/04\/mar05-0144.jpg\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-large wp-image-512\" src=\"http:\/\/liipetti.net\/erratic\/wp-content\/uploads\/2017\/04\/mar05-0144.jpg\" alt=\"mar05-0144\" width=\"256\" height=\"256\" srcset=\"https:\/\/liipetti.net\/erratic\/wp-content\/uploads\/2017\/04\/mar05-0144.jpg 256w, https:\/\/liipetti.net\/erratic\/wp-content\/uploads\/2017\/04\/mar05-0144-150x150.jpg 150w\" sizes=\"auto, (max-width: 256px) 100vw, 256px\" \/><\/a> <a href=\"http:\/\/liipetti.net\/erratic\/wp-content\/uploads\/2017\/04\/mar05-0204.jpg\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-large wp-image-513\" src=\"http:\/\/liipetti.net\/erratic\/wp-content\/uploads\/2017\/04\/mar05-0204.jpg\" alt=\"mar05-0204\" width=\"256\" height=\"256\" srcset=\"https:\/\/liipetti.net\/erratic\/wp-content\/uploads\/2017\/04\/mar05-0204.jpg 256w, https:\/\/liipetti.net\/erratic\/wp-content\/uploads\/2017\/04\/mar05-0204-150x150.jpg 150w\" sizes=\"auto, (max-width: 256px) 100vw, 256px\" \/><\/a> <a href=\"http:\/\/liipetti.net\/erratic\/wp-content\/uploads\/2017\/04\/Norge04b-162.png\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-large wp-image-514\" src=\"http:\/\/liipetti.net\/erratic\/wp-content\/uploads\/2017\/04\/Norge04b-162.png\" alt=\"Norge04b-162\" width=\"256\" height=\"256\" srcset=\"https:\/\/liipetti.net\/erratic\/wp-content\/uploads\/2017\/04\/Norge04b-162.png 256w, https:\/\/liipetti.net\/erratic\/wp-content\/uploads\/2017\/04\/Norge04b-162-150x150.png 150w\" sizes=\"auto, (max-width: 256px) 100vw, 256px\" \/><\/a> <a href=\"http:\/\/liipetti.net\/erratic\/wp-content\/uploads\/2017\/04\/resa03-0305.jpg\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-515\" src=\"http:\/\/liipetti.net\/erratic\/wp-content\/uploads\/2017\/04\/resa03-0305.jpg\" alt=\"resa03-0305\" width=\"256\" height=\"256\" srcset=\"https:\/\/liipetti.net\/erratic\/wp-content\/uploads\/2017\/04\/resa03-0305.jpg 256w, https:\/\/liipetti.net\/erratic\/wp-content\/uploads\/2017\/04\/resa03-0305-150x150.jpg 150w\" sizes=\"auto, (max-width: 256px) 100vw, 256px\" \/><\/a> <a href=\"http:\/\/liipetti.net\/erratic\/wp-content\/uploads\/2017\/04\/st2007-124.png\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-516\" src=\"http:\/\/liipetti.net\/erratic\/wp-content\/uploads\/2017\/04\/st2007-124.png\" alt=\"st2007-124\" width=\"256\" height=\"256\" srcset=\"https:\/\/liipetti.net\/erratic\/wp-content\/uploads\/2017\/04\/st2007-124.png 256w, https:\/\/liipetti.net\/erratic\/wp-content\/uploads\/2017\/04\/st2007-124-150x150.png 150w\" sizes=\"auto, (max-width: 256px) 100vw, 256px\" \/><\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<p>New innovative GAN implementations are published every week. A particularly interesting one is CycleGAN, which promises to learn to do transformations, similar to\u00a0what pix2pix does, but without needing pairs of corresponding images. In other words, it claims to be able to transform horses to zebras using a training set consisting \u2026<\/p>\n<p class=\"continue-reading-button\"> <a class=\"continue-reading-link\" href=\"https:\/\/liipetti.net\/erratic\/2017\/04\/04\/learning-multiple-styles\/\">Continue reading<i class=\"crycon-right-dir\"><\/i><\/a><\/p>\n","protected":false},"author":1,"featured_media":504,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[2,3],"tags":[],"class_list":["post-500","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-art","category-neural-networks"],"_links":{"self":[{"href":"https:\/\/liipetti.net\/erratic\/wp-json\/wp\/v2\/posts\/500","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/liipetti.net\/erratic\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/liipetti.net\/erratic\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/liipetti.net\/erratic\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/liipetti.net\/erratic\/wp-json\/wp\/v2\/comments?post=500"}],"version-history":[{"count":2,"href":"https:\/\/liipetti.net\/erratic\/wp-json\/wp\/v2\/posts\/500\/revisions"}],"predecessor-version":[{"id":518,"href":"https:\/\/liipetti.net\/erratic\/wp-json\/wp\/v2\/posts\/500\/revisions\/518"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/liipetti.net\/erratic\/wp-json\/wp\/v2\/media\/504"}],"wp:attachment":[{"href":"https:\/\/liipetti.net\/erratic\/wp-json\/wp\/v2\/media?parent=500"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/liipetti.net\/erratic\/wp-json\/wp\/v2\/categories?post=500"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/liipetti.net\/erratic\/wp-json\/wp\/v2\/tags?post=500"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}