Author Login Chief Editor Login Reviewer Login Editor Login Remote Office

Computer Engineering ›› 2026, Vol. 52 ›› Issue (2): 197-208. doi: 10.19678/j.issn.1000-3428.0069830

• Computer Vision and Image Processing • Previous Articles    

Lightweight Photorealistic Image Style Transfer with Collaborative Optimization of Shuffle Gate Attention and Channel Alignment Whitening and Coloring Transform

LIU Huilin, FANG Qiong, WANG Yansi, ZHANG Shunxiang, SU Shuzhi   

  1. School of Computer Science and Engineering, Anhui University of Science and Technology, Huainan 232001, Anhui, China
  • Received:2024-05-09 Revised:2024-08-23 Published:2024-10-30

混洗门控注意力与通道对齐策略协同优化的轻量级真实图像风格迁移

刘惠临, 方琼, 王燕思, 张顺香, 苏树智   

  1. 安徽理工大学计算机科学与工程学院, 安徽 淮南 232001
  • 作者简介:刘惠临(CCF会员),高级实验师、博士,主研方向为计算机视觉、图像处理、多模态数据融合;方琼、王燕思,硕士研究生;张顺香(通信作者),教授、博士、博士生导师,E-mail:sxzhang@aust.edu.cn;苏树智,副教授、博士。
  • 基金资助:
    国家自然科学基金(52374155,62102003);安徽省自然科学基金(2308085MF218);安徽省智能感知与健康养老工程研究中心2022年度开放课题(2022OPB01)。

Abstract: Existing photorealistic image style transfer algorithms typically do not fully consider the issues of algorithm model size and computational efficiency while pursuing improvements in image realism and stylization intensity. Therefore, applying these methods to low computing power devices is difficult. To address this issue, this study proposes a lightweight real image style transfer algorithm. The VGG19 is replaced with the ShuffleNet V2 lightweight network as the feature extractor, with block-wise training and skip-connection techniques introduced to significantly reduce the number of parameters and improve the speed of image style transfer. To better balance the content and style of the transferred images, the study also proposes a Shuffle Gated Channel Attention Mechanism (SGCAM) and Channel Alignment Whitening and Coloring Transform (CAWCT). SGCAM combines channel shuffling with gating mechanisms efficiently, which not only enhances the realism of generated images but also further maintains the advantage of the lightweight algorithm. CAWCT significantly boosts the stylization intensity of the generated images by introducing binary operations to match the whitened content features and style features for similarity. Experimental results show that the parameter size of the proposed algorithm is only 14.8% of that of PhotoWCT2. It takes only 4.22 s to transfer an image with a resolution of 1 000×750 pixel, which is 0.79 s faster than that achieved by PhotoWCT2. Simultaneously, the quality and stylization strength of the generated images are significantly improved. In performance evaluations, the Structural Similarity Index Measure (SSIM) and Peak Signal-to-Noise Ratio (PSNR) indicators increase by 0.031 dB and 0.066 dB, respectively, while the Content loss, Gram loss, and Style loss metrics decrease by 0.227, 0.138×10-5, and 0.116, respectively.

Key words: style transfer, lightweight, ShuffleNet V2, channel attention, similarity match

摘要: 现有的真实图像风格迁移算法在追求提升图像的真实感和风格化强度的同时,通常未充分考虑算法模型尺寸和计算效率问题,因此很难适用于低算力设备。为解决这一问题,提出一种轻量级真实图像风格迁移算法。使用ShuffleNet V2轻量级网络替代VGG19作为特征提取器,并引入块式训练和跳跃连接技术,旨在大幅度减少参数量,提高图像的风格迁移速度。同时,为了更好地平衡迁移图像的内容和风格,设计混洗门控通道注意力机制(SGCAM)和通道对齐策略(CAWCT)。SGCAM将通道混洗和门控机制巧妙结合,不仅增强了生成图像的真实感,还进一步保持了算法轻量化的优势。CAWCT通过引入二值化操作对白化后的内容特征和风格特征进行相似性匹配,显著提升了生成图像的风格化强度。实验结果表明,所提算法的参数量仅为PhotoWCT2的14.8%,迁移一张1 000×750像素的图像只需4.22 s,比PhotoWCT2少0.79 s,同时生成图像的质量和风格化强度均得到明显提升,结构相似性(SSIM)和峰值信噪比(PSNR)指标分别提高0.031 dB和0.066 dB,内容损失(Content loss)、Gram损失(Gram loss)和风格损失(Style loss)指标分别降低0.227、0.138×10-5和0.116。

关键词: 风格迁移, 轻量级, ShuffleNet V2, 通道注意力, 相似性匹配

CLC Number: