## 3 Methodology
### Stage 4: Meta-Heuristic Algorithms for Feature Selection
#### 3.4.2. Dynamic Population Gray Wolf Optimization (DPGWO)  
The selection of the number of features and their combinations from the given 22 features is considered a non-polynomial hard problem. In this work, DPGWO, a new variant of GWO, is introduced to solve the above problem, and its effectiveness is proved by comparing its performance with MFO and GWO algorithms. The dynamic population size in DPGWO enables the optimization process to adjust the number of gray wolves based on their fitness values. As a result, gray wolves with higher fitness values, which are closer to the ideal solution, have a higher likelihood of surviving and reproducing, whereas those with lower fitness values have a larger probability of being replaced. This helps to maintain a varied population and prevent premature convergence to poor solutions. The distinction between the proposed algorithm and the existing enhancement of GWO will be  
* Introducing life for each wolf during population initialization. * Fixing the age and probability of reproducing capability of the wolf. * Choosing the disease probability to control the dynamic population size. Apart from that, in the existing evolutionary population dynamics for the GWO algorithm, the repositioning of poor solutions has been carried out around the positions of alpha, beta, and delta wolves [29]. In this work, the following new concepts are incorporated into the existing GWO algorithm to enhance its performance with dynamic populations: \begin{table}
\begin{tabular}{l c c c c c} \hline \hline \multirow{2}{*}{**Parameters**} & \multicolumn{5}{c}{**Levels**} \\ \cline{2-6}  & **1** & **2** & **3** & **4** & **5** \\ \hline n\_estimators & 100 & 500 & 900 & 1100 & 1500 \\ base\_score & 0.25 & 0.5 & 0.75 & 1 & \\ learning\_rate & 0.05 & 0.1 & 0.15 & & \\ Booster & gbtree & Gblinear & & & \\ \hline \hline \end{tabular}
\end{table} 
Table 8: List of Hyper Parameters and their Levels. \begin{table}
\begin{tabular}{l c c c c} \hline \hline \multirow{2}{*}{**Parameters**} & \multicolumn{5}{c}{**Crack Dimensions**} \\ \cline{2-5}  & **Length** & **Depth** & **Width** \\ \hline n\_estimators & 500 & 1500 & 100 \\ base\_score & 1 & 0.75 & 1 \\ learning\_rate & 0.05 & 0.15 & 0.05 \\ Booster & Gblinear & gblinear & gbtree & \\ \hline \hline \end{tabular}
\end{table} 
Table 9: Optimum Hyper Parameters of XGB for Crack Dimensions. During population initialization, the life of each wolf has been assigned randomly within the maximum number of iterations. The life of \(i\)th wolf (\(L_{i}\)) is defined as follows in Equation (1):  
\[L_{i}=\left\{j;j\in[1,nitr]\right\} \tag{1}\]  
Removing the existing wolf and instead introducing a new wolf will improve exploration. If the life of the wolf is equal to the current iteration (\(itr\)), then that wolf will be removed from the population. Equation (2) expresses the life of ith wolf during the current iteration \(L_{i}(itr)\). \[L_{i}(itr)=\left\{ \begin{array}{l}0\;itr=L_{i}(itr)\\ L_{i}(itr)itr<L_{i}(itr)\end{array} \right\} \tag{2}\]  
The reproducing nature of the wolf is considered to introduce new offspring from the existing fittest wolves after a defined mature age (\(k\)) with reproduce probability (\(r_{p}\)) expressed in Equation (3). This concept will improve the exploitation of the algorithm. In Equation (3), 1 indicates that the \(i\)th wolf can reproduce. \[R_{i}(itr)=\left\{ \begin{array}{l}1\;L_{i}(itr)>k\;and\;P(r1<r_{p})\\ 0\;L_{i}(itr)>k\;and\;P(r1\geq r_{p})\end{array} \right\} \tag{3}\]  
To control the size of the wolves, after reaching the threshold size, the existence of each wolf (\(E_{i}\)) is confirmed with the disease probability (\(d_{p}\)) as expressed in Equation (4). The values of \(r1\) and \(r2\) will be between 0 and 1. \[E_{i}(itr)=\left\{ \begin{array}{l}1\;L_{i}(itr)>itr\;and\;P(r2<d_{p})\\ 0\;L_{i}(itr)>itr\;and\;P(r2\geq d)\end{array} \right\} \tag{4}\]  
The parameters used in the optimization algorithms are presented in Tables 10 and 11. The pseudocodes of MFO, GWO, and DPGWO are given in Appendix B.