Abstract:To address the limitations of the existing deep learning methods in ancient mural restoration, such as insufficient consideration of stylistic features leading to style inconsistency, artifacts, and visual discontinuities in restored murals, we propose a style-guided and jointly modulated inpainting algorithm for ancient murals. Firstly, an encoder based on fast Fourier convolution residual blocks is constructed to extract multi-scale content features of damaged murals. Secondly, a style extraction network is designed to learn mural style features, coupled with a content-style attention module to establish correlations between stylistic and content features, thereby mitigating style inconsistency. Subsequently, a dual-stream decoder incorporating joint global-spatial modulation blocks is developed: global modulation enables semantic-aware structural synthesis, followed by spatial modulation that adaptively adjusts feature maps in a spatially adaptive manner to generate restored mural images. Finally, experimental validation on authentic Dunhuang murals demonstrates that the proposed method achieves superior style consistency in restored murals and outperforms comparative algorithms across objective evaluation metrics.