Abstract
Generating recognizable sketches remains a challenge for sequence-based generative models, which often lack global spatial coherence. We present Sketch-Inspector, a hybrid architecture that augments the standard Sketch-RNN framework with a Convolutional Neural Network (CNN) "inspector." This inspector provides real-time visual feedback by evaluating the rendered canvas at each stroke iteration. Our results on the QuickDraw cat dataset show that Sketch-Inspector produces more stable and human-like sketches, increasing the fool rate against a trained discriminator from 7.4% to 13.6%.
Introduction
Sketching is a unique form of visual communication that relies on the sequential placement of strokes. While Recurrent Neural Networks (RNNs) like Sketch-RNN have successfully modeled the temporal nature of drawing, they often fail to maintain global proportions or semantic features, leading to abstract or messy outputs. Humans, by contrast, use visual feedback to adjust their drawings as they progress. In this work, we introduce a dual-decoder system that gives the AI an "eye" for its own work, ensuring that generated strokes contribute to a recognizable global structure.
Methodology
The Sketch-Inspector architecture is based on a Variational Autoencoder (VAE) with a novel dual-decoder design. As shown in Figure 1, the model combines sequential information with visual evaluation.
Dual-Decoder Architecture
The generation process is driven by two parallel components:
- RNN Decoder: This component processes the history of stroke coordinates to predict the next movement, maintaining the temporal logic of the drawing.
- CNN Inspector: At each step $i$, the strokes $[S'_0, S'_1, ..., S'_{i-1}]$ are rendered into a 128x128 image $I$. This image is processed by a six-layer CNN to extract spatial features.
- Integration: The outputs from the RNN and the CNN's fully connected (fc) layer are summed and passed to a Gaussian Mixture Model (GMM). The GMM then samples the coordinates for the next stroke $S'_i$.
CNN Inspector Details
The "inspector" is a deep convolutional network designed to recognize the semantic components of a sketch. As detailed in Figure 2, it utilizes six convolutional layers followed by a series of fully connected layers to transform the visual state of the canvas into a feedback signal for the mixture model.
Experimental Results
We evaluated Sketch-Inspector using the cat category of the QuickDraw dataset, training on 70,000 human-drawn sketches.
Quantitative Performance
To measure the "human-likeness" of the generated sketches, we employed a separate CNN discriminator. The discriminator was highly accurate at identifying human sketches (95.2%). However, it was significantly more likely to be fooled by Sketch-Inspector than by the baseline Sketch-RNN:
- Sketch-RNN Fool Rate: 7.4%
- Sketch-Inspector Fool Rate: 13.6%
Furthermore, the discriminator's accuracy dropped from 70.6% when evaluating Sketch-RNN to 63.2% for our model, indicating that Sketch-Inspector captures more human-like drawing patterns.
Qualitative Insights
Qualitative analysis revealed that Sketch-Inspector is more likely to include critical semantic features, such as eyes and whiskers, which are frequently omitted by sequence-only models. t-SNE visualizations of the latent space confirmed that our model produces more stable and consistent outputs, prioritizing recognizability over the unconstrained diversity seen in Sketch-RNN.
Conclusion
By incorporating a visual feedback loop, Sketch-Inspector bridges the gap between sequential stroke prediction and global image recognition. Although the inclusion of a CNN decoder increases computational cost—making the model approximately four times slower than the baseline—the significant improvement in sketch quality and recognizability justifies the overhead. Future research will focus on optimizing the rendering process and extending the model to more diverse object categories.
Summary updated