[Paper Review] Attention-aware Multi-stroke Style Transfer
This paper proposes an attention-aware multi-stroke style transfer model that integrates self-attention into a style-agnostic autoencoder to generate stylized images with consistent spatial attention and flexible multi-stroke fusion. By leveraging multi-scale style swapping and attention-guided fusion, the method enables automatic spatial stroke size control and produces high-quality, diverse stylizations comparable to state-of-the-art methods while maintaining real-time inference performance.
Neural style transfer has drawn considerable attention from both academic and industrial field. Although visual effect and efficiency have been significantly improved, existing methods are unable to coordinate spatial distribution of visual attention between the content image and stylized image, or render diverse level of detail via different brush strokes. In this paper, we tackle these limitations by developing an attention-aware multi-stroke style transfer model. We first propose to assemble self-attention mechanism into a style-agnostic reconstruction autoencoder framework, from which the attention map of a content image can be derived. By performing multi-scale style swap on content features and style features, we produce multiple feature maps reflecting different stroke patterns. A flexible fusion strategy is further presented to incorporate the salient characteristics from the attention map, which allows integrating multiple stroke patterns into different spatial regions of the output image harmoniously. We demonstrate the effectiveness of our method, as well as generate comparable stylized images with multiple stroke patterns against the state-of-the-art methods.
Motivation & Objective
- To address the lack of spatial attention consistency between content and stylized images in existing style transfer methods.
- To enable flexible multi-stroke fusion with varying levels of detail across different image regions.
- To achieve automatic spatial stroke size control without hand-crafted masks or per-region optimization.
- To maintain real-time inference speed while supporting arbitrary style transfer with multiple stroke patterns.
Proposed method
- Integrates a self-attention mechanism into the bottleneck of a style-agnostic autoencoder to learn global and long-range dependencies in content images.
- Derives an attention map from the content image via reconstruction training, highlighting salient and semantically relevant regions.
- Performs multi-scale style swapping by replacing high-level content features with multi-scale style features, generating distinct stroke pattern maps.
- Applies a learnable fusion strategy that combines multiple stroke patterns using the attention map as a spatial weight map for region-specific blending.
- Uses a Gaussian variance parameter in the attention filter to control the spatial granularity of stroke sizes automatically.
- Employs a feed-forward network architecture to enable real-time inference with controllable stroke count and detail level.
Experimental results
Research questions
- RQ1Can self-attention mechanisms improve spatial consistency of visual attention between content and stylized images in neural style transfer?
- RQ2How can multiple stroke patterns with varying sizes be flexibly fused across different image regions?
- RQ3Can stroke size be automatically adapted to image saliency without manual masks or region-specific processing?
- RQ4To what extent can multi-stroke fusion be controlled in terms of number of strokes and level of detail while maintaining real-time performance?
Key findings
- The proposed method achieves attention consistency, preserving salient regions in the stylized output with spatial alignment to the content image.
- With three strokes, the method takes 0.80 seconds on average for 256×256 images and 0.94 seconds for 512×512 images, outperforming Style-Swap and matching Avatar-Net in speed.
- The method enables automatic spatial stroke size control: fine strokes are applied to salient regions (e.g., human figures), medium to mid-saliency areas (e.g., mountains), and coarse strokes to low-saliency regions (e.g., sky).
- Multi-stroke fusion with increasing stroke count (up to 8) shows a controlled, linear increase in inference time (from 0.92s to 1.18s for 512×512), demonstrating scalability.
- The attention map enables region-specific fusion weights, allowing harmonious integration of multiple stroke patterns without visual artifacts or distortion.
- The model produces stylized images with diverse, perceptually plausible stroke patterns that are visually comparable to state-of-the-art methods, including AdaIN, WCT, and Avatar-Net.
Read this paper
Open the full text in the Nubint reader and ask about any passage as you read.
Read this paper on NubintThis review was generated by AI from the original paper. Please check the paper before citing it.