## 3 The Proposed Method
### Embedding  
In the embedding phase, we utilize the previously described CNN-based predictor to generate the predict image and hide the secret data by prioritizing the pixels with the largest differences between the generated predict image and the cover image. Therefore, before performing embedding, a trained CNN-based predictor model is required. The detailed embedding process follows the steps below. Step 1: As shown in Figure 5b, to create the inner square corresponding to the input data of the CNN-based predictor model, leave only the pixels that will be used as input from the cover image, while setting the remaining pixels to 0. The generated input data are inserted into the previously created CNN-based predictor model, resulting in the prediction of outer square pixel values as illustrated in Figure 5c, \(I_{outer}\). The inner square used as input values in the CNN-based predictor is combined with the outer square from Figure 5c, \(I_{outer}\), resulting in the generation of the predicted image as illustrated in Figure 5d. Step 2: The proposed embedding method hides secret data in the difference between \(P\) and \(C\), so we calculate the difference between \(P\) and \(C\) as described in Equation (10) and designate it as \(G\). \[G_{(i,j)}=P_{(i,j)}-C_{(i,j)} \tag{10}\]  
For each pixel where the value of \(G_{(i,j)}\) is not 0, indicating the presence of a difference between the cover image and the predicted image, hide 1 bit of secret data per pixel. To determine the locations where the data are hidden, we multiply the value of \(G_{(i,j)}\) by 2 to make it even. Figure 5: (**a**) Cover image \(C\). (**b**) The inner square part of cover image \(I_{inner}\). (**c**) Predicting inner square of the cover image \(T_{outer}\). (**d**) Predicted image \(P\). Step 3: The new image pixel \(S\) is generated by subtracting twice the difference of \(P\) and \(C\), denoted as \(G\) from \(P\). In this way, the generated \(S\) hides the secret data. The formula for calculating this is Equation (11):  
\[S_{(i,j)}=P_{(i,j)}-G_{(i,j)}\times 2 \tag{11}\]  
For example, given an image of size 3 \(\times\) 3 and pixel values as shown in Figure 6a, the difference between the predicted image, Figure 6b, is represented by Figure 6c. The generated \(S_{(i,j)}\) resulting from the difference between \(P_{(i,j)}\) and two times the results in \(G_{(i,j)}\) is shown in Figure 6d. Step 4: Use the \(G\) generated in Step 3 to determine the locations of the pixels where the secret data will be hidden. Since \(G\) contains both negative and positive values, apply the absolute value of \(G\) to calculate \(G_{abs}\), which is described in Equation (12). Then, sort the coordinates of the pixels in descending order based on the magnitude of \(G_{abs}\). If multiple pixels have the same value of \(G_{abs}\), prioritize the coordinates of the top-left pixel to obtain the absolute value. \[G_{abs}=|G| \tag{12}\]  
Step 5: Once the coordinates with the largest \(G_{abs}\) values are sorted, hide the secret data in descending order of \(G_{abs}\) values. The hidden data consist of binary data composed of 1 and 0, and based on the magnitude of the \(G_{abs}\) values, add the secret data to the corresponding \(S_{(i,j)}\) pixel. If the secret data are 0, no data are hidden in the corresponding pixel. If the secret data are 1, then 3 is added to or subtracted from the corresponding pixel. As explained in Equation (13), add 3 to \(S_{(i,j)}\) if the \(G_{(i,j)}\) value is greater than 0. If the \(G_{(i,j)}\) value is less than 0, a new value of \(S_{(i,j)}\) is subtracted by 3. The hiding secret data are 1 bit per pixel, but in reality, 3 is added to the corresponding pixel, which is greater than 1 and an odd number. The reason for adding a value greater than 1 is that \(S\) becomes closer to \(C\) as the added value increases, ultimately resulting in an increase in the PSNR of the stego-image. \[S_{(i,j)}= \begin{cases}S_{(i,j)}+(3\times SecretData)\ if\ G_{(i,j)}>0\\ S_{(i,j)}-(3\times SecretData)\ if\ G_{(i,j)}<0\end{cases}