[Paper Review] AdaAttN: Revisit Attention Mechanism in Arbitrary Neural Style Transfer
AdaAttN introduces adaptive per-point attention normalization for arbitrary style transfer, leveraging both shallow and deep features to compute attention-weighted style statistics and a local feature loss for improved local quality.
Fast arbitrary neural style transfer has attracted widespread attention from academic, industrial and art communities due to its flexibility in enabling various applications. Existing solutions either attentively fuse deep style feature into deep content feature without considering feature distributions, or adaptively normalize deep content feature according to the style such that their global statistics are matched. Although effective, leaving shallow feature unexplored and without locally considering feature statistics, they are prone to unnatural output with unpleasing local distortions. To alleviate this problem, in this paper, we propose a novel attention and normalization module, named Adaptive Attention Normalization (AdaAttN), to adaptively perform attentive normalization on per-point basis. Specifically, spatial attention score is learnt from both shallow and deep features of content and style images. Then per-point weighted statistics are calculated by regarding a style feature point as a distribution of attention-weighted output of all style feature points. Finally, the content feature is normalized so that they demonstrate the same local feature statistics as the calculated per-point weighted style feature statistics. Besides, a novel local feature loss is derived based on AdaAttN to enhance local visual quality. We also extend AdaAttN to be ready for video style transfer with slight modifications. Experiments demonstrate that our method achieves state-of-the-art arbitrary image/video style transfer. Codes and models are available.
Motivation & Objective
- Motivate the need for better locality-aware arbitrary style transfer that preserves content while capturing local style patterns.
- Propose AdaAttN to compute per-point attention-weighted style statistics from both shallow and deep features.
- Normalize content features using per-point statistics to align with attention-weighted style statistics.
- Introduce a local feature loss to enhance local visual quality and extend the framework to video style transfer.
Proposed method
- Introduce AdaAttN module that learns an attention map from concatenated shallow and deep content/style features.
- Compute attention-weighted mean and variance maps of the style features using the attention scores.
- Normalizes content features using the per-point attention-weighted statistics to achieve local distribution alignment.
- Define a local feature loss that supervises the per-point style transformation for improved local fidelity.
- Extend the framework to video by incorporating cosine-based attention and an image-wise similarity loss to stabilize temporal consistency.
Experimental results
Research questions
- RQ1How can per-point, locality-aware statistics be used to improve arbitrary style transfer without sacrificing content structure?
- RQ2Can attention mechanisms that incorporate both shallow and deep features better capture local style patterns than global statistics-based methods?
- RQ3Does an attention-driven normalization with a local feature loss yield superior visual quality and temporal stability in video style transfer?
Key findings
- AdaAttN achieves state-of-the-art results in arbitrary image style transfer by aligning content features with attention-weighted per-point statistics of style features.
- The method preserves content structure while transferring detailed local style patterns, outperforming baselines in qualitative assessments.
- A local feature loss improves local visual quality and complements global style loss for better stylization results.
- Extension to video style transfer with cosine-based attention improves temporal stability without heavy reliance on optical flow.
- Ablation studies show the importance of shallow feature usage and the local feature loss for final quality.
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.