Abstract
Hybrid metaheuristic algorithms have been widely used to solve global optimization problems, making the concept of hybridization increasingly important. This study proposes a new hybrid multi-strategy metaheuristic algorithm named COSGO, which combines the strengths of grey wolf optimization (GWO) and Sand Cat Swarm Optimization (SCSO) to effectively address global optimization tasks. Additionally, a chaotic opposition-based learning strategy is incorporated to enhance the efficiency and global search capability of the algorithm. One of the main challenges in metaheuristic algorithms is premature convergence or getting trapped in local optima. To overcome this, the proposed strategy is designed to improve exploration and help the algorithm escape local minima. As a real-world application, multi-level thresholding for color image segmentation—a well-known problem in image processing—is studied. The COSGO algorithm is applied using two objective functions, Otsu’s method and Kapur’s entropy, to determine optimal multi-level thresholds. Experiments are conducted on 10 images from the widely used BSD500 dataset. The results show that the COSGO algorithm achieves competitive performance compared to other State-of-the-Art algorithms. To further evaluate its effectiveness, the CEC2017 benchmark functions are employed, and a Friedman ranking test is used to statistically analyze the results.
1. Introduction
Image segmentation aims to divide an image into several regions with similar features or semantic meanings for further processing and analysis []. This technique has attracted significant attention in various fields, including early disease detection [], autonomous driving [], and image processing applications []. To achieve accurate and robust segmentation, it is essential that the pixel characteristics within each region are consistent []. Threshold-based segmentation methods in image segmentation are typically divided into two categories []. Bi-level thresholding is a fundamental technique that segments an image into two separate classes by determining a single optimal threshold value. On the other hand, multi-level thresholding partitions the image into multiple segments by locating several threshold values.
Multi-threshold segmentation refers to the process of dividing an image into several object and background regions by determining multiple threshold values []. Existing image thresholding segmentation techniques primarily include two classical approaches: the Otsu method and the Kapur entropy method. The Kapur entropy approach selects thresholds based on the principles of information theory [,]. It operates by evaluating the entropy values of pixel distributions at various grey levels within the image. The threshold corresponding to the maximum entropy is chosen as the optimal point for image segmentation. The Otsu method is a popular technique for image segmentation that relies on analyzing greyscale distributions [,].
Its main strategy is to identify a threshold that separates the image into two groups, aiming to reduce the variance within each group as much as possible. By iteratively assessing intra-class variances, the method selects the threshold that yields the lowest total variance, leading to optimal binarization. The increase in the number of thresholds in multi-threshold image segmentation leads to an exponential rise in computational complexity, which in turn causes traditional multi-level thresholding techniques to suffer from reduced accuracy and slow convergence.
To address these limitations, metaheuristic algorithms have been employed in image segmentation tasks, demonstrating impressive performance. There have been many metaheuristic algorithms presented in the last few decades. Metaheuristic algorithms are used to solve real-world problems in different dimensions. It is possible to find the best or near-optimal solution using metaheuristic algorithms. Based on the No-Free-Lunch (NFL) theory [], it has been concluded that there is no algorithm that can find all the possible solutions to optimization problems. There is a large difference between a heuristic algorithm and a metaheuristic algorithm in avoiding local optima trapping. Unlike heuristic algorithms, metaheuristic algorithms try to find a global optimum or optimal solution. Metaheuristic algorithms avoid being trapped in local optima through the use of exploration and exploitation phases. In each metaheuristic algorithm, these phases are the main operations. In addition, the trade-off between these two phases is important. The process of exploration involves looking for the most effective solution(s) for a given area(s), while the process of exploitation involves focusing on the most effective solution(s) for a given area(s) []. In most cases, the exploration ability of search agents must be increased in the initial iterations in order to locate potential areas and then exploit the optimum solution once discovered.
Metaheuristic algorithms can be divided into three categories: evolution-based, swarm-based, and physics-based. Evolutionary algorithms are largely based on natural laws and behaviors. Based on Darwin’s theory of evolution, the genetic algorithm is a metaheuristic algorithm []. Another evolution-based metaheuristic algorithm is differential evolution (DE) [], another algorithm based on Darwinian theory, although it differs from GA in its selection phase. Metaheuristic algorithms based on swarms and societies in nature are called swarm-based algorithms. In order to find a solution to these algorithms, members of groups interact with one another within a search space. One of the most well-known algorithms in this category is particle swarm optimization (PSO) []. PSO simulates flocking birds’ social behavior. There are several possible solutions represented by each particle in the group. Among the other algorithms in this category are ant colony optimization (ACO) [], grey wolf optimization [], and Sand Cat Swarm Optimization []. Metaheuristic algorithms with physics-based inputs are derived from physical laws and theories, like gravity and particle movement. Among the well-known physics-based metaheuristic algorithms are the Gravitational Search Algorithm (GSA) [], the Big-Bang Big-Crunch (BBBC) [], and the Charged System Search (CSS) [].
In [], the proposed modified grey wolf optimizer (MGWO) is applied to multi-level thresholding color image segmentation to achieve the optimum threshold. The authors used some strategies in leader selection and position update; in addition, they used a mutation operator to lead search agents to the optimum solution. In [], the authors proposed a hybrid algorithm based on crayfish optimization and a differential evolution algorithm named ACOADE to use in color multi-threshold image segmentation. This hybrid algorithm maximizes the foraging parameter of crayfish optimization and uses the base process of the differential evolution (DE) algorithm to achieve the optimum threshold value of the image segmentation technique using the Otsu and Kapur entropy methods as objective functions. The authors of [] proposed an improved whale optimization algorithm to overcome the limitations of the classical WOA in color multi-threshold image segmentation. In this way, enhancement significantly improved the segmentation accuracy and robustness of the results.
In [], the black widow optimization (BWO) algorithm is applied to a multi-level thresholding image segmentation problem. Similar to other studies in this field, the Otsu and Kapur entropy methods are used to evaluate as their objective function. Learning Enthusiasm-Based Teaching–Learning-Based Optimization (LebTLBO) is a recent metaheuristic known for its simplicity and low computational cost []. Its effectiveness in image segmentation is evaluated using the Berkeley Segmentation Dataset 500 (BSDS500). This dataset provides diverse and high-quality images suitable for benchmarking. Objective functions such as Otsu’s method and Kapur’s entropy are employed to assess segmentation performance. Improved elephant herding optimization (IEHO) integrates opposition-based learning and chaotic sequences to enhance the exploration–exploitation balance []. Its efficiency is tested on multi-level thresholding (MTH) for image segmentation. Kapur’s entropy, Otsu’s method, and Masi entropy are used as objective functions to determine optimal thresholds.
Recently, a novel 3D memristive cubic map employing dual discrete memristors (3D-MCM) has been proposed, exhibiting rich dynamical behaviors, including coexisting attractors, making it suitable for secure image encryption tasks []. To address the growing demand for secure and efficient image transmission, a novel color image encryption algorithm based on the 2D Logistic–Rulkov Neuron Map (2D-LRNM) was proposed, offering enhanced complexity and unpredictability through a hybrid chaotic model []. PSEQADE is a quantum differential evolutionary algorithm that uses a quantum-adaptive mutation strategy and a population state evaluation framework to address excessive mutation in QDE. The experimental results show excellent convergence performance, high accuracy, and stability in solving high-dimensional complex problems [].
MGAD is a novel adaptive evolutionary multitask optimization algorithm designed to address challenges in evolutionary multitask optimization, including dynamic control, inaccurate task selection, negative knowledge transfer, and decreased optimization performance due to increased uncertainty []. The TSLS-SCSO algorithm, an enhanced version of Sand Cat Swarm Optimization (SCSO), is proposed for autonomous path planning in dynamic environments. It incorporates a population initialization strategy, spiral search, Livy flight, tent chaotic mapping, and sparrow alert mechanism, achieving higher accuracy and competitiveness [].
The method includes a PHFM-based domain transform strategy and the BHRN network structure. The input image is transformed into the PHFM domain for parsing and edge predictions. An encoder–decoder structure is used for mutual guidance learning across multiple stages. The shared encoder enhances feature propagation, while separate decoders predict parsing and edge results []. This study explores the use of chaotic systems in metaheuristic optimization techniques to improve search efficiency. The initial populations of the PSO and WSO algorithms are distributed according to Logistic, Chebyshev, Circle, sine, and Piecewise chaotic maps [].
The paper proposes a Polynomial Chebyshev Symmetric Chaotic-based GJO (PCSCGJO) algorithm to improve image segmentation in image processing. The PCSCGJO algorithm combines a chaotic generating function with the Golden Jackal Optimizer (GJO) algorithm, aiming to avoid local optima and improve segmentation results. The simulation results show the PCSCGJO method’s effectiveness in dealing with medical color images outperforms other metaheuristic algorithms in terms of quality and accuracy []. This paper proposes an improved Transit Search algorithm based on a chaotic map and local escape operator (CLTS). The algorithm introduces chaos initialization, simplifies transit criteria, improves convergence speed in the neighborhood phase, and balances exploration and exploitation. The experimental results show the CLTS algorithm achieves faster convergence speed and higher accuracy compared to the TS algorithm and other advanced algorithms. It also outperforms advanced image segmentation algorithms in terms of convergence and segmentation effects [].
To improve metaheuristic algorithm performance, hybrid metaheuristic algorithms are proposed. It is common for metaheuristic algorithms to integrate two or more metaheuristic algorithms to solve optimization problems. Hybrid metaheuristic algorithms have the primary objective of utilizing the advantages of both algorithms while minimizing their drawbacks. Hybrid metaheuristic algorithms generally fine-tune exploration and exploitation []. A hybrid metaheuristic algorithm is proposed in order to achieve a balance between exploration and exploitation of metaheuristic algorithms. The performance of the convergence curve and the optimal solution during algorithm execution are essential for achieving the best result. The metaheuristic algorithm finds the optimal solution by analyzing the initial search space, whereas the algorithm structure is used to determine the optimal solution. The diversity of solutions is also important in this way. On the other hand, there is a relationship between the diversity of solutions and the speed of convergence. Fast convergence is often caused by low diversity. Most hybrid metaheuristic algorithms perform solution diversity, and the algorithm structure further promotes solution diversity [,]. The most important issue to avoid is local trapping.
This study makes the following major contributions:
- A novel hybrid metaheuristic algorithm (COSGO) is proposed, which integrates grey wolf optimization (GWO) and Sand Cat Swarm Optimization (SCSO) to enhance global optimization performance.
- The COSGO algorithm is specifically designed to overcome the local optima problem by improving exploration capabilities. The adaptive characteristics of SCSO are used to increase the diversity of GWO, thereby achieving a better balance between exploration and exploitation.
- A chaotic opposition-based learning (COBL) strategy is incorporated into the hybrid metaheuristic algorithm to further improve convergence speed and solution quality by enhancing population diversity.
- The proposed algorithm is applied to the multi-level thresholding color image segmentation problem, aiming to reduce computational effort in finding optimal threshold values. Both Otsu’s method and Kapur’s entropy are employed as objective functions.
- Experimental validation is conducted using the BSD500 dataset (10 color images) to demonstrate the segmentation quality and effectiveness of the COSGO algorithm.
- Comprehensive performance evaluation is carried out using the CEC2017 benchmark suite, and statistical significance is assessed using the Friedman ranking test, confirming the competitive performance of the proposed approach.
2. Fundamentals
An overview of the GWO optimization algorithm is provided in the first part of this section. The second part of the presentation focuses on the SCSO optimization algorithm, which is explained in detail. At the end of this section, the multi-level thresholding image segmentation problem is defined.
2.1. Grey Wolf Optimization (GWO)
The grey wolf optimization (GWO) algorithm was described by Mirjalili et al. []. A simulation of GWO was conducted based on the leadership hierarchy and social behavior of grey wolves. Unlike other types of animals, grey wolves live and hunt in a unique habitat. There are usually 5–12 grey wolves in a group of grey wolves. In each group, there are four kinds of grey wolves, namely, alpha (α), beta (β), delta (δ), and omega (ω). In groups, each of these types of grey wolves has a different responsibility. Alpha (α) wolves have a powerful effect on their groups. The alpha (α) wolf is responsible for making decisions regarding hunting, sleep locations, and wake-up times. The group is responsible for making this decision. Beta (β) wolves are on the second level of the pack hierarchy. Co-leaders are wolves that are considered to be part of the group’s leadership. Delta (δ) is categorized at the third level of the hierarchy. Delta wolves must follow the instructions of the upper-level wolves: alpha and beta. The delta is the last wolf capable of eating and hunting. It is important to say that if the delta wolf does not exist in a group, the group encounters internal chaos and problems. In the hierarchy of grey wolves, the omega grey wolf occupies the lowest position. A wolf is considered an omega if it does not include any of the above types.
The GWO algorithm consists of three phases: encircling, attacking, and hunting. Each phase has a different mathematical model. A number of parameters are included in the encircling model to allow the wolves to encircle their prey. As a result, the new location has been updated. The following equations represent encircling the prey mathematically:
In this regard, are coefficient vectors, and are the position vectors of the grey wolf and prey, respectively. Here, another important parameter is , which decreased from 2 to 0. This parameter is used to guide the search agents to the prey based on the iteration number. As in most metaheuristic algorithms, there are some random parameters between 0 and 1; in the GWO algorithm, are random numbers:
2.2. Sand Cat Swarm Optimization (SCSO)
Sand Cat Swarm Optimization (SCSO) is a metaheuristic algorithm inspired by the unique survival and hunting behaviors of sand cats, a species adapted to harsh desert environments []. Unlike domestic cats, sand cats can detect low-frequency sounds below 2 kHz, which plays a crucial role in locating prey in challenging conditions. SCSO simulates this remarkable sensory and hunting capability to navigate the search space and locate near-optimal solutions. Similar to other swarm-based optimization techniques, the algorithm begins with the random initialization of a population of search agents within defined lower and upper bounds. Each agent represents a potential solution in a matrix where rows correspond to individual agents and columns to the problem’s dimensions. A fitness function is employed to evaluate how well each solution satisfies the optimization objective—whether minimization or maximization—and guides the search process across iterations. The algorithm iteratively updates the agents’ positions based on fitness values until convergence, with the final solution representing the best outcome found. While the principal goal across metaheuristics is similar, the strategies employed, such as the foraging-inspired mechanism in SCSO, distinguish each algorithm in achieving optimal or near-optimal results.
Each search agent begins with a sensitivity range starting at 2 kHz, controlled by the parameter, which linearly decreases over iterations to balance exploration and exploitation. Position updates are based on both the best candidate and the current position, modulated by the sensitivity range , ensuring adaptive movement across the search space. A circular movement strategy is employed using a random angle , enabling agents to effectively avoid local optima and converge toward the best solution:
2.3. Multi-Level Thresholding Image Segmentation
One of the most important and sensitive topics in image processing research is the multi-level thresholding problem, which can accurately capture complex details and structures in images. Additionally, it greatly enhances the impact of image segmentation. The segmentation approach is applied to images in the majority of medical sciences, such as pattern identification, medical image processing, and medical image analysis. The Otsu and Kapur methods are used in this study as objective functions in this problem.
2.3.1. Otsu Method
Otsu’s multi-threshold image segmentation is a statistical, unsupervised, and non-parametric method used to determine the optimal threshold values in image processing []. The goal of this method is to maximize the between-class variance, ensuring that pixels within the same segment have similar intensity values while also achieving strong separation between different segments. Assume an image is to be divided into N classes. To achieve this segmentation, N − 1 thresholds must be determined. Multi-thresholding separates pixels based on their greyscale intensity values using these thresholds. The normalized histogram of the image is defined below in Equation (15)
Here, is the histogram count for intensity level i, NP is the total number of pixels in the image, and L is the number of greyscale levels. For a single threshold T, the probability of occurrence (weights) for the two classes separated by T are given by:
The class means are:
The total mean intensity of the image is:
Otsu’s method selects the threshold T* that maximizes the between-class variance:
For multi-threshold segmentation (i.e., more than two classes), the principle is extended to maximize the sum of between-class variances for all N classes. This typically involves evaluating combinations of thresholds to find the set that yields the highest overall between-class variance.
2.3.2. Kapur Method
An additional popular technique for multi-level thresholding is Kapur’s method, which is founded on the idea of Shannon entropy. Unlike Otsu’s method, which relies on variance-based class separation, Kapur’s method seeks to maximize the sum of entropies of the segmented regions, thus ensuring that each region contains the most information possible. The method utilizes the normalized histogram of the greyscale image to calculate the probability distribution of pixel intensities. Given a combination of thresholds , the total entropy H for K segmented regions is calculated as:
The entropy of the final region is:
Based on the above equation, pi is the probability of the ith grey level, and L is the total number of grey levels. The probability sums (weights) for each segmented region are calculated as follows:
The optimal set of thresholds is the one that maximizes the total entropy H, thereby achieving the most informative segmentation of the image. Kapur’s method is particularly effective for images with complex intensity distributions and is often used in applications requiring the precise segmentation of textures or objects with varying brightness.
3. Hybrid Metaheuristic Algorithm
Here, the classic SCSO and GWO algorithms are used to propose a new hybrid algorithm that benefits from the advantages of these algorithms to create an efficient algorithm for solving global optimization. In addition, a chaotic opposition-based learning strategy is used in the proposed hybrid optimization algorithm.
3.1. Hybridization SCSO and GWO
The SCSO algorithm uses the R parameter to control the movement of search agents within the search space. This parameter also ensures a balance between exploration and exploitation. Inspired by the unique characteristics of sand cats in nature, the R parameter emphasizes the sensitivity range and decreases from 2 kHz to 0 over time. In contrast, the GWO algorithm uses the A parameter to control the movement of search agents. When the A parameter value is greater or less than 1, it influences the balance between exploration and exploitation. However, this mechanism can lead to drawbacks, such as trapping in local optima, especially in large search spaces. To address this issue, the hybrid algorithm incorporates the R parameter to enhance control over agent movement and improve the balance between exploration and exploitation.
In this context, the COSGO algorithm benefits from the R-value of the SCSO algorithm to switch dynamically between two well-known metaheuristic algorithm strategies. When the R-value is between −1 and 1, the search agents follow the behavior rules of the SCSO algorithm; otherwise, they update their positions based on the GWO algorithm. COSGO also includes a mechanism to validate the fitness of newly updated positions. Updated positions are first checked against the search space boundaries. If they fall outside the allowed limits, correction parameters are applied to move them back within boundaries. Subsequently, a sorting mechanism is employed to merge the new positions with the existing ones, resulting in a combined population of old and new individuals. Likewise, the fitness values of both the existing and new individuals are merged. All individuals are ranked in ascending order based on their fitness values, with the best individual placed at the top. The population is then updated by selecting the top individuals according to the original number of search agents, ensuring that the best solutions are retained.
Grey wolf optimization (GWO) was employed due to its effective global exploration capabilities, simple structure, and minimal parameter requirements, which make it highly adaptable across a variety of optimization problems. On the other hand, the Sand Cat Swarm Optimization (SCSO) algorithm has demonstrated efficient local search behavior and a balanced exploration–exploitation trade-off, making it a suitable candidate for hybridization. The integration of chaotic opposition-based learning further enhances diversity and helps avoid premature convergence. Comparative studies such as [,] have also highlighted the complementary strengths of these algorithms, supporting the rationale for their combination in the proposed framework.
3.2. Chaotic Opposition-Based Learning Strategy
One of the recently introduced techniques in optimization is opposition-based learning (OBL) []. OBL was first proposed by Tizhoosh to emphasize the evaluation of the opposite position of a search agent within the search space. In this approach, an optimization algorithm evaluates the fitness of both the current position and the opposite position of a search agent. This allows the algorithm to explore the search space more broadly, covering diverse regions and directions. Moreover, in complex optimization problems where multiple local optima exist, search agents can easily become trapped. OBL helps mitigate this issue by increasing the chances of escaping local optima, thus enhancing the global search capability of the algorithm. In Equation (23), which represents the initial population of the optimization algorithm, lb is lower bound, ub is upper bound, and ri is a random number from a uniform distribution in the range [0, 1]. In equation 24, the opposite position of the current position is calculated:
As mentioned earlier, OBL benefits from considering the opposite population based on fixed positions; however, this approach may face limitations. To address this issue, in [], the authors proposed a modified version of OBL by introducing a random number, which adds a certain level of randomness to the solution and improves diversity. In the chaotic opposition-based learning strategy (COBLS), chaotic behavior is introduced to enhance population diversity and avoid premature convergence. A chaotic array is first generated by iteratively applying the sine map s times. This chaotic array is then used to replace the conventional random array, and opposite solutions are calculated accordingly. As a result, the search process is enriched by exploring different regions of the search space more effectively.
In this study, the sine map was selected as the chaotic map to enhance the diversity of the population during the optimization process. Compared to other chaotic maps such as the Logistic map, the sine map offers smoother and more uniformly distributed sequences, which can help to explore the search space more effectively. Previous studies have shown that the choice of chaotic map can significantly influence the convergence behavior and performance of metaheuristic algorithms [,]:
In Equation (25), the Fs is a chaotic array that has been mapped using a sine function s times. S is set at 20 in order to prevent the loss of diversity brought on by too few iterations or the increase in running time produced by too many iterations.
3.3. System Model
As aforementioned, this study proposes a new multi-strategy hybrid metaheuristic algorithm to address one of the np-hard problems, multi-level thresholding for color image segmentation. The aim of this problem is to partition a color image into meaningful regions based on pixel intensity values. Initially, it takes an RGB image as input and converts it to greyscale histograms. These histograms are then used to determine the optimal threshold values. This combinatorial optimization problem is modeled, and the goal is to select a set of threshold values that maximizes an image quality criterion. The proposed COSGO algorithm was employed to find these optimal thresholds. To evaluate the COSGO algorithm, a total of 10 real-world images were taken from the BSD500 dataset, which is one of the well-known datasets. The flowchart of the proposed COSGO algorithm is given in Figure 1.
Figure 1.
The flowchart of the COSGO algorithm.
In addition, in the simulation, the main parameters used in the system and COSGO algorithm are explained below:
- T: number of thresholds (3–5 in this study).
- MaxIter: maximum number of iterations (e.g., 100).
- PopulationSize: number of candidate solutions (e.g., 30).
- Objective Functions: Otsu method and Kapur entropy.
- Dataset: BSD500 (10 selected color images).
- Channels: R, G, and B (treated independently for thresholding).
- Evaluation Metric: PSNR, SSIM, and computation time.
It is possible to explain the problem formulation. Let h(i) be an image histogram for intensity level i ∈ [0, 255]. The objective is to determine a threshold vector for a multi-level thresholding problem with T thresholds:
The goal is to maximize f(T), a fitness function that can be either Otsu’s method or Kapur’s entropy. Thus, the optimization problem is formulated as:
In order to determine the optimal threshold set T that produces the highest segmentation quality based on the chosen objective function, the COSGO algorithm searches the solution space.
4. Results and Analysis
This section evaluates the proposed algorithm using benchmark functions, which are commonly employed to assess metaheuristic algorithms due to their stochastic nature. To demonstrate the effectiveness of the proposed method, it is compared with several metaheuristic algorithms, including GWO [], SCSO [], and the WOA [] and two hybrid metaheuristic algorithms, including AGWO_CS [] and the PSOGSA []. The evaluation includes benchmark tests and statistical analyses. Each algorithm was run independently 30 times using identical control settings, and performance was measured based on the mean and standard deviation. All simulations were conducted on the same system using MATLAB R2020b. The simulation parameters for each metaheuristic algorithm are explained in Table 1.
Table 1.
The simulation parameters.
4.1. Experimental Analysis Based on CEC2017
For numerical validation, a set of 29 benchmark functions from the CEC2017 test suite was employed, which are widely utilized for assessing the performance of metaheuristic algorithms. These functions are categorized into four groups: the unimodal functions range from F1 to F3, multimodal from F4 to F10, hybrid from F11 to F20, and composite from F21 to F30. The proposed COSGO algorithm was benchmarked using these functions and compared against several existing methods, including GWO, SCSO, the WOA, AGWO-CS, and the PSOGSA. Table 2 summarizes the experimental outcomes in terms of mean, worst, best, and standard deviation values. In this way, the Friedman ranking presented in Table 3 was used to compare the performance of COSGO to metaheuristic algorithms. For each benchmark function, the algorithms are ranked based on their performance, with the best-performing algorithm. These rankings were then averaged over all problems to compute the overall Friedman rank for each algorithm. A lower average rank indicates better overall performance. The Friedman test is a non-parametric statistical method that helps determine whether the observed differences in ranks among the algorithms are statistically significant. Based on Table 3, it is observed that the average ranking of the COSGO algorithm is lower than the other algorithms. It means the COSGO algorithm performance is better than the others.
Table 2.
Results for F1-F30 algorithms (CEC17) D10.
Table 3.
Friedman rankings of COSGO and the compared algorithms.
4.2. Experimental Analysis Based on Multi-Level Thresholding
To assess the performance of the proposed COSGO algorithm against other methods, multiple quantitative metrics were used, such as the Peak Signal-to-Noise Ratio (PSNR), the Feature Similarity Index (FSIM), the Structural Similarity Index Measure (SSIM), dice, and the Jaccard index and accuracy, along with the optimal objective function values and their associated variances. In this regard, ten images were selected from the BSD500 dataset []. For ease of interpretation and comparative analysis, the best results averaged over 10 independent runs are highlighted in bold in the subsequent tables. Table 4 presents the average and standard deviation fitness function values for all compared methods across thresholding levels 2, 3, 4, and 5 evaluated on all images using two objective functions: Otsu’s method and Kapur’s entropy. Moreover, the proposed COSGO algorithm demonstrates lower computational time at threshold level 2 and level 3. Based on the obtained results of the running time of each algorithm, which are presented in Table 5, the COSGO algorithm achieves superior performance in terms of execution time.
Table 4.
The fitness values of the algorithms.
Table 5.
The running time of each algorithm.
The segmentation results based on Otsu and Kapur entropy are shown in Table 6, along with the PSNR, SSIM, and FSIM values. A traditional statistic for assessing image quality is the PSNR. It determines how segmented and original photos differ from one another. The segmented image is more like the original when the PSNR value is higher. In this way, the higher value of the PSNR proves the algorithm efficiently. In addition, the mean square error (MSE) was calculated for each algorithm with two objective functions. The obtained results were also in the same running condition, with 100 iteration numbers and 30 search agent numbers. It was observed that the proposed COSGO algorithm showed better performance in terms of higher PSNR and lower MSE values in comparison to the other algorithms.
Table 6.
The PSNR and MSE values of the algorithms.
The Structural Similarity Index Measure (SSIM) evaluates the perceived quality of an image by incorporating luminance, contrast, and structural information. A higher SSIM value closer to 1 indicates a greater structural similarity between the segmented image and the original image. The Feature Similarity Index Measure (FSIM), which is widely used for image quality assessment, particularly in terms of texture and detail preservation, quantifies the similarity based on low-level image features, such as phase congruency and gradient magnitude. Table 7 presents the obtained value for each algorithm with two different objective functions as Otsu and Kapur entropy functions.
Table 7.
The SSIM and FSIM values of the algorithms.
In Table 8, the dice coefficient and Jaccard index are shown. The dice coefficient and Jaccard index (intersection over union) are widely used metrics for evaluating image segmentation performance by measuring the similarity between the predicted segmentation and the ground truth. In contrast, the Jaccard index measures the ratio of the intersection to the union of the same sets. Both metrics range from 0 to 1, with higher values indicating greater similarity, and they are especially important in assessing the spatial accuracy of segmentation methods.
Table 8.
The dice and Jaccard index values of the algorithms.
Table 9 presents the quantitative evaluation of the segmentation accuracy achieved by each algorithm across the test image dataset. The evaluation is based on two widely recognized overlap-based similarity metrics: the dice coefficient and the Jaccard index. These metrics assess how closely the segmented regions produced by the algorithms align with the ground truth masks. Higher values in both metrics indicate superior segmentation performance, reflecting better boundary adherence and region consistency. The table highlights the comparative strengths of each method and provides a comprehensive understanding of their effectiveness in accurately delineating the target regions.
Table 9.
The accuracy values of the algorithms.
As shown in Figure 2, Figure 3, Figure 4 and Figure 5, the comparisons of SSIM and FSIM values across 10 test images demonstrate significant variations among different algorithms at threshold levels 2–5.
Figure 2.
Comparison of SSIM and FSIM values obtained from 10 test images using different algorithms at threshold level 2.
Figure 3.
Comparison of SSIM and FSIM values obtained from 10 test images using different algorithms at threshold level 3.
Figure 4.
Comparison of SSIM and FSIM values obtained from 10 test images using different algorithms at threshold level 4.
Figure 5.
Comparison of SSIM and FSIM values obtained from 10 test images using different algorithms at threshold level 5.
4.3. Performance Analysis
Based on the results, it should be noted that the COSGO algorithm performed significantly in finding the threshold value in images. In this problem, the image levels were studied on levels 2, 3, 4, and 5, respectively. The findings obtained for the algorithm in concern were near to one, which shows good improvement of the algorithm and a considerable performance of the algorithm, according to Table 6 and Table 7, which have been analyzed on the PSNR, SSIM, and FSIM criteria. An increase in the number of threshold levels generally results in more vivid and detailed segmented images. While images segmented using the COSGO algorithm are often visually distinguishable, the method exhibits certain weaknesses in specific regions. In addition, Figure 6 shows the segmented images with different metaheuristic algorithms.

Figure 6.
The segmented images with different algorithms.
4.4. Objective Function Analysis
In this section, the results obtained for the Otsu and Kapur entropy objective functions are analyzed. Based on Figure 7, Figure 8 and Figure 9, it can be noted that the COSGO algorithm performed better. In Figure 7, which is based on the PSNR results, the Otsu function obtained superior results over the COSGO algorithm and WOA. In the case of the Kapur function, the GWO and SCSO algorithms obtained better results, respectively. Based on the level of the images, the COSGO algorithm with the Otsu function at level 2, the SCSO algorithm with the Otsu function at level 3, the COSGO algorithm with the Otsu function at level 4, and the COSGO algorithm with the Otsu function at level 5 obtained promising results in the PSNR.
Figure 7.
Comparative PSNR analysis across different threshold levels (levels 2–5) using Otsu and Kapur methods with four algorithms. COSGO consistently outperforms other methods, especially under the Otsu-based segmentation, indicating its robustness in preserving image quality.
Figure 8.
SSIM analysis for multiple threshold levels (levels 2–5) using Otsu and Kapur methods with various metaheuristic algorithms. COSGO again shows superior structural similarity performance, particularly under the Otsu thresholding strategy, indicating its effectiveness in preserving structural details.
Figure 9.
FSIM analysis across different threshold levels (levels 2–5) using Otsu and Kapur methods with various algorithms. COSGO consistently outperforms others in feature similarity, especially when combined with Otsu, highlighting its robustness in preserving perceptual image quality.
In Figure 8, the Structural Similarity Index Measure (SSIM) values were analyzed for different metaheuristic algorithms in combination with two distinct objective functions: Otsu and Kapur entropy. The results reveal that the proposed COSGO algorithm, when used with the Otsu objective function, generally exhibits strong performance in terms of structural similarity. Notably, at the multi-level thresholding level of 5, COSGO demonstrates superior performance with both Otsu and Kapur entropy compared to the other algorithms. This indicates that the COSGO algorithm is more capable of preserving structural information, such as luminance, contrast, and texture consistency, particularly at higher threshold levels. The effectiveness of COSGO under these conditions highlights its potential for more accurate and visually coherent image segmentation.
In Figure 9, the Feature Similarity Index Measure (FSIM) values obtained from various algorithms are presented and analyzed. The results indicate that the proposed COSGO algorithm demonstrates superior performance compared to other competing methods. Particularly, when integrated with the Otsu objective function, COSGO achieves the highest FSIM values across multiple test images. This suggests that COSGO is more effective in preserving low-level visual features, such as texture and edge information, during the segmentation process. The enhanced FSIM scores further confirm that the proposed approach maintains a high degree of similarity between the segmented and original images, thus contributing to improved perceptual quality and segmentation accuracy.
4.5. Theoretical Insights into the COSGO Algorithm
The COBL method improves the suggested hybrid GWO-SCSO algorithm, which provides unique theoretical contributions beyond the simple combination of two metaheuristics. The hybrid structure achieves a more balanced search process by combining the local exploitation strength of SCSO with the global exploration capabilities of GWO. The algorithm can converge more quickly while being resilient against local optima due to this combination. Additionally, the population diversity is enhanced by the chaotic opposition-based learning (COBL) method, which results in improved initialization and more consistent convergence behavior across runs. Our approach combines a complementary dynamics hierarchical leadership-based search in GWO with adaptive motion in SCSO, which improves the optimization performance in hybrid metaheuristic algorithms that frequently mix similar search behaviors. The COSGO hybridization process collectively offers advantages in both convergence speed and stability, which is established by our experimental findings.
5. Conclusions
In this study, the COSGO metaheuristic algorithm is proposed as a hybrid multi-strategy metaheuristic algorithm. This algorithm benefits from the advantages of the grey wolf optimization and sand cat swarm optimization algorithms to create an efficient metaheuristic algorithm to solve global optimization problems. Also, chaotic opposition-based learning was used to enhance the search agents’ search ability and obtain balanced exploration and exploitation phases. The COSGO algorithm displays better performance in comparison with the GWO and SCSO algorithm, the WOA, and two hybrid metaheuristic algorithms, AGWO-CS and the PSOGSA, in the CEC 2017 benchmark functions. Based on the obtained results in the Freidman ranking test, the COSGO algorithm’s 1.862068966 average ranking shows its competitive efficiency in the benchmark functions. In addition, one of the well-known np-hard problems—multi-level thresholding color image segmentation—was studied with the proposed COSGO algorithm. Two objective functions named Otsu and Kapur were used to find the optimum values. This technique was evaluated with four performance criteria—the PSNR, MSE, SSIM, FSIM, dice coefficient, Jaccard index, and segmentation accuracy—to investigate the COSGO algorithm’s performance in comparison with other metaheuristic algorithms. It was observed that the COSGO algorithm shows good performance with the Otsu method in multi-level thresholding color image segmentation.
Funding
This research received no external funding.
Institutional Review Board Statement
Not applicable.
Informed Consent Statement
Not applicable.
Data Availability Statement
The data presented in this study are available on request from the corresponding author.
Conflicts of Interest
The author declares no conflict of interest.
References
- Dong, Y.; Li, M.; Zhou, M. Multi-Threshold Image Segmentation Based on the Improved Dragonfly Algorithm. Mathematics 2024, 12, 854. [Google Scholar] [CrossRef]
- Akay, R.; Saleh, R.A.; Farea, S.M.; Kanaan, M. Multilevel thresholding segmentation of color plant disease images using metaheuristic optimization algorithms. Neural Comput. Appl. 2022, 34, 1161–1179. [Google Scholar] [CrossRef]
- Oliva, D.; Abd Elaziz, M.; Hinojosa, S. Metaheuristic Algorithms for Image Segmentation: Theory and Applications; Springer International Publishing: Berlin/Heidelberg, Germany, 2019; pp. 59–69. [Google Scholar]
- Abualigah, L.; Almotairi, K.H.; Elaziz, M.A. Multilevel thresholding image segmentation using meta-heuristic optimization algorithms: Comparative analysis, open challenges and new trends. Appl. Intell. 2023, 53, 11654–11704. [Google Scholar] [CrossRef]
- Hu, P.; Han, Y.; Zhang, Z. Multi-Level Thresholding Color Image Segmentation Using Modified Gray Wolf Optimizer. Biomimetics 2024, 9, 700. [Google Scholar] [CrossRef] [PubMed]
- Zhang, C.; Pei, Y.H.; Wang, X.X.; Hou, H.Y.; Fu, L.H. Symmetric cross-entropy multi-threshold color image segmentation based on improved pelican optimization algorithm. PLoS ONE 2023, 18, e0287573. [Google Scholar] [CrossRef]
- Wolpert, D.H.; Macready, W.G. No free lunch theorems for optimization. IEEE Trans. Evol. Comput. 1997, 1, 67–82. [Google Scholar] [CrossRef]
- Yang, X.S. Nature-Inspired Metaheuristic Algorithms; Luniver Press: Bristol, UK, 2010. [Google Scholar]
- Holland, J.H. Genetic algorithms. Sci. Am. 1992, 267, 66–73. [Google Scholar] [CrossRef]
- Storn, R.; Price, K. Differential evolution–a simple and efficient heuristic for global optimization over continuous spaces. J. Glob. Optim. 1997, 11, 341–359. [Google Scholar] [CrossRef]
- Kennedy, J.; Eberhart, R. Particle swarm optimization. In Proceedings of the ICNN’95-International Conference on Neural Networks, Perth, WA, Australia, 27 November–1 December 1995; Volume 4, pp. 1942–1948. [Google Scholar]
- Dorigo, M.; Birattari, M.; Stutzle, T. Ant colony optimization. IEEE Comput. Intell. Mag. 2007, 1, 28–39. [Google Scholar] [CrossRef]
- Mirjalili, S.; Mirjalili, S.M.; Lewis, A. Grey wolf optimizer. Adv. Eng. Softw. 2014, 69, 46–61. [Google Scholar] [CrossRef]
- Seyyedabbasi, A.; Kiani, F. Sand Cat swarm optimization: A nature-inspired algorithm to solve global optimization problems. Eng. Comput. 2023, 39, 2627–2651. [Google Scholar] [CrossRef]
- Rashedi E, Nezamabadi-Pour H, Saryazdi S GSA: A gravitational search algorithm. Inf. Sci. 2009, 179, 2232–2248. [CrossRef]
- Erol, O.K.; Eksin, I. A new optimization method: Big bang–big crunch. Adv. Eng. Softw. 2006, 37, 106–111. [Google Scholar] [CrossRef]
- Kaveh A, Talatahari S A novel heuristic optimization method: Charged system search. Acta Mech. 2010, 213, 267–289. [CrossRef]
- Ma, G.; Yue, X. An improved whale optimization algorithm based on multilevel threshold image segmentation using the Otsu method. Eng. Appl. Artif. Intell. 2022, 113, 104960. [Google Scholar] [CrossRef]
- Houssein, E.H.; Helmy, B.E.D.; Oliva, D.; Elngar, A.A.; Shaban, H. A novel black widow optimization algorithm for multilevel thresholding image segmentation. Expert Syst. Appl. 2021, 167, 114159. [Google Scholar] [CrossRef]
- Singh, S.; Mittal, N.; Singh, H. A multilevel thresholding algorithm using LebTLBO for image segmentation. Neural Comput. Appl. 2020, 32, 16681–16706. [Google Scholar] [CrossRef]
- Chakraborty, F.; Roy, P.K. An efficient multilevel thresholding image segmentation through improved elephant herding optimization. Evol. Intell. 2025, 18, 17. [Google Scholar] [CrossRef]
- Gao, S.; Iu, H.H.C.; Erkan, U.; Simsek, C.; Toktas, A.; Cao, Y.; Wu, R.; Mou, J.; Li, Q.; Wang, C. A 3D memristive cubic map with dual discrete memristors: Design, implementation, and application in image encryption. IEEE Trans. Circuits Syst. Video Technol. 2025. Early Access. [Google Scholar] [CrossRef]
- Gao, S.; Zhang, Z.; Iu, H.H.C.; Ding, S.; Mou, J.; Erkan, U.; Toktas, A.; Li, Q.; Wang, C.; Cao, Y. A Parallel Color Image Encryption Algorithm Based on a 2D Logistic-Rulkov Neuron Map. IEEE Internet Things J. 2025, 12, 18115–18124. [Google Scholar] [CrossRef]
- Deng, W.; Wang, J.; Guo, A.; Zhao, H. Quantum differential evolutionary algorithm with quantum-adaptive mutation strategy and population state evaluation framework for high-dimensional problems. Inf. Sci. 2024, 676, 120787. [Google Scholar] [CrossRef]
- Song, Y.; Song, C. Adaptive evolutionary multitask optimization based on anomaly detection transfer of multiple similar sources. Expert Syst. Appl. 2025, 283, 127599. [Google Scholar] [CrossRef]
- Deng, W.; Feng, J.; Zhao, H. Autonomous path planning via sand cat swarm optimization with multi-strategy mechanism for unmanned aerial vehicles in dynamic environment. IEEE Internet Things J. 2025. Early Access. [Google Scholar] [CrossRef]
- Liu, Y.; Wang, C.; Lu, M.; Yang, J.; Gui, J.; Zhang, S. From simple to complex scenes: Learning robust feature representations for accurate human parsing. IEEE Trans. Pattern Anal. Mach. Intell. 2024, 46, 5449–5462. [Google Scholar] [CrossRef]
- Serbet, F.; Kaya, T. New comparative approach to multi-level thresholding: Chaotically initialized adaptive meta-heuristic optimization methods. Neural Comput. Appl. 2025, 37, 8371–8396. [Google Scholar] [CrossRef]
- Hamza, A.; Grimes, M.; Boukabou, A.; Lekouaghet, B.; Oliva, D.; Dib, S.; Himeur, Y. A chaotic variant of the Golden Jackal Optimizer and its application for medical image segmentation. Appl. Intell. 2025, 55, 295. [Google Scholar] [CrossRef]
- Li, C.; Liu, H. A transit search algorithm with chaotic map and local escape operator for multi-level threshold segmentation of spleen CT images. Appl. Math. Model. 2025, 141, 115930. [Google Scholar] [CrossRef]
- Ting, T.O.; Yang, X.S.; Cheng, S.; Huang, K. Hybrid Metaheuristic Algorithms: Past, Present, and Future. In Recent Advances in Swarm Intelligence and Evolutionary Computation; Springer: Berlin/Heidelberg, Germany, 2015; pp. 71–83. [Google Scholar]
- Amirsadri, S.; Mousavirad, S.J.; Ebrahimpour-Komleh, H. A Levy flight-based grey wolf optimizer combined with back-propagation algorithm for neural network training. Neural Comput. Appl. 2018, 30, 3707–3720. [Google Scholar] [CrossRef]
- Tizhoosh, H.R. Opposition-based learning: A new scheme for machine intelligence. In Proceedings of the International Conference on Computational Intelligence for Modelling, Control and Automation and International Conference on Intelligent Agents, Web Technologies and Internet Commerce (CIMCA-IAWTIC’06), Vienna, Austria, 28–30 November 2005; Volume 1, pp. 695–701. [Google Scholar]
- Long, W.; Jiao, J.; Liang, X.; Cai, S.; Xu, M. A random opposition-based learning grey wolf optimizer. IEEE Access 2019, 7, 113810–113825. [Google Scholar] [CrossRef]
- Rani, G.S.; Jayan, S.; Alatas, B. Analysis of chaotic maps for global optimization and a hybrid chaotic pattern search algorithm for optimizing the reliability of a bank. IEEE Access 2023, 11, 24497–24510. [Google Scholar] [CrossRef]
- Lu, H.; Wang, X.; Fei, Z.; Qiu, M. The effects of using chaotic map on improving the performance of multiobjective evolutionary algorithms. Math. Probl. Eng. 2014, 2014, 924652. [Google Scholar] [CrossRef]
- Mirjalili, S.; Lewis, A. The whale optimization algorithm. Adv. Eng. Softw. 2016, 95, 51–67. [Google Scholar] [CrossRef]
- Sharma, S.; Kapoor, R.; Dhiman, S. A novel hybrid metaheuristic based on augmented grey wolf optimizer and cuckoo search for global optimization. In Proceedings of the 2021 2nd International Conference on Secure Cyber Computing and Communications (ICSCCC), Jalandhar, India, 21–23 May 2021; pp. 376–381. [Google Scholar]
- Mirjalili, S.; Hashim, S.Z.M. A new hybrid PSOGSA algorithm for function optimization. In Proceedings of the 2010 International Conference on Computer and Information Application, Tianjin, China, 3–5 December 2010; pp. 374–377. [Google Scholar]
- Martin, D.; Fowlkes, C.; Tal, D.; Malik, J. A database of human segmented natural images and its application to evaluating segmentation algorithms and measuring ecological statistics. In Proceedings of the Proceedings Eighth IEEE International Conference on Computer Vision. ICCV 2001, Vancouver, BC, Canada, 7–14 July 2001; Volume 2, pp. 416–423. [Google Scholar]
Disclaimer/Publisher’s Note: The statements, opinions and data contained in all publications are solely those of the individual author(s) and contributor(s) and not of MDPI and/or the editor(s). MDPI and/or the editor(s) disclaim responsibility for any injury to people or property resulting from any ideas, methods, instructions or products referred to in the content. |
© 2025 by the author. Licensee MDPI, Basel, Switzerland. This article is an open access article distributed under the terms and conditions of the Creative Commons Attribution (CC BY) license (https://creativecommons.org/licenses/by/4.0/).