Introduction
Neural Painting (NP) has revolutionized the way we think about digital art generation. By decomposing images into sequences of brushstrokes, NP models have achieved remarkable levels of realism. However, these systems have traditionally functioned as "black boxes"—autonomous agents that take a target image and produce a finished painting without any human intervention. This lack of interactivity limits their utility as creative tools.
In this paper, we introduce I-Paint, the first framework designed for Interactive Neural Painting (INP). Unlike its predecessors, I-Paint is designed to work alongside a human artist, suggesting the next set of strokes based on the current state of the canvas and the artist's intent.
The Challenge: Moving Beyond the Black Box
Existing NP methods typically rely on rigid, hierarchical grids or mathematically optimized sequences that do not reflect the human artistic process. A human painter might focus on a specific object, refine a texture, or move across the canvas in a way that prioritizes visual semantics over pixel-wise efficiency.
To create a truly interactive system, a model must be able to:
- Understand Context: Process the current state of the canvas and the artist's recent actions.
- Provide Multimodality: Offer multiple plausible suggestions rather than a single deterministic output.
- Generate Intuitive Strokes: Produce strokes that feel "human-like" in their placement, color, and order.
The I-Paint Architecture
The core of our approach is a conditional transformer-based Variational AutoEncoder (VAE). This architecture allows the model to handle the inherent uncertainty and creativity of the painting process.
1. Contextual Encoding
To generate relevant suggestions, I-Paint utilizes a Context Encoder. This component fuses three critical inputs: the reference image (the goal), the current state of the canvas, and the most recent strokes made by the user. By processing these through a Transformer, the model creates a rich "context vector" that informs the next steps.
2. Two-Stage Decoding
A significant innovation in I-Paint is its two-stage decoder. Rather than predicting all stroke parameters (color, size, shape, position) simultaneously, the model breaks the task down:
- Stage 1 (Positioning): The model first predicts the spatial coordinates of the next strokes.
- Stage 2 (Parameterization): Using bilinear sampling, the model "looks" at the reference image at the predicted positions to extract local features. It then determines the remaining parameters, such as color, orientation, and brush size. This "position-first" approach mimics the eye-to-hand coordination of a human artist.
3. Probabilistic Suggestions
Because I-Paint is built on a VAE, it can sample different points in its latent space. This allows the system to offer a variety of suggestions for any given context, empowering the user to choose the direction that best fits their vision.
Training for Human Intuition
A major hurdle in developing INP is the lack of datasets capturing the interactive painting process. To address this, we introduced two new benchmarks: ADE 20K Outdoor INP and Oxford-IIIT Pet INP.
To make these datasets effective for training, we developed a reordering algorithm. Standard synthetic stroke data is often chaotic; our algorithm re-sorts these strokes into sequences that group by object, color, and spatial proximity. This ensures the model learns to suggest strokes that feel natural to a human user. Furthermore, a "distribution matching loss" was implemented to ensure the suggested strokes maintain color consistency and local proximity rather than appearing as a scattered mess.
Evaluation and Results
We compared I-Paint against leading non-interactive models, including Paint Transformer (PT) and Stylized Neural Painting (SNP).
Quantitative Performance
I-Paint demonstrated superior performance across several key metrics:
- Frechet Stroke Distance (FSD) and Dynamic Time Warping (DTW): These metrics showed that I-Paint’s stroke characteristics and sequences were significantly more aligned with human-like painting patterns than the baselines.
- Diversity (LPIPS): Our model produced a wider variety of plausible suggestions, confirming the effectiveness of the VAE-based approach.
User Preference
In a blind user study, participants were asked to choose between suggestions from I-Paint and the baseline models. I-Paint was preferred 95% to 97% of the time. Users specifically noted that I-Paint’s suggestions felt more consistent with the subject matter and displayed better color and positional accuracy.
Conclusion
I-Paint represents a significant step toward AI-assisted creativity. By shifting the focus from autonomous reconstruction to interactive collaboration, we provide a tool that supports rather than replaces the artist. While the current model relies on synthetic reordered data and simplified brushstrokes, future work will explore more complex textures and integration into professional creative suites like Adobe Photoshop or Krita.
Summary updated