## 2 RIS-Assisted System and Channel Model
### Proposed Deep Learning Model
#### 2.4.2 Model Construction and Operation  
The proposed model is comprised of two different networks such as 1-D CNN and the GRU network. The proposed CNN-GRU-based network design is shown in Figure 4. The input layer, convolutional layer, pooling layer, GRU layer, and output layer make up the proposed model's structure. The input OFDM demodulated information is extracted by the convolutional layer, and afterward, the pooling layers are used to compensate for the features. Then, the GRU layer is utilized for memorizing features of the previous 1-D CNN output. In the end, the classification is performed by the softmax layer for GRU output. The operation of each layer of the proposed model is described as follows:  
_Input layer_: We consider the input sequence features matrix of \(Q=[S_{1}{}^{\text{\tiny 7R}}\), \(S_{1}{}^{\text{\tiny 7D}}\), \(S_{2}{}^{\text{\tiny 7R}}\), \(S_{2}{}^{\text{\tiny 7D}}\), \(S_{3}{}^{\text{\tiny 7R}}\), \(S_{3}{}^{\text{\tiny 7D}}\), \(...,S_{N}{}^{\text{\tiny 7R}}\), \(S_{N}{}^{\text{\tiny 7D}}\)], which is composed with two numerical values together and the corresponding label classes. The \(i\)-th output of the sequence matrix is \(S_{i}\), so that \(S_{0}=Q\). Eight real and imaginary values, which correspond to label 1, are contained in each sequence. The dimension of \(8\times 1\) in the input layer is assumed to equal the size of the input features. Two numerical values of sequence features with their associated labels are supplied into the CNN's input layer from the created dataset, where the configuration sets the number of features in the input data to be equal to the input size. _Convolutional layer (\(i=1\))_: To extract local features from the sequence data, we utilize the convolutional layer. The convolutional layer's parameters (\(k\times s\)), where \(k\) is the kernel size and \(s\) is the input data dimension, comprise a collection of learnable filters. In the convolutional layer, a total of 64 filters in \(3\times 3\) various sizes are used. The outcome feature matrix \(S_{i}\) may, thus, be represented as follows:  
\[S_{i}=f(S_{i-1}\otimes w_{i}+b_{i}), \tag{12}\]  
where \(w_{i}\) stands for the weight of the \(i\)-th layer, and \(b_{i}\) stands for the layer's bias. The following layers make use of a non-linear or piecewise linear activation function called a rectified linear unit (ReLU). If the output of the ReLU function is positive, it will be directly  
Figure 4: The architecture of the proposed CNN-GRU network: the 1-D CNN network with its layers (**left side**) and the GRU network layers (**right side**). Figure 3: Dataset examples including real and imaginary parts with its labels. entered; otherwise, it will be 0. The ReLU function is shown mathematically as follows: \(f(x)=max(0,x)\). _Pooling layer (i = 2):_ The main function of the pooling layer is to compress the features that the convolutional layer has recovered in order to decrease the information dimension and the risk of network overfitting. This layer's function in the study is to cut down on the computing time required to process sequence characteristics from earlier hidden layers using a 1-D global average pooling approach. The output of the pooling layer is the highest of the earlier features matrix. Consequently, the outcome feature matrix \(S_{i}\) may be expressed as follows:  
\[S_{i}=f_{p}(S_{i-1}), \tag{13}\]  
where the pooling function \(f_{p}\) is used. The dimension of \(S_{2}\) is calculated from the pooling layer as \(m/z\times n\), where \(z\) represents the scale value of the current layer of the pooling layer, \(m\) represents the number of filters, and \(n\) represents the number of input data time steps. _GRU layer (i = 3):_ The GRU layer train is the feature vectors that the CNN extracts where the GRU layer retains the internal workings of many features. According to the structure of the GRU layer, the GRU operating system may be summed up in the next following sentences.