Differentiable Drawing and Sketching

We present a bottom-up differentiable relaxation of the process of drawing points, lines and curves into a pixel raster. Our approach arises from the observation that rasterising a pixel in an image given parameters of a primitive can be reformulated in terms of the primitive’s distance transform, and then relaxed to allow the primitive’s parameters to be learned. This relaxation allows end-to-end differentiable programs and deep networks to be learned and optimised, and provides several building blocks that allow control over how a compositional drawing process is modelled. We emphasise the bottom-up nature of our proposed approach, which allows for drawing operations to be composed in ways that can mimic the physical reality of drawing rather than being tied to, for example, approaches in modern computer graphics. With the proposed approach we demonstrate how sketches can be generated by directly optimising against photographs and how auto-encoders can be built to transform rasterised handwritten digits into vectors without supervision. Extensive experimental results highlight the power of this approach under different modelling assumptions for drawing tasks.

[1]  Yann LeCun,et al.  The mnist database of handwritten digits , 2005 .

[2]  Ningyuan Zheng,et al.  StrokeNet: A Neural Painting Environment , 2018, ICLR.

[3]  Honggang Zhang,et al.  Universal Sketch Perceptual Grouping , 2018, ECCV.

[4]  Alex Lamb,et al.  Deep Learning for Classical Japanese Literature , 2018, ArXiv.

[5]  Joshua B. Tenenbaum,et al.  Human-level concept learning through probabilistic program induction , 2015, Science.

[6]  Jack Bresenham,et al.  Algorithm for computer control of a digital plotter , 1965, IBM Syst. J..

[7]  Alexei A. Efros,et al.  The Unreasonable Effectiveness of Deep Features as a Perceptual Metric , 2018, 2018 IEEE/CVF Conference on Computer Vision and Pattern Recognition.

[8]  Ulf Assarsson,et al.  Hair self shadowing and transparency depth ordering using occupancy maps , 2009, I3D '09.

[9]  Tao Xiang,et al.  Sketch-a-Net: A Deep Neural Network that Beats Humans , 2017, International Journal of Computer Vision.

[10]  David Salesin,et al.  Rendering parametric surfaces in pen and ink , 1996, SIGGRAPH.

[11]  Tatsuya Harada,et al.  Neural 3D Mesh Renderer , 2017, 2018 IEEE/CVF Conference on Computer Vision and Pattern Recognition.

[12]  David Salesin,et al.  Computer-generated pen-and-ink illustration , 1994, SIGGRAPH.

[13]  Xiaolin Wu An efficient antialiasing technique , 1991, SIGGRAPH.

[14]  Fisher Yu,et al.  Scribbler: Controlling Deep Image Synthesis with Sketch and Color , 2016, 2017 IEEE Conference on Computer Vision and Pattern Recognition (CVPR).

[15]  Tom Duff,et al.  Compositing digital images , 1984, SIGGRAPH.

[16]  Hao Li,et al.  Soft Rasterizer: A Differentiable Renderer for Image-Based 3D Reasoning , 2019, 2019 IEEE/CVF International Conference on Computer Vision (ICCV).

[17]  Masashi Sugiyama,et al.  Artist Agent: A Reinforcement Learning Approach to Automatic Stroke Generation in Oriental Ink Painting , 2012, ICML.

[18]  Vineeth N. Balasubramanian,et al.  Teaching GANs to sketch in vector format , 2019, ICVGIP.

[19]  Samuel B. Williams,et al.  ASSOCIATION FOR COMPUTING MACHINERY , 2000 .

[20]  Ravi Kiran Sarvadevabhatla,et al.  SketchParse: Towards Rich Descriptions for Poorly Drawn Sketches using Multi-Task Hierarchical Deep Networks , 2017, ACM Multimedia.

[21]  David G. Lowe,et al.  Distinctive Image Features from Scale-Invariant Keypoints , 2004, International Journal of Computer Vision.

[22]  Jimmy Ba,et al.  Adam: A Method for Stochastic Optimization , 2014, ICLR.

[23]  Kun Zhou,et al.  SketchGCN: Semantic Sketch Segmentation with Graph Convolutional Networks , 2020, ArXiv.

[24]  Eunbyung Park,et al.  Unsupervised Doodling and Painting with Improved SPIRAL , 2019, ArXiv.

[25]  Anil A. Bharath,et al.  Adversarial Training for Sketch Retrieval , 2016, ECCV Workshops.

[26]  Yoshua Bengio,et al.  Learning Phrase Representations using RNN Encoder–Decoder for Statistical Machine Translation , 2014, EMNLP.

[27]  Aaron Hertzmann,et al.  Painterly rendering with curved brush strokes of multiple sizes , 1998, SIGGRAPH.

[28]  Douglas Eck,et al.  A Neural Representation of Sketch Drawings , 2017, ICLR.

[29]  Eero P. Simoncelli,et al.  Image quality assessment: from error visibility to structural similarity , 2004, IEEE Transactions on Image Processing.

[30]  Tzu-Mao Li,et al.  Differentiable vector graphics rasterization for editing and learning , 2020, ACM Trans. Graph..

[31]  Matthias Bethge,et al.  ImageNet-trained CNNs are biased towards texture; increasing shape bias improves accuracy and robustness , 2018, ICLR.

[32]  Aaron Hertzmann,et al.  A survey of stroke-based rendering , 2003, IEEE Computer Graphics and Applications.

[33]  Peng Xu,et al.  Deep Learning for Free-Hand Sketch: A Survey , 2020, ArXiv.

[34]  Sang Min Yoon,et al.  SketchHelper: Real-Time Stroke Guidance for Freehand Sketch Retrieval , 2019, IEEE Transactions on Multimedia.

[35]  Oriol Vinyals,et al.  Synthesizing Programs for Images using Reinforced Adversarial Learning , 2018, ICML.

[36]  Tao Xiang,et al.  Learning Deep Sketch Abstraction , 2018, 2018 IEEE/CVF Conference on Computer Vision and Pattern Recognition.

[37]  Ivan E. Sutherland,et al.  Sketchpad a Man-Machine Graphical Communication System , 1899, Outstanding Dissertations in the Computer Sciences.

[38]  Reiichiro Nakano,et al.  Neural Painters: A learned differentiable constraint for generating brushstroke paintings , 2019, ArXiv.

[39]  Jie Yang,et al.  Sketchsegnet: A Rnn Model for Labeling Sketch Strokes , 2018, 2018 IEEE 28th International Workshop on Machine Learning for Signal Processing (MLSP).