Image inpainting aims to restore the missing parts by using the known areas of the image to obtain reasonable content.It has important research value in the field of image processing and computer vision,and is also widely used in image editing and object removal.At present,in the field of image restoration,the restoration method based on deep learning is very popular and has achieved good results,but there are still many problems in the restoration of large-area damaged image.Aiming to solve the problems of texture blur and disordered structure in existing algorithms for repairing large-scale holes with complex backgrounds,a recurrent UNet inpainting algorithm based on Hybrid Dilated Convolution(HDC)and Propagation Consistent Attention(PCA)is proposed.Firstly,the recurrent U-Net implements partial convolution to preprocess the image to be repaired,normalize and update the mask and feature map,and then send the preprocessed feature map to the U-Net module,which consists of HDC and PCA for inference.After the inference is completed,the output feature map is fed to the module again for cyclic repairing,and the inference is performed step by step until the repair is completed.After the cycle is over,the output image is combined with features.Finally,the merged feature map is inputted to the post-processing module for up-sampling to obtain the inpainted result.The proposed model uses Group Normalization(GN)and smaller batches for training to speed up the iteration.The subjective and objective experimental results verify the performance of the proposed algorithm on Paris StreetView,an internationally recognized public street view dataset.The experimental results show that the proposed algorithm can effectively repair large-area irregular missing images with complex backgrounds,effectively avoid texture blur,and improve the accuracy of image structure.The peak signal-to-noise ratio(PSNR)and the structural similarity(SSIM)are superior over the comparison algorithms.Aiming at the problems of edge detail distortion and poor image coherence in existing algorithms for repairing large-scale holes,a recurrent U-Net inpainting algorithm based on PCA and a mixed loss function(Mix Loss,ML)is proposed.Firstly,product operation is performed to improve the learning ability of the model.Thereafter,the image is fed into the U-Net module based on PCA and multi-residual module for repairing,and the output image continues to be inputted into the U-Net loop.The output results are combined with features,and the combined image is subjected to a series of post-processing such as upsampling to obtain the final synthesis result.Finally,a hybrid loss function of absolute error and structural similarity is proposed to calculate the difference between the synthesized image and the original image,and to optimize the output result.The subjective and objective experimental results verify the performance of the proposed algorithm on the internationally recognized public face dataset CelebA.The experimental results show that the proposed algorithm can effectively repair largearea irregular missing images,effectively avoid edge detail distortion,and improve the coherence of structural details.Its peak signal-to-noise ratio(PSNR)and structural similarity(SSIM)are better than the comparison algorithms. |