## 2 Materials and Methods
### Sinogram Inpainting Generative Adversarial Network (SI-GAN)  
SI-GAN framework is shown in Figure 2. The network encoder module (a) is mainly used to extract the feature information of the limited-angle sinogram, to down-sample the lower-level mask and images layer by layer, and to learn a high-level compact latent feature. In order to overcome the limitation that encoder module (a) convolves layer by layer and cannot observe image features in the distance effectively, we added the attention module (b). By repeated use of attention network between adjacent layers of encoders and by learning the contents of the high-level semantic feature layer to fill the missing areas of the low-level feature layer, this cross-layer attention filling mechanism can achieve the mapping of high-level semantic features to low-level features, realize a higher resolution, and ensure the content consistency of the missing area. The method of this module drewn on the research of [PERSON] et al. [26] and the implementation details are shown in Figure 2 ATN. By calculating the area matching degree between the (\(3\times 3\)) patch inside and outside the missing hole area, the external feature information is transferred to the inside of the area. The calculation of the matching degree is gauged by cosine similarity:  
\[s_{i,\rho}^{k}=\left\langle\frac{q_{\rho,n}^{k}}{\|q_{\rho,n}^{k}\|},\frac{q_{ i,m}^{k}}{\|q_{i,m}^{k}\|}\right\rangle \tag{1}\]  
Figure 1: The flowchart of SIAR-GAN algorithm. where \(s^{k}_{i,o}\) represents cosine similarity, \(q^{k}_{o,u}\) denotes the \(n\)-th patch extracted outside the hole of the \(k\)-th high-level feature map, and \(q^{k}_{i,m}\) represents the \(m\)-th patch extracted from the inside of the hole of the \(k\)-th high-level feature map. The similarity scores are then processed with SoftMax to obtain the attention score, which is then weighted with the adjacent low-level feature map to fill the hole area:  
\[q^{k-1}_{i,m}=\sum_{n=1}^{N}\alpha^{k}_{i,o}q^{k-1}_{o,n} \tag{2}\]  
where \(\alpha^{k}_{i,o}\) represents the attention score calculated through the \(k\)-layer high-level feature map, \(q^{k-1}_{o,n}\) represents the \(n\)-th patch outside the hole of the \(k\)-1 st low-level feature map, and \(q^{k-1}_{i,m}\) represents the \(m\)-th patch inside the hole of the low-level feature map of the \(k\)-1 st layer. The same operation is performed on all patches of adjacent feature layers to obtain the attention-complemented low-level feature map. Finally, the transfer of the attention from the high-level feature map to the low-level feature map is accomplished. Decoder module (c) simultaneously receives feature images from encoder (a) and attention module (b) in a cross-layer connection. The output feature map of the previous layer of decoder and the output feature map of the corresponding layer of attention module are stacked back and forth, and then input to the next layer of decoder. This is continued recursively to complete filling the missing hole and to form a complete the whole sinogram. The multi-scale decoding module (d) generates images of different scales by convolving  
Figure 2: A diagram of the SI-GAN network framework. The network consists of 5 modules: (**a**) encoder module, (**b**) attention module, (**c**) decoder module, (**d**) multi-scale decoding module, and D discriminator module. with the feature maps of different layers of the decoder and establishes a more rigorous multi-scale loss, so that the model achieves better results. Unlike many GANs, the discriminator network (D) in this article will output an \(59\times 19\) image block instead of a single value. Each pixel value in the image block represents the true probability of the image within the corresponding receptive field in the original image. This regionally aware discriminator can improve the texture and semantic similarity between the generated image and the original image, so that the generated image can have a higher resolution and greater detail.