# Development of Artificial Intelligence-Based Dual-Energy Subtraction for Chest Radiography
## 2 Materials and Methods
### Performance Evaluation  
We evaluated similarity between real and virtually generated 60 kV images for the test dataset cases. In addition, image quality of soft-tissue- and bone-enhanced images generated by our AI-DES was evaluated based on their similarity to those obtained by Discovery XR656, which is assumed to be the ground truth. Frechet inception distance (FID) has been widely used for performance evaluation of GAN models [40; 41]. However, this metric measures distances between synthetic and real data distributions; that is, FID evaluates not the similarity between each real and fake sample but the entire similarity between the two groups. Hence, we evaluated the similarity between each generated image and its corresponding ground truth using the peak signal-to-noise ratio (PSNR), structural similarity (SSIM) [42; 43], and multiscale SSIM (MS-SSIM) [44] instead of FID. PSNR is an index based on the perceived sensitivity of noise components. It calculates the noise ratio relative to the maximum value between two images in decibels, as follows:  
\[PSNR=20\log_{10}\left(\frac{P_{max}}{MSE}\right), \tag{11}\]  
where MSE is the mean square error (MSE) between two images, and \(P_{max}\) is the maximum value of the image pixels. In this study, \(P_{max}\) was set to 1 because we normalized the pixel values of each image dataset, as mentioned previously in Section 2.3. The higher the value of PSNR, the more similar the two images are. SSIM assumes image similarity using three components of brightness, contrast, and structure [42]. It has been reported that SSIM is more consistent with human perception and subjective evaluation than PSNR [45]. The images become more similar when the SSIM value is closer to 1. SSIM is calculated by dividing each region of interest (ROI) and averaging the respective SSIM values to estimate the overall similarity between the two entire images (**x**,**y**). We set the ROI size to 3 \(\times\) 3 in this study. The calculation of SSIM between two corresponding ROIs is defined as follows:  
\[SSIM_{ROI}(\textbf{x},\textbf{y})=\frac{(2\mu_{x}\mu_{y}+C_{1})(2\sigma_{xy}+ C_{2})}{(\mu_{x}^{2}+\mu_{y}^{2}+C_{1})(\sigma_{x}^{2}+\sigma_{y}^{2}+C_{2})}, \tag{12}\]  
where \(\mu_{x}\) and \(\mu_{y}\) are the local averages, \(\sigma_{x}\) and \(\sigma_{y}\) are the local standard deviations, and \(\sigma_{xy}\) is local covariance. \(C_{1}\) and \(C_{2}\) are given by  
\[C_{1}=(K_{1}L)^{2}, \tag{13}\]  
\[C_{2}=(K_{2}L)^{2}, \tag{14}\]  
where \(K_{1}\) = 0.01, \(K_{2}\) = 0.03, and \(L\) = 1 were used in this study. MS-SSIM has been introduced as an alternative metric of SSIM to evaluate image details at various resolutions [44]. It can overcome the shortcomings of SSIM, which tends to underestimate spatial translation and overestimate image blurring [46]. MS-SSIM is computed by combining the three components of SSIM on multiple scales, as follows:  
\[SSIM(\textbf{x},\textbf{y})=[l_{M}(\textbf{x},\textbf{y})]^{\alpha_{M}}\cdot \prod_{j=1}^{M}[c_{j}(\textbf{x},\textbf{y})]^{\beta_{j}}[s_{j}(\textbf{x}, \textbf{y})]^{\gamma_{j}}. \tag{15}\]  
The two images (**x**,**y**) are iteratively low-pass-filtered and downsampled by a factor of 2. The scale of the original image is 1, while that of the most reduced image is \(M\). The brightness is compared only at scale \(M\), and we refer to this as \(l_{M}(\textbf{x},\textbf{y})\). The contrast and structure components are compared at each scale, denoted as \(c_{j}(\textbf{x},\textbf{y})\) and \(s_{j}(\textbf{x},\textbf{y})\), respectively, for the \(j\)th scale. [PERSON] et al. [44] obtained five-scale parameters in which the SSIM scores agreed with subjective assessments: \(\beta_{1}\) = \(\gamma_{1}\) = 0.0448, \(\beta_{2}\) = \(\gamma_{2}\) = 0.2856,\(\beta_{3}=\gamma_{3}=0.3001\), \(\beta_{4}=\gamma_{4}=0.2363\), and \(\alpha_{5}=\beta_{5}=\gamma_{5}=0.1333\). We set \(M=5\) and used these five-scale parameters in the present study.