Multi-level threshold Kapur entropy image segmentation method based on MSh model

By constructing a multi-level threshold Kapur entropy image segmentation method and establishing a multi-dimensional dynamic evaluation system using the MSh model, the number of thresholds is dynamically adjusted, which solves the problems of insufficient flexibility and incomplete evaluation in existing segmentation methods. This achieves a balance between image segmentation quality and efficiency, and improves the robustness and adaptability of the algorithm.

CN121904089APending Publication Date: 2026-04-21ZHEJIANG GUANGSHA COLLEGE OF APPLIED CONSTRTECH +1
View PDF 1 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
ZHEJIANG GUANGSHA COLLEGE OF APPLIED CONSTRTECH
Filing Date
2025-12-30
Publication Date
2026-04-21

AI Technical Summary

Technical Problem

Existing multi-level threshold image segmentation methods lack flexibility and cannot adaptively adjust according to the complexity of image content and the real-time performance of the algorithm, resulting in oversegmentation or undersegmentation. Furthermore, they lack a comprehensive evaluation system to measure segmentation quality, efficiency, and resource consumption, making it difficult to achieve the best balance between speed, accuracy, and resource overhead.

Method used

A multi-level threshold Kapur entropy image segmentation method based on the MSh model is constructed. By calculating the density coefficient, optimizing the convergence characteristic coefficient, segmentation accuracy coefficient, and signal-noise-efficiency matching coefficient, a multi-dimensional dynamic evaluation system is established to dynamically adjust the number of thresholds to optimize segmentation quality and efficiency.

Benefits of technology

It achieves comprehensive quantification of the algorithm's time efficiency, space efficiency, and convergence speed, ensuring a balance between segmentation quality and computational resource consumption, improving the algorithm's robustness and adaptability in complex scenarios, and avoiding oversegmentation or undersegmentation problems.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121904089A_ABST
    Figure CN121904089A_ABST
Patent Text Reader

Abstract

The invention discloses a multi-level threshold Kapur entropy image segmentation method based on an MSh model. The method comprises the following steps: outputting a calculation density coefficient through a calculation density model; outputting an optimized convergence characteristic coefficient through the optimized convergence characteristic model; outputting a segmentation precision coefficient through the segmentation precision model; outputting a signal-noise-efficiency matching coefficient through a signal-noise-efficiency matching model; and outputting the target optimal threshold number through the threshold optimization model. According to the method, a multi-dimensional and dynamic evaluation system is constructed, so that the limitation of the prior art is overcome. The introduction of the optimization convergence characteristic coefficient enables the convergence robustness and efficiency of the algorithm to be accurately measured, and avoids the possible problem of unstable convergence or low efficiency in a traditional method.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention belongs to the field of image processing technology, specifically relating to a multi-level threshold Kapur entropy image segmentation method based on the MSh model. Background Technology

[0002] Image segmentation, a fundamental step in computer vision and image processing, aims to divide digital images into regions with unique attributes to facilitate subsequent analysis and understanding. In multi-object or complex scenes, single-threshold segmentation methods often fail to achieve ideal results; therefore, multi-level threshold image segmentation techniques have emerged and become a research hotspot.

[0003] Chinese patent application No. 202011048219.0 discloses a two-dimensional segmentation method for multi-threshold images, proposing a multi-threshold image segmentation model. This model is based on Kapur entropy and non-local mean two-dimensional histograms, and incorporates the foraging behavior of artificial bee colonies into the slime mold algorithm to obtain the optimal threshold for image segmentation and achieve better image segmentation quality.

[0004] The focus of this patent is on improving algorithm performance, with a fixed, pre-defined threshold number. However, this strategy lacks flexibility and cannot adaptively adjust based on image content complexity and real-time algorithm performance, easily leading to oversegmentation or undersegmentation.

[0005] Furthermore, existing research on segmentation algorithms often considers segmentation quality (such as PSNR) or operational efficiency in isolation, lacking a multi-dimensional dynamic evaluation system that can comprehensively measure "quality-efficiency-resource consumption" to guide the online optimization of algorithm parameters (such as the number of thresholds). This makes it difficult for algorithms to achieve the optimal balance between speed, accuracy, and resource overhead in practical applications, limiting their adaptability and overall performance. Summary of the Invention

[0006] The purpose of this invention is to provide a multi-level threshold Kapur entropy image segmentation method based on the MSh model to solve the problems mentioned in the background. The multi-level threshold Kapur entropy image segmentation method based on the MSh model provided by this invention has the characteristic of being able to comprehensively quantify the algorithm's time efficiency, space efficiency, and convergence speed.

[0007] To achieve the above objectives, the present invention provides the following technical solution: a multi-level threshold Kapur entropy image segmentation method based on the MSh model, comprising the following steps:

[0008] S1. Based on the average running time of a single iteration, the peak memory usage, and the number of iterations required to achieve a specific accuracy, the calculated density coefficients are output through the calculated density model.

[0009] S2. Based on the final energy function value, the average fitness value at convergence, and the smoothness of the convergence curve, the optimized convergence characteristic coefficients are output by optimizing the convergence characteristic model.

[0010] S3. Based on segmentation accuracy, intra-class consistency, and inter-class separation, the segmentation accuracy coefficients are output through the segmentation accuracy model.

[0011] S4. Based on the peak signal-to-noise ratio and total convergence running time under the calculated density coefficient and optimized convergence characteristic coefficient, the signal-to-noise-efficiency matching coefficient is output through the signal-to-noise-efficiency matching model.

[0012] S5. Based on the signal-to-noise-efficiency matching coefficient, segmentation accuracy coefficient, and the current optimal threshold number, the target optimal threshold number is output through the threshold optimization model.

[0013] In this invention, further, in S1, the step of calculating the density coefficients by calculating the density model based on the average running time of a single iteration, the peak memory usage, and the number of iterations required to achieve a specific accuracy is as follows:

[0014] S11. Obtain the average running time of a single iteration, the peak memory usage, and the number of iterations required to achieve a specific level of accuracy.

[0015] S12. Ratio the average running time of a single iteration, the peak memory usage, and the number of iterations required to reach a specific accuracy with the corresponding reference values ​​to obtain the time efficiency index, space efficiency index, and convergence speed index.

[0016] S13. Import the time efficiency index, space efficiency index, and convergence speed index into the computational density coefficient model to obtain the computational density coefficient.

[0017] In this invention, the computational density model is further configured such that when the computational load reflected by multiple efficiency indices increases, the output computational density coefficient decreases accordingly; the computational density coefficient model is expressed as:

[0018] C cd =exp(-t ind -M ind -N ind );

[0019] Among them, C cd This indicates the calculation of the density coefficient, t ind M represents the time efficiency index. ind N represents the space efficiency index. ind C represents the convergence rate exponent. cd ∈(0,1] and the larger the value, the lower the computational efficiency.

[0020] In this invention, further, in S2, the step of optimizing the convergence characteristic coefficients by optimizing the convergence characteristic model based on the final energy function value, the average fitness value at convergence, and the smoothness of the convergence curve is as follows:

[0021] S21. Obtain the final energy function value, the average fitness value at convergence, and the smoothness of the convergence curve;

[0022] S22. Perform max-min normalization on the average fitness value at convergence to obtain the threshold quality index.

[0023] S23. Perform max-min normalization on the final energy function value and the smoothness of the convergence curve to obtain the segmentation quality factor and smoothness factor.

[0024] S24. Take the complements of the segmentation quality factor and the smoothing factor to obtain the segmentation quality index and the smoothing index;

[0025] S25. Import the threshold quality index, segmentation quality index, and smoothness index into the optimization convergence characteristic model to obtain the optimization convergence characteristic coefficients.

[0026] Furthermore, in this invention, as the exponent reflecting threshold quality, segmentation quality, and convergence smoothness increases, the output optimized convergence characteristic coefficient also increases accordingly; the optimized convergence characteristic model is expressed as:

[0027] C oc =a1F ind +a2E ind +a3σ ind ;

[0028] Among them, C oc F represents the convergence characteristic coefficient of the optimization. ind E represents the threshold quality index. ind σ represents the segmentation quality index. ind The smoothing exponent, a i Represents the weight coefficient and C oc The larger the value in [0, 1], the better the optimization convergence characteristics.

[0029] In this invention, further, in S3, the step of outputting the segmentation accuracy coefficients based on the segmentation accuracy model, considering segmentation accuracy, intra-class consistency, and inter-class separation, is as follows:

[0030] S31. Obtain the segmentation accuracy, intra-class consistency, and inter-class separation degree;

[0031] S32. Perform max-min normalization on the segmentation accuracy, intra-class consistency, and inter-class separation to obtain the segmentation accuracy index, intra-class consistency index, and inter-class separation index.

[0032] S33. Import the segmentation accuracy index, intra-class consistency index, and inter-class separation index into the segmentation accuracy model to obtain the segmentation accuracy coefficients.

[0033] In this invention, the segmentation accuracy is further configured such that when the segmentation accuracy index and the inter-class separation index increase, and the intra-class consistency index decreases, the output segmentation accuracy coefficient increases; the segmentation accuracy model is expressed as:

[0034]

[0035] Among them, C sa A represents the segmentation precision coefficient. ind V represents the segmentation accuracy index. ind D represents the intra-class consistency index. ind b represents the inter-class separation index. i Represents the weight coefficient and C sa ∈[0.5, 1] ​​and the larger the value, the better the segmentation quality.

[0036] In this invention, further, in S4, the step of outputting the signal-noise-efficiency matching coefficients through the signal-noise-efficiency matching model based on the calculated density coefficients, the peak signal-to-noise ratio under optimized convergence characteristic coefficients, and the total convergence running time is as follows:

[0037] S41. Perform maximum-maximum normalization on the peak signal-to-noise ratio to obtain the signal-to-noise ratio exponent.

[0038] S42. Calculate the ratio of the total convergence runtime to the reference runtime to obtain the runtime index;

[0039] S43. Based on the calculated density coefficient and optimized convergence characteristic coefficient, the efficiency basic coefficient is obtained through the efficiency basic model.

[0040] S44. Import the efficiency base coefficient, signal-to-noise ratio index, and runtime index into the signal-to-noise-efficiency matching model to obtain the signal-to-noise-efficiency matching coefficient.

[0041] In this invention, the basic efficiency model is further expressed as:

[0042]

[0043] Among them, C z C represents the basic efficiency coefficient. cd C represents the density coefficient. oc This represents the convergence characteristic coefficient for optimization.

[0044] The signal-to-noise-efficiency matching model is represented as:

[0045] Cse =C z p ind (1-exp(-η ind ));

[0046] Among them, C se C represents the signal-to-noise-efficiency matching coefficient. z p represents the basic efficiency coefficient. ind Signal-to-noise ratio exponent, η ind C represents the runtime index. sa The larger the value in [0,1], the higher the overall quality-time benefit of the algorithm under specific resource consumption.

[0047] In this invention, further, in S5, the threshold optimization model adaptively adjusts the current optimal threshold number using a smoothing adjustment function based on the difference between the product of the signal-to-noise-efficiency matching coefficient and the segmentation accuracy coefficient and a preset target equilibrium point, so as to output the target optimal threshold number. The threshold optimization model is expressed as follows:

[0048] m optimal =m cur (1+tanh(C se C sa -θ));

[0049] Where, m optimal m represents the number of target optimal thresholds. cur C represents the current optimal threshold quantity. se C represents the signal-to-noise-efficiency matching coefficient. sa θ represents the segmentation accuracy coefficient, and θ represents the target equilibrium point.

[0050] Compared with the prior art, the beneficial effects of the present invention are:

[0051] 1. This invention overcomes the limitations of existing technologies by constructing a multi-dimensional and dynamic evaluation system.

[0052] 2. By introducing a computational density coefficient, this invention can comprehensively quantify the time efficiency, space efficiency, and convergence speed of the algorithm, which contrasts with the rough assessment of resource consumption in traditional methods.

[0053] 3. The introduction of the optimized convergence characteristic coefficient in this invention enables the convergence robustness and efficiency of the algorithm to be accurately measured, avoiding the problems of convergence instability or low efficiency that may occur in traditional methods.

[0054] 4. The segmentation accuracy coefficient of this invention comprehensively reflects the quality of the segmentation result from multiple dimensions, which is more comprehensive than a single segmentation accuracy index.

[0055] 5. This invention effectively combines computational efficiency, convergence characteristics, segmentation quality, and total running time through a signal-to-noise-efficiency matching model, outputting signal-to-noise-efficiency matching coefficients. This allows the algorithm to balance the relationship between quality and efficiency within a unified framework, which is lacking in existing technologies.

[0056] 6. Based on these comprehensive evaluation coefficients, the threshold optimization model of this invention can dynamically output the target optimal threshold number. This adaptive adjustment mechanism enables the algorithm to flexibly increase or decrease the threshold number according to the actual content complexity of the image and the real-time performance, thereby effectively solving the oversegmentation or undersegmentation problem caused by the fixed threshold number in traditional methods.

[0057] 7. This invention provides an accurate and comprehensive method for evaluating the computational efficiency of algorithms. By standardizing and integrating data from multiple dimensions such as time efficiency, space efficiency, and convergence speed, it effectively solves the problems of inaccurate efficiency quantification and incomplete indicators in traditional evaluation methods. The computational density coefficient obtained thereby can accurately reflect the actual resource consumption of the algorithm, providing a reliable input for the subsequent signal-noise-efficiency matching model. This enables the entire image segmentation method to more accurately balance segmentation quality and computational efficiency when adaptively adjusting the number of thresholds, avoiding oversegmentation or undersegmentation caused by efficiency evaluation bias, and significantly improving the robustness and performance of the algorithm in practical applications.

[0058] 8. This invention provides a systematic and standardized method for calculating the optimal convergence characteristic coefficient, which can accurately and comprehensively evaluate the convergence performance of image segmentation algorithms. It solves the problems of single indicators, inconsistent dimensions, and inconsistent optimization directions in traditional evaluation methods. By obtaining multiple raw indicators such as the final energy function value, the average fitness value at convergence, and the smoothness of the convergence curve, and performing max-min normalization and complement transformation on them, it ensures that all evaluation indicators are compared on a unified scale and in a unified optimization direction. This processing method avoids evaluation bias caused by different indicator dimensions or conflicting optimization objectives, thus improving the optimal convergence characteristic coefficient C. oc This can truly reflect the overall convergence performance of the algorithm. Furthermore, the optimized convergence characteristic coefficient C... oc As input, with the density coefficient C cd They work together to affect the signal-to-noise-efficiency matching model, thus influencing the signal-to-noise-efficiency matching coefficient C. se This linkage mechanism allows the algorithm to consider not only computational efficiency and segmentation accuracy when evaluating its overall performance, but also its own convergence quality and stability. Ultimately, in the threshold optimization model, based on a more comprehensive and accurate signal-to-noise-efficiency matching coefficient C... se And segmentation accuracy coefficient C saIt can determine the optimal threshold number of the target more intelligently and adaptively, which significantly improves the robustness and adaptability of the image segmentation method in complex scenarios. It can effectively balance the consumption of computing resources and convergence efficiency while ensuring the segmentation quality, and avoid the risk of over-segmentation or under-segmentation, thus achieving better overall performance in practical applications.

[0059] 9. This invention provides a more comprehensive and accurate segmentation quality evaluation mechanism, no longer limited to a single segmentation accuracy index, but comprehensively considering three key dimensions: segmentation accuracy, intra-class consistency, and inter-class separation. This multi-dimensional evaluation method allows the segmentation accuracy coefficient to more realistically reflect the actual effect of image segmentation, avoiding misjudgments caused by one-sided evaluation. For example, even if the segmentation accuracy is high, if the intra-class consistency is poor or the inter-class separation is low, the coefficient can effectively identify the shortcomings in segmentation quality. Furthermore, this comprehensive segmentation accuracy coefficient serves as an important input to the subsequent threshold optimization model, significantly improving the adaptability and robustness of the entire multi-level threshold Kapur entropy image segmentation method. Since this coefficient can accurately quantify the quality of the current segmentation result, the threshold optimization model can dynamically adjust the target optimal threshold number based on this information and in combination with the signal-to-noise-efficiency matching coefficient. This allows the algorithm to intelligently find the best balance between segmentation quality, computational efficiency, and resource consumption according to the complexity of different images and real-time performance requirements, thereby effectively solving the problem of the lack of flexibility and difficulty in adapting to complex scenarios in traditional methods with a fixed number of thresholds, ultimately achieving better image segmentation results.

[0060] 10. This invention provides a specific and quantitative method for calculating the signal-to-noise ratio (SNR)-efficiency matching coefficient, thereby solving the problem of lacking a concrete implementation method to dynamically evaluate the quality-time comprehensive benefits of the algorithm under resource consumption in multi-level threshold Kapur entropy image segmentation methods. This scheme eliminates the dimensional differences in quality evaluation between different images and algorithms by normalizing the peak signal-to-noise ratio (PSNR), ensuring the accuracy and comparability of the SNR index. Simultaneously, by comparing the total convergence runtime with the reference runtime, the time efficiency of the algorithm can be objectively quantified, avoiding evaluation bias caused by absolute time values. Furthermore, by fusing the computational density coefficient and the optimized convergence characteristic coefficient through an efficiency-based model, this scheme can comprehensively evaluate the resource consumption and convergence quality of the algorithm, overcoming the limitations of single-level threshold Kapur entropy matching. Relying solely on a single metric is one-sided. Ultimately, the signal-to-noise-efficiency matching model organically combines the efficiency base coefficient, signal-to-noise ratio index, and running time index to generate a single, comprehensive signal-to-noise-efficiency matching coefficient. This coefficient can dynamically and accurately reflect the overall quality-time benefits of the algorithm under specific resource consumption, providing precise input for the upper-level threshold optimization model. Therefore, this scheme enables the threshold optimization model to adjust the target optimal threshold number based on a multi-dimensional, balanced performance evaluation index, significantly improving the adaptability and overall performance of the image segmentation algorithm. It ensures that the algorithm can achieve a better balance between segmentation quality, running efficiency, and resource overhead in practical applications, avoiding the problems of over-segmentation, under-segmentation, and performance instability caused by fixed threshold numbers or empirical settings in traditional methods.

[0061] 11. This invention provides a specific and operable mathematical model for adaptively adjusting the optimal number of thresholds in the image segmentation process. This model utilizes the smoothing properties of the hyperbolic tangent function to effectively avoid abrupt changes or instabilities that may occur during threshold adjustment, thereby ensuring the accuracy and controllability of the adjustment. With the help of signal-to-noise-efficiency matching coefficients and segmentation accuracy coefficients, this model can comprehensively evaluate the algorithm's overall performance in terms of quality, efficiency, and resource consumption, and make intelligent decisions based on a preset target balance point. This enables the image segmentation method to dynamically optimize the number of thresholds according to different image content and real-time performance requirements, thereby effectively controlling computational costs while ensuring segmentation quality, and significantly improving the algorithm's adaptability and overall performance. Attached Figure Description

[0062] Figure 1 This is a flowchart of the method of the present invention.

[0063] Figure 2 and Figure 4 These are the original images from the BSD dataset selected in the image segmentation experiment of this invention.

[0064] Figure 3 for Figure 2 A schematic diagram illustrating the iterative computation time of image segmentation under different computational methods for the original image.

[0065] Figure 5 for Figure 4 A schematic diagram illustrating the iterative computation time of image segmentation under different computational methods for the original image. Detailed Implementation

[0066] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.

[0067] In the description of this invention, unless otherwise explicitly specified and limited, the terms "connected," "linked," and "fixed" should be interpreted broadly. For example, they can refer to a fixed connection, a detachable connection, or an integral part; they can refer to a mechanical connection or an electrical connection; they can refer to a direct connection or an indirect connection through an intermediate medium; they can refer to the internal communication of two components or the interaction between two components. Those skilled in the art can understand the specific meaning of the above terms in this invention based on the specific circumstances.

[0068] In this invention, unless otherwise explicitly specified and limited, "above" or "below" the second feature can include direct contact between the first and second features, or contact between the first and second features through another feature between them. Furthermore, "above," "over," and "on top" of the second feature includes the first feature directly above or diagonally above the second feature, or simply indicates that the first feature is at a higher horizontal level than the second feature. "Below," "below," and "under" the second feature includes the first feature directly below or diagonally below the second feature, or simply indicates that the first feature is at a lower horizontal level than the second feature.

[0069] In the description of this invention, the terms "upper," "lower," "right," and "left," etc., refer to the orientation or positional relationship shown in the accompanying drawings. They are used only for ease of description and simplification of operation, and do not indicate or imply that the device or element referred to must have a specific orientation, or be constructed and operated in a specific orientation. Therefore, they should not be construed as limitations on this invention. Furthermore, the terms "first" and "second" are used merely for distinction in description and have no special meaning.

[0070] Please see Figures 1-5This embodiment provides the following technical solution: a multi-level threshold Kapur entropy image segmentation method based on the MSh model, comprising the following steps:

[0071] S1. Based on the average running time of a single iteration (reflecting time efficiency), peak memory usage (reflecting space efficiency), and the number of iterations required to achieve a specific accuracy (reflecting convergence speed), the calculated density coefficients are output through the calculated density model.

[0072] S2. Based on the final energy function value (the minimum value reached by the Mumford-Shah energy functional after the algorithm converges), the average fitness value at convergence (the average entropy value obtained after the algorithm converges when using Kapur entropy as the objective function), and the smoothness of the convergence curve (the standard deviation of the fitness value), the optimized convergence characteristic coefficients are output by optimizing the convergence characteristic model.

[0073] S3. Based on segmentation accuracy, intra-class consistency (gray-level variance within a region) and inter-class separation (mean and standard deviation of gray-level values ​​between regions), the segmentation accuracy coefficient is output through the segmentation accuracy model.

[0074] S4. Based on the peak signal-to-noise ratio and total convergence running time under the calculated density coefficient and optimized convergence characteristic coefficient, the signal-to-noise-efficiency matching coefficient is output through the signal-to-noise-efficiency matching model.

[0075] S5. Based on the signal-to-noise-efficiency matching coefficient, segmentation accuracy coefficient, and the current optimal threshold number, the target optimal threshold number is output through the threshold optimization model.

[0076] By adopting the above technical solutions, this invention overcomes the limitations of existing technologies by constructing a multi-dimensional and dynamic evaluation system. By introducing a computational density coefficient, this invention can comprehensively quantify the algorithm's time efficiency, space efficiency, and convergence speed, which contrasts with the coarse assessment of resource consumption in traditional methods. The introduction of an optimized convergence characteristic coefficient allows for accurate measurement of the algorithm's convergence robustness and efficiency, avoiding potential convergence instability or inefficiency issues in traditional methods. The segmentation accuracy coefficient of this invention comprehensively reflects the quality of the segmentation results from multiple dimensions, providing a more comprehensive picture than a single segmentation accuracy index. Through a signal-to-noise-efficiency matching model, this invention effectively combines computational efficiency, convergence characteristics, segmentation quality, and total running time, outputting a signal-to-noise-efficiency matching coefficient. This allows the algorithm to balance the relationship between quality and efficiency within a unified framework, a feature lacking in existing technologies. Based on these comprehensive evaluation coefficients, the threshold optimization model of this invention can dynamically output the target optimal threshold number. This adaptive adjustment mechanism enables the algorithm to flexibly increase or decrease the threshold number according to the actual content complexity of the image and the real-time performance, thereby effectively solving the oversegmentation or undersegmentation problem caused by the fixed threshold number in traditional methods.

[0077] Specifically, in S1, based on the average running time per iteration, peak memory usage, and the number of iterations required to achieve a specific level of accuracy, the steps for calculating the density coefficients by calculating the density model are as follows:

[0078] S11. Obtain the average running time of a single iteration, the peak memory usage, and the number of iterations required to achieve a specific level of accuracy.

[0079] S12. Ratio the average running time of a single iteration, the peak memory usage, and the number of iterations required to reach a specific accuracy to the corresponding reference values ​​(average values ​​on the benchmark test set) to obtain the time efficiency index, space efficiency index, and convergence speed index.

[0080] S13. Import the time efficiency index, space efficiency index, and convergence speed index into the computational density coefficient model to obtain the computational density coefficient.

[0081] Specifically, the computational density model is configured such that as the computational load reflected by multiple efficiency indices increases, the output computational density coefficient decreases accordingly; the computational density coefficient model is expressed as:

[0082] C cd =exp(-t ind -M ind -N ind );

[0083] Among them, C cd This indicates the calculation of the density coefficient, t ind M represents the time efficiency index. ind N represents the space efficiency index. ind C represents the convergence rate exponent. cd ∈(0,1) and the larger the value, the lower the computational efficiency.

[0084] Specifically, the average runtime per iteration refers to the average time consumed by the algorithm in performing a complete iteration. This metric directly reflects the algorithm's efficiency in the time dimension. It can be obtained by recording the system timestamps at the beginning and end of each iteration, calculating the time difference, and averaging it over all iterations; or, if the total runtime is known, dividing it by the total number of iterations. Peak memory usage refers to the maximum amount of system memory resources required by the algorithm throughout its entire runtime. This metric directly measures the algorithm's efficiency in the spatial dimension. It can be obtained by using process monitoring tools or APIs provided by the operating system to track and record the algorithm's memory usage in real time, thus capturing the peak; or by analyzing the algorithm's data structure and variable allocation to estimate its worst-case memory requirements. The number of iterations required to achieve a specific precision refers to the number of iterations the algorithm undergoes from its initial state until its output meets the preset convergence conditions or precision requirements. This metric reflects the convergence speed of the algorithm. It can be obtained by evaluating whether the current result has reached a preset accuracy threshold after each iteration during the algorithm iteration process (for example, the change in the energy function value is less than a certain minimum value, or the similarity between the segmentation result and the reference image reaches a certain level). Once the threshold is met, the current iteration number is recorded.

[0085] This invention achieves a comprehensive capture of the algorithm's efficiency across three core dimensions: time, space, and convergence speed, by precisely measuring the average runtime per iteration, peak memory usage, and the number of iterations required to reach a specific level of accuracy. Subsequently, these raw measurements are compared with pre-defined reference values ​​to generate dimensionless time efficiency, space efficiency, and convergence speed indices. This standardization process effectively eliminates dimensional differences between different efficiency indicators, allowing for comparison and integration within a unified framework. Next, these indices are incorporated into a computational density coefficient model, which uses an exponential function to nonlinearly combine the efficiency indices, generating a comprehensive computational density coefficient. This exponential design allows the computational density coefficient to sensitively reflect subtle changes in algorithm efficiency and ensures the reasonableness of its value range. In this way, this solution integrates disparate efficiency indicators into a single, physically meaningful comprehensive coefficient, providing an accurate and comprehensive assessment of the algorithm's computational efficiency. The computational density coefficient is then used in the signal-to-noise-efficiency matching model, where it, along with the optimization convergence characteristic coefficient, influences the generation of the signal-to-noise-efficiency matching coefficient, thereby guiding the threshold optimization model to output the target optimal number of thresholds. This progressive evaluation system allows the algorithm to fully consider its performance in terms of computational resource consumption when selecting the optimal number of thresholds, thus optimizing the overall operating efficiency of the algorithm while ensuring segmentation quality.

[0086] As a specific implementation method, the performance of a multi-level threshold Kapur entropy image segmentation algorithm based on the MSh model can be evaluated. First, the algorithm is run multiple times under a specific hardware platform and operating system environment, and its average runtime per iteration, peak memory usage, and the number of iterations required to achieve a specific accuracy (e.g., the Mumford-Shah energy functional converges to less than 10⁻⁵) are recorded when processing a series of standard images. It is assumed that the measured average runtime per iteration is 0.06 seconds, the peak memory usage is 120MB, and the number of iterations required to achieve the specific accuracy is 60. Simultaneously, a set of reference values ​​is pre-determined on the same benchmark set: a reference runtime of 0.05 seconds, a reference memory usage of 100MB, and a reference number of iterations of 50. Next, ratio processing is performed to obtain various efficiency indices: the time efficiency index t... ind =0.06 / 0.05=1.2; Space efficiency index M ind =120 / 100=1.2; Convergence rate exponent N ind =60 / 50 = 1.2$$. Finally, these indices are imported into the density coefficient calculation model, where C cd =0.0273 will serve as an important input to the subsequent signal-to-noise-efficiency matching model, used to comprehensively evaluate the quality-time benefits of the algorithm under specific resource consumption.

[0087] Through the above technical solution, this invention provides a precise and comprehensive method for evaluating algorithm computational efficiency. This method standardizes and integrates data from multiple dimensions, such as time efficiency, space efficiency, and convergence speed, effectively solving the problems of inaccurate efficiency quantification and incomplete indicators in traditional evaluation methods. The resulting computational density coefficient accurately reflects the actual resource consumption of the algorithm, providing reliable input for the subsequent signal-to-noise-efficiency matching model. This allows the entire image segmentation method to more accurately balance segmentation quality and computational efficiency when adaptively adjusting the threshold number, avoiding oversegmentation or undersegmentation caused by efficiency evaluation bias, and significantly improving the robustness and performance of the algorithm in practical applications.

[0088] Specifically, in S2, based on the final energy function value (the minimum value reached by the Mumford-Shah energy functional after algorithm convergence), the average fitness value at convergence (the average entropy value obtained after algorithm convergence when using Kapur entropy as the objective function), and the smoothness of the convergence curve (the standard deviation of the fitness value), the steps to optimize the convergence characteristic model and output the optimized convergence characteristic coefficients are as follows:

[0089] S21. Obtain the final energy function value, the average fitness value at convergence, and the smoothness of the convergence curve;

[0090] S22. Perform max-min normalization on the average fitness value at convergence to obtain the threshold quality index.

[0091] S23. Perform max-min normalization on the final energy function value and the smoothness of the convergence curve to obtain the segmentation quality factor and smoothness factor.

[0092] S24. Take the complements of the segmentation quality factor and the smoothing factor to obtain the segmentation quality index and the smoothing index (index = 1 - factor);

[0093] S25. Import the threshold quality index, segmentation quality index, and smoothness index into the optimization convergence characteristic model to obtain the optimization convergence characteristic coefficients.

[0094] Specifically, as the exponents reflecting threshold quality, segmentation quality, and convergence smoothness increase, the output optimization convergence characteristic coefficients also increase; the optimization convergence characteristic model is expressed as:

[0095] C oc =a1F ind +a2E ind +a3σ ind ;

[0096] Among them, C oc F represents the convergence characteristic coefficient of the optimization. ind E represents the threshold quality index. ind σ represents the segmentation quality index. ind The smoothing exponent, a i Represents the weight coefficient and C oc The larger the value in [0, 1], the better the optimization convergence characteristics.

[0097] Specifically, in the above technical solution, obtaining the final energy function value, the average fitness value at convergence, and the smoothness of the convergence curve are fundamental to evaluating the convergence characteristics of the algorithm. The final energy function value refers to the minimum value reached by the Mumford-Shah energy functional after the algorithm converges. Its function is to quantify the quality of the image segmentation result; a lower energy value generally indicates smoother segmentation boundaries and more uniform internal regions. This value can be obtained by calculating the Mumford-Shah energy functional value corresponding to the current segmentation result after the image segmentation algorithm has finished running. The average fitness value at convergence refers to the average entropy value obtained after the algorithm converges when using Kapur entropy as the objective function. Its function is to evaluate the effectiveness of the selected threshold in preserving image information. A higher Kapur entropy value generally means that the segmentation result better preserves the original information of the image. This value can be obtained by averaging the Kapur entropy values ​​of all individuals (e.g., in evolutionary algorithms) at the time of algorithm convergence. Convergence curve smoothness refers to the standard deviation of fitness values. Its function is to reflect the degree of fluctuation in fitness values ​​during the convergence process. A smaller standard deviation generally indicates a more stable and smoother convergence process. This value can be obtained by recording the fitness values ​​of each generation during the algorithm's iterations and then calculating the standard deviation of these fitness values.

[0098] To unify the optimization direction of all indicators, this invention takes the complements of the segmentation quality factor and the smoothing factor to obtain the segmentation quality index and the smoothing index (index = 1 - factor). Taking the complement means subtracting the original factor value from 1. Its function is to transform the indicator that "the smaller the value, the better" into an indicator that "the larger the value, the better," thereby unifying the optimization direction of all indicators and facilitating subsequent comprehensive evaluation. The segmentation quality index is the complement of the segmentation quality factor; a larger value indicates better segmentation quality. The smoothing index is the complement of the smoothing factor; a larger value indicates a more stable convergence process.

[0099] Finally, the threshold quality index, segmentation quality index, and smoothing index are imported into the optimization convergence characteristic model to obtain the optimization convergence characteristic coefficients. The optimization convergence characteristic model is a mathematical model used to comprehensively evaluate the optimization convergence characteristics of an algorithm. Its function is to weight and combine multiple standardized indicators to output a single comprehensive coefficient. The optimization convergence characteristic coefficient C is... oc This is the final output of the model, used to quantify the optimization convergence characteristics of the algorithm. Its value ranges from [0,1], and a larger value indicates better optimization convergence characteristics. In model C... oc =a1F ind +a2E ind +a3σ ind In the middle, F ind E represents the threshold quality index, reflecting the effectiveness of threshold selection; ind σ represents the segmentation quality index, reflecting the quality of the final segmentation result;ind This represents the smoothing exponent, reflecting the stability of the algorithm's convergence process. i This represents the weighting coefficients, used to adjust the relative importance of each indicator in the comprehensive evaluation, and their sum of 1 ensures that C... oc The weighting coefficients should be set within a reasonable range and be interpretable. They can be set based on the specific application scenario or expert experience, and for example, optimized through cross-validation or machine learning methods.

[0100] The present invention aims to accurately evaluate the convergence performance of image segmentation algorithms by systematically calculating and optimizing convergence characteristic coefficients. The operational logic of this scheme is as follows: First, after the image segmentation algorithm runs and converges, the system obtains three key raw performance indicators: the final energy function value, the average fitness value at convergence, and the smoothness of the convergence curve. These indicators provide comprehensive raw data on the convergence characteristics of the algorithm from three dimensions: the quality of the segmentation result, the effectiveness of the threshold selection, and the stability of the algorithm's convergence process. Next, to eliminate potential dimensional differences among these raw indicators and unify their optimization direction, the system standardizes these indicators. Specifically, the average fitness value at convergence is directly subjected to max-min normalization to obtain a threshold quality index; a larger index value indicates better threshold quality. The final energy function value and the smoothness of the convergence curve are also subjected to max-min normalization to obtain a segmentation quality factor and a smoothness factor, respectively. Since the energy function value and smoothness are indicators where "smaller values ​​are better," to align with the "larger values ​​are better" direction of the threshold quality index, the system further takes the complement of these two factors (i.e., 1 minus the factor value), thus obtaining the segmentation quality index and smoothness index. This unifies all three indices to an evaluation direction where "larger values ​​are better." Finally, these three standardized and unified optimization directions of the threshold quality index, segmentation quality index, and smoothness index are imported into the optimization convergence characteristic model. This model uses a weighted summation method to linearly combine these three indices and calculates the final optimization convergence characteristic coefficient C based on preset weight coefficients a1, a2, and a3 (whose sum is 1). oc C oc The coefficient C comprehensively reflects the overall performance of the algorithm during the convergence process; a larger value indicates better optimization convergence characteristics. oc The calculation provides a key input for the subsequent signal-to-noise-efficiency matching model.

[0101] As a specific implementation method, the calculation of the optimized convergence characteristic coefficient of the present invention can be carried out with reference to the following example. Assume that in an image segmentation experiment, after the algorithm finishes running, the following raw data is obtained: the final energy function value is 0.15; the average fitness value at convergence is 0.8; and the convergence curve smoothness is 0.02. First, perform max-min normalization. Assume that in historical experimental data, the minimum average fitness value at convergence is 0.5, and the maximum is 0.9; the minimum final energy function value is 0.1, and the maximum is 0.3; and the minimum convergence curve smoothness is 0.01, and the maximum is 0.05. Perform max-min normalization on the average fitness value of 0.8 at convergence to obtain the threshold quality index F. ind =(0.8-0.5) / (0.9-0.5)=0.3 / 0.4=0.75=. The final energy function value of 0.15 is subjected to max-min normalization to obtain the segmentation quality factor as (0.15-0.1) / (0.3-0.1)=0.05 / 0.2=0.25. Taking its complement, the segmentation quality index E is obtained. ind =1-0.25=0.75. The smoothness of the convergence curve (0.02) is normalized using a max-min normalization process, yielding a smoothing factor of (0.02-0.01) / (0.05-0.01)=0.01 / 0.04=0.25. Taking the complement, we obtain the smoothing exponent σ. ind =1 - 0.25 = 0.75. Assuming a1, a2, and a3 are 0.4, 0.3, and 0.3 respectively, then the optimization convergence coefficient C... oc =0.75. This coefficient can be used as input to the subsequent signal-to-noise-efficiency matching model and threshold optimization model to guide the algorithm in adaptive adjustments.

[0102] Through the above technical solution, this invention provides a systematic and standardized method for calculating the optimal convergence characteristic coefficient. This method can accurately and comprehensively evaluate the convergence performance of image segmentation algorithms, solving the problems of single indicators, inconsistent dimensions, and inconsistent optimization directions in traditional evaluation methods. Specifically, by obtaining multiple raw indicators such as the final energy function value, the average fitness value at convergence, and the smoothness of the convergence curve, and performing max-min normalization and complement transformation on them, it ensures that all evaluation indicators are compared on a unified scale and in a unified optimization direction. This processing method avoids evaluation bias caused by different indicator dimensions or conflicting optimization objectives, resulting in a more accurate and efficient convergence characteristic coefficient C. oc This can truly reflect the overall convergence performance of the algorithm. Furthermore, the optimized convergence characteristic coefficient C... oc As input, with the density coefficient C cd They work together to affect the signal-to-noise-efficiency matching model, thus influencing the signal-to-noise-efficiency matching coefficient C. seThe calculation. This linkage mechanism allows the algorithm to consider not only computational efficiency and segmentation accuracy when evaluating its overall performance, but also fully incorporate the algorithm's own convergence quality and stability. Finally, in the threshold optimization model, based on a more comprehensive and accurate signal-to-noise-efficiency matching coefficient C... se And segmentation accuracy coefficient C sa This allows for a more intelligent and adaptive determination of the optimal threshold number for the target. This significantly improves the robustness and adaptability of image segmentation methods in complex scenarios, enabling them to effectively balance computational resource consumption and convergence efficiency while ensuring segmentation quality. It also avoids the risks of oversegmentation or undersegmentation, thus achieving better overall performance in practical applications.

[0103] Specifically, in S3, based on segmentation accuracy, intra-class consistency (gray-level variance within a region), and inter-class separation (mean and standard deviation of gray-level values ​​between regions), the steps for outputting segmentation accuracy coefficients through the segmentation accuracy model are as follows:

[0104] S31. Obtain segmentation accuracy, intra-class consistency (grayscale variance within the region), and inter-class separation (mean and standard deviation of grayscale values ​​between regions);

[0105] S32. Perform max-min normalization on the segmentation accuracy, intra-class consistency, and inter-class separation to obtain the segmentation accuracy index, intra-class consistency index, and inter-class separation index.

[0106] S33. Import the segmentation accuracy index, intra-class consistency index, and inter-class separation index into the segmentation accuracy model to obtain the segmentation accuracy coefficients.

[0107] Specifically, the segmentation accuracy is configured such that the output segmentation accuracy coefficient increases when the segmentation accuracy index and the inter-class separation index increase, and the intra-class consistency index decreases; the segmentation accuracy model is expressed as:

[0108]

[0109] Among them, C sa A represents the segmentation precision coefficient. ind V represents the segmentation accuracy index. ind D represents the intra-class consistency index. ind b represents the inter-class separation index. i Represents the weight coefficient and C sa ∈[0.5, 1] ​​and the larger the value, the better the segmentation quality.

[0110] Specifically, when acquiring segmentation accuracy, intra-class consistency (gray-level variance within a region), and inter-class separation (mean and standard deviation of gray-level values ​​between regions), segmentation accuracy refers to the degree of consistency between the image segmentation result and the ground truth. Its function is to quantify the accuracy of the segmentation algorithm. Segmentation accuracy can be calculated based on pixel-level matching, such as by calculating the Jaccard similarity coefficient or Dice coefficient to measure the overlap between the segmented region and the ground truth region. Another method is to calculate the pixel classification accuracy, i.e., the proportion of correctly classified pixels out of the total number of pixels. Intra-class consistency (gray-level variance within a region) refers to the uniformity of the gray-level values ​​of pixels within each segmented region. Its function is to evaluate the internal homogeneity of the segmented regions. It is usually obtained by calculating the variance of the gray-level values ​​of all pixels within each segmented region. The smaller the variance, the more concentrated the gray-level values ​​within the region, and the better the consistency. Another implementation method is to calculate the mean absolute deviation of the gray-level values ​​of pixels within each region to reflect the dispersion of the gray-level values. Inter-class separation (standard deviation of grayscale mean between regions) refers to the degree of difference in pixel grayscale values ​​between different segmented regions, and its function is to evaluate the distinguishability between different regions. It is usually obtained by calculating the standard deviation between the average grayscale values ​​of all segmented regions. The larger the standard deviation, the greater the difference in average grayscale values ​​between different regions, and the better the separation. Another way to achieve this is to calculate the average of the absolute values ​​of the difference between the average grayscale values ​​of any two adjacent regions to measure the sharpness of the region boundaries.

[0111] The step of importing the segmentation accuracy index, intra-class consistency index, and inter-class separation index into the segmentation accuracy model to obtain the segmentation accuracy coefficient involves inputting the normalized indices into a predefined mathematical model to calculate a comprehensive segmentation accuracy coefficient. Its function is to quantitatively evaluate the overall segmentation quality based on the relative importance of each index. This process is typically executed by a calculation module or algorithm that receives the three indices as input, calculates them according to the model formula, and finally outputs a single numerical value as the segmentation accuracy coefficient. The segmentation accuracy model is a nonlinear combination function used to combine the three normalized indices into a single segmentation accuracy coefficient. Its function is to provide a quantitative and comparable indicator to reflect the overall quality of image segmentation. The (1-A) in the model... ind ) and (1-D ind The design of A is to convert all items into a "smaller is better" measure, because A ind and B ind The larger the value, the better the quality, while V... ind The smaller the value, the better the quality. The weighted sum term b1(1-A) in the denominator... ind )+b2V ind +b3(1-D ind The smaller the value, the better the overall value of C. saA larger value aligns with the definition that "a larger value indicates better segmentation quality." Weight coefficient b i This allows for adjusting the importance of different metrics based on specific application scenarios or expert experience. For example, some applications may prioritize segmentation accuracy, while others may focus more on the homogeneity of regions. This model ensures that C... sa The value falls within the range of [0.5,1], providing a bounded and easily interpretable quality assessment criterion.

[0112] This invention addresses the potential bias in traditional methods for evaluating segmentation quality by introducing a comprehensive segmentation accuracy model. First, by acquiring three key indicators—segmentation accuracy, intra-class consistency, and inter-class separation—it ensures a multi-dimensional evaluation of the segmentation results. Segmentation accuracy directly reflects the accuracy of the segmentation results, intra-class consistency focuses on the homogeneity within segmented regions, and inter-class separation measures the distinguishability between different regions. These three indicators comprehensively characterize segmentation quality from different perspectives. Subsequently, these original indicators undergo min-max normalization, converting them into dimensionless exponents. This eliminates differences in their dimensions and numerical ranges, allowing for fair comparison and combination in subsequent calculations. Based on this, these normalized exponents are imported into a pre-defined segmentation accuracy model. This model cleverly combines the segmentation accuracy index, intra-class consistency index, and inter-class separation index with weights. For the segmentation accuracy index and the inter-class separation index, the complement (1-A) is used to calculate the weighted average. ind ) and (1-D ind This ensures that each term in the denominator represents the degree of "quality deficiency," meaning the smaller these terms are, the better the overall quality. The intraclass consistency index V ind Since a smaller value is always better, we use it directly. In this way, the model can calculate a segmentation accuracy coefficient between 0.5 and 1. The larger the value of this coefficient, the better the overall quality of image segmentation.

[0113] The introduction of this segmentation accuracy coefficient is closely linked to other components of the multi-level threshold Kapur entropy image segmentation method based on the MSh model proposed in this invention. Specifically, this segmentation accuracy coefficient, as one of the important inputs to the threshold optimization model, together with the signal-to-noise-efficiency matching coefficient, determines the optimal number of thresholds. By providing a more comprehensive and accurate segmentation quality assessment, this scheme enables the threshold optimization model to more intelligently adjust the number of thresholds dynamically based on image content and algorithm performance, avoiding the limitations of traditional fixed threshold number strategies. For example, when the segmentation accuracy coefficient is high, it indicates that the current segmentation quality is good, and the threshold optimization model may be more inclined to maintain or fine-tune the number of thresholds; while when the segmentation accuracy coefficient is low, it may prompt the model to explore new combinations or numbers of thresholds to improve the segmentation effect. This synergistic effect allows the entire image segmentation method to achieve a better balance between accuracy, efficiency, and resource consumption, thereby improving the algorithm's adaptability and overall performance.

[0114] As a specific implementation method, when obtaining segmentation accuracy, intra-class consistency, and inter-class separation, the image to be segmented can first be compared with a pre-prepared ground truth label image, and the pixel-level Jaccard similarity coefficient can be calculated as the segmentation accuracy. Next, for the segmented image, each segmented region is traversed, and the variance of the grayscale values ​​of all pixels within that region is calculated as the intra-class consistency. Simultaneously, the average grayscale value of all segmented regions is calculated, and the standard deviation between these average grayscale values ​​is obtained as the inter-class separation. Subsequently, these obtained raw values ​​are subjected to min-max normalization. For example, weight coefficients b1 = 0.4, b2 = 0.3, and b3 = 0.3 can be set to indicate that segmentation accuracy has a relatively high weight in the evaluation. According to the formula... Calculate the final segmentation accuracy coefficient. For example, if A ind =0.9, V ind =0.1, D ind =0.8, then C sa ≈0.885. This calculated C sa The value represents the overall quality assessment of the current image segmentation result.

[0115] Through the above technical solution, this invention provides a more comprehensive and accurate segmentation quality evaluation mechanism. This solution is no longer limited to a single segmentation accuracy index, but comprehensively considers three key dimensions: segmentation accuracy, intra-class consistency, and inter-class separation. This multi-dimensional evaluation method allows the segmentation accuracy coefficient to more realistically reflect the actual effect of image segmentation, avoiding misjudgments caused by one-sided evaluation. For example, even if the segmentation accuracy is high, if the intra-class consistency is poor or the inter-class separation is low, the coefficient can effectively identify the shortcomings in segmentation quality. Furthermore, this comprehensive segmentation accuracy coefficient, as an important input to the subsequent threshold optimization model, can significantly improve the adaptability and robustness of the entire multi-level threshold Kapur entropy image segmentation method. Since this coefficient can accurately quantify the quality of the current segmentation result, the threshold optimization model can dynamically adjust the target optimal threshold number based on this information, combined with the signal-to-noise-efficiency matching coefficient. This allows the algorithm to intelligently find the optimal balance between segmentation quality, computational efficiency, and resource consumption according to the complexity of different images and real-time performance requirements, thereby effectively solving the problems of inflexibility and difficulty in adapting to complex scenes with a fixed threshold number in traditional methods, ultimately achieving superior image segmentation results.

[0116] Specifically, in S4, the steps for outputting the signal-noise-efficiency matching coefficients based on the calculated density coefficients, optimized convergence characteristic coefficients, peak signal-to-noise ratio, and total convergence running time using the signal-to-noise-efficiency matching model are as follows:

[0117] S41. Perform maximum-maximum normalization on the peak signal-to-noise ratio to obtain the signal-to-noise ratio exponent.

[0118] S42. Calculate the ratio of the total convergence runtime to the reference runtime to obtain the runtime index;

[0119] S43. Based on the calculated density coefficient and optimized convergence characteristic coefficient, the efficiency basic coefficient is obtained through the efficiency basic model.

[0120] S44. Import the efficiency base coefficient, signal-to-noise ratio index, and runtime index into the signal-to-noise-efficiency matching model to obtain the signal-to-noise-efficiency matching coefficient.

[0121] Specifically, the basic efficiency model is represented as follows:

[0122]

[0123] Among them, C z C represents the basic efficiency coefficient. cd C represents the density coefficient. oc This represents the convergence characteristic coefficient for optimization.

[0124] Specifically, the signal-to-noise-efficiency matching model is expressed as:

[0125] C se =C z p ind (1-exp(-η ind ));

[0126] Among them, C se C represents the signal-to-noise-efficiency matching coefficient. z p represents the basic efficiency coefficient. ind Signal-to-noise ratio exponent, η ind C represents the runtime index. sa The larger the value of ∈[0,1], the higher the overall quality-time benefit of the algorithm under specific resource consumption.

[0127] Specifically, Peak Signal-to-Noise Ratio (PSNR) is a commonly used objective metric for measuring image quality. It assesses the degree of distortion between the compressed or processed image and the original image. Its value is usually expressed in decibels (dB); a higher value indicates less image distortion, meaning better image quality. In image segmentation, PSNR reflects the similarity between the segmentation result and the ideal segmentation result, thus indirectly evaluating the quality of the segmentation algorithm. Total convergence runtime refers to the total time consumed by an image segmentation algorithm from the start of execution to reaching convergence, and is one of the key indicators for measuring algorithm efficiency. Reference runtime is a benchmark time used for comparison with the total convergence runtime. It can be the average runtime obtained through benchmark testing, or the theoretically optimal time dynamically calculated based on factors such as image size and complexity. Furthermore, the reference runtime can also be determined by statistically analyzing multiple algorithms with known performance on the same test set and taking their average or median. Ratio processing involves dividing a numerical value by another reference value to obtain a relative proportion or exponent. This converts absolute values ​​into relative quantities, thus better reflecting their performance in a specific context. The running time exponent is a value obtained by comparing the total convergence running time with the reference running time. It reflects the algorithm's time efficiency; generally, a smaller value indicates a faster and more efficient algorithm. The density coefficient C is calculated. cd This is a metric for measuring the computational efficiency of an algorithm; a higher value generally indicates greater computational overhead and lower efficiency. The optimization convergence characteristic coefficient C... oc This is a metric for evaluating the convergence performance of an algorithm; a higher value indicates better convergence characteristics. Efficiency baseline coefficient C z This is a comprehensive index output by the efficiency model, used to quantify the overall efficiency of the algorithm. A higher value generally indicates higher overall algorithm efficiency. Signal-to-noise ratio (SNR) - Efficiency Matching Coefficient C se It is the final indicator output by the signal-to-noise-efficiency matching model. The larger its value, the higher the overall quality-time benefit of the algorithm under specific resource consumption. It is a key indicator for measuring the overall performance of the algorithm.

[0128] This invention aims to dynamically and comprehensively evaluate the overall performance of image segmentation algorithms through a series of refined computational steps, quantifying it into signal-to-noise ratio (SNR)-efficiency matching coefficients to guide subsequent threshold optimization. The scheme first performs maximum-minimum normalization on the peak signal-to-noise ratio (PSNR), unifying the original PNR values ​​from different images or algorithms to a comparable scale, generating a SNR index. This process ensures the fairness and consistency of image quality assessment, avoiding the impact of differences in the original data units on subsequent calculations. Simultaneously, to quantify the algorithm's time efficiency, the total convergence runtime is compared to a preset reference runtime, yielding a runtime index. This relativistic approach allows for effective comparison of the algorithm's speed with a benchmark, objectively reflecting its efficiency level. Based on this, the scheme introduces an efficiency foundation model, which generates efficiency foundation coefficients based on computational density coefficients and optimized convergence characteristic coefficients. The computational density coefficient reflects the algorithm's resource consumption, while the optimized convergence characteristic coefficient evaluates the algorithm's convergence quality and stability. The efficiency foundation model integrates these two dimensions through a specific mathematical relationship, where the computational density coefficient C... cd A larger value indicates lower efficiency, while the optimization convergence characteristic coefficient C... oc A larger value indicates better convergence properties. This model cleverly incorporates C... cd Invert and AND with C oc Take the average, then subtract the result from 1, so that C z A higher value indicates higher overall efficiency, thus balancing resource consumption and convergence quality. Finally, the obtained efficiency baseline coefficient, signal-to-noise ratio exponent, and runtime exponent are imported into the signal-to-noise-efficiency matching model. This model uses C... se =C z p ind (1-exp(-η ind This expression organically combines the overall efficiency of the algorithm, image segmentation quality, and runtime efficiency. Among them, the basic efficiency coefficient C... z The signal-to-noise ratio exponent p represents the algorithm's overall performance in terms of resource consumption and convergence. ind The quality of the segmentation results was quantified, while the running time exponent η ind Then through the exponential function 1-exp(-η) indThe form of () ensures that the impact of runtime on the final coefficient is within a reasonable range, avoiding the excessive dominance of extreme runtime on the overall evaluation. In this way, the signal-to-noise-efficiency matching model can output a single, comprehensive signal-to-noise-efficiency matching coefficient, which fully reflects the combined quality-time benefits achievable by the algorithm under specific resource consumption. This scheme provides a quantified and dynamic signal-to-noise-efficiency matching coefficient, providing crucial input to the upper-level threshold optimization model. It allows threshold optimization to no longer rely solely on a single segmentation quality or efficiency indicator, but to make decisions at a multi-dimensional balance point. Through precise calculation of C... se The threshold optimization model can more accurately determine whether the current algorithm configuration has achieved the best balance between quality, efficiency and resource consumption, thereby guiding the algorithm to adaptively adjust the number of target optimal thresholds. This effectively solves the problem of inflexible threshold selection caused by the lack of a comprehensive evaluation system in traditional methods.

[0129] As a specific implementation method, the calculation of the signal-to-noise ratio-efficiency matching coefficient of the present invention can be performed with reference to the following example. Assume that when segmenting an image, the following data was obtained through monitoring the algorithm's performance: peak signal-to-noise ratio is 30dB; total convergence time is 5 seconds; and the known computational density coefficient C... cd The value is 0.7 (indicating relatively high computational cost); the known optimization convergence coefficient C oc A value of 0.8 (indicating good convergence characteristics). First, perform maximum-minimum normalization of the peak signal-to-noise ratio (PSNR). Assume that in the current application scenario, the theoretical minimum PSNR is 10 dB and the theoretical maximum is 40 dB. Then the PSNR exponent p... ind It can be calculated as: p ind = (30-10) / (40-10) = 20 / 30 = 0.67. This indicates that the quality of the current segmentation result is at a moderately high level. Next, the ratio of the total convergence runtime to the reference runtime is processed. Assume that the reference runtime is determined to be 2 seconds by running the standard algorithm on the benchmark set. Then the runtime exponent η... ind It can be calculated as η ind =5 / 2 = 2.5. This indicates that the current algorithm's running time is 2.5 times the reference running time. Next, based on the calculated density coefficient C... cd And the optimized convergence characteristic coefficient C oc The efficiency base coefficient C is obtained through the efficiency base model. z According to the model formula Substitute the known value: C z =0.55. This basic efficiency coefficient of 0.55 reflects the algorithm's overall performance in terms of resource consumption and convergence characteristics. Finally, the basic efficiency coefficient C... z Signal-to-noise ratio index pind and running time index η ind Import the signal-to-noise ratio (SNR)-efficiency matching model and obtain the SNR-efficiency matching coefficient C. se According to model formula C se =C z p ind (1-exp(-η ind Substitute the calculated value: C se =0.338. The final signal-to-noise-efficiency matching coefficient C is... se It is approximately 0.338. This coefficient will serve as input to the subsequent threshold optimization model to guide the determination of the optimal number of thresholds. For example, if this coefficient is lower than a certain preset target equilibrium point, it may be necessary to adjust the number of thresholds to seek a better quality-efficiency balance.

[0130] Through the above technical solution, this invention provides a specific and quantitative method for calculating the signal-to-noise ratio (SNR)-efficiency matching coefficient, thereby solving the problem of lacking a concrete implementation method to dynamically evaluate the overall quality-time benefits of the algorithm under resource consumption in multi-level threshold Kapur entropy image segmentation methods. This scheme eliminates the dimensional differences in quality assessment between different images and algorithms by normalizing the peak signal-to-noise ratio (PSNR), ensuring the accuracy and comparability of the SNR index. Simultaneously, by comparing the total convergence runtime with the reference runtime, the algorithm's time efficiency can be objectively quantified, avoiding evaluation bias caused by absolute time values. Furthermore, by fusing the computational density coefficient and the optimization convergence characteristic coefficient through an efficiency-based model, this scheme can comprehensively evaluate the algorithm's resource consumption and convergence quality, overcoming the one-sidedness of relying solely on a single indicator. Finally, the SNR-efficiency matching model organically combines the efficiency-based coefficient, the SNR index, and the runtime index to generate a single, comprehensive SNR-efficiency matching coefficient. This coefficient can dynamically and accurately reflect the overall quality-time benefits of the algorithm under specific resource consumption, providing precise input for the upper-level threshold optimization model. Therefore, this scheme enables the threshold optimization model to adjust the target optimal threshold number based on a multi-dimensional, balanced performance evaluation metric, significantly improving the adaptability and overall performance of the image segmentation algorithm. It ensures that the algorithm achieves a better balance between segmentation quality, operational efficiency, and resource consumption in practical applications, avoiding the problems of oversegmentation, undersegmentation, and performance instability caused by fixed threshold numbers or empirical settings in traditional methods.

[0131] Specifically, in S5, the threshold optimization model adaptively adjusts the current optimal threshold number based on the difference between the product of the signal-to-noise ratio-efficiency matching coefficient and the segmentation accuracy coefficient and a preset target equilibrium point, using a smoothing adjustment function to output the target optimal threshold number. The threshold optimization model is expressed as:

[0132] m optimal =m cur (1+tanh(C se C sa -θ));

[0133] Where, m optimal m represents the number of target optimal thresholds. cur C represents the current optimal threshold quantity. se C represents the signal-to-noise-efficiency matching coefficient. sa θ represents the segmentation accuracy coefficient, and θ represents the target equilibrium point (representing the expected value C). se C sa (product level).

[0134] Number of target optimal thresholds m optimal This represents the optimal threshold number suggested by the threshold optimization model for the current image segmentation task. It is the final output of the algorithm's adaptive adjustment, directly guiding subsequent image segmentation operations. The current optimal threshold number m cur This represents the number of thresholds used or considered optimal by the system before this threshold optimization. As one of the inputs to the threshold optimization model, it provides a benchmark for model adjustment, ensuring the continuity and gradualness of threshold number adjustments. Signal-to-noise ratio-efficiency matching coefficient C se It is an indicator that measures the overall benefit of an image segmentation algorithm in terms of output quality and running efficiency under specific resource consumption, reflecting the balance between performance and efficiency. Segmentation accuracy coefficient C sa Used to quantify the accuracy and quality of image segmentation results, providing a comprehensive evaluation of the segmentation performance. The target equilibrium point θ is a preset, adjustable value representing the desired product level of the signal-to-noise-efficiency matching coefficient and the segmentation accuracy coefficient. It allows users or systems to set their preferences for the overall performance of the algorithm according to actual application needs, thereby affecting the direction and magnitude of the threshold adjustment.

[0135] The core of this threshold optimization model lies in utilizing the nonlinear characteristics of the hyperbolic tangent function (tanh) to optimize the overall performance of the algorithm (based on the signal-to-noise ratio-efficiency matching coefficient C). se And segmentation accuracy coefficient C sa The product of the two values ​​(represented by the product of the two values) is compared with the preset target equilibrium point θ. When the algorithm's current overall performance (C) is... se C sa When the value is higher than the target equilibrium point θ, it indicates that the algorithm performs well with the current number of thresholds, and there is even room for improvement. At this point, the output of the tanh function is positive, making the target optimal threshold number m... optimal The current optimal threshold number m curOn the basis of this, a moderate increase is made. Conversely, when the current overall performance of the algorithm is lower than the target equilibrium point θ, the output of the tanh function is negative, causing m to... optimal In m cur Based on this, reduce appropriately. If the current overall performance is close to the target equilibrium point, and the tanh function output is close to zero, then m optimal Will remain with m cur The results are largely the same. This adjustment mechanism based on the tanh function ensures that the adjustment process of the threshold number is smooth and bounded, avoiding the abrupt changes or overshoot problems that may occur with traditional linear adjustment, thereby improving the stability and accuracy of the algorithm's adaptive adjustment. By using the current optimal threshold number m... cur As a benchmark for adjustment, the model ensures the continuity of the threshold number variation, enabling the algorithm to optimize the threshold number in a gradual and controlled manner based on real-time feedback, thereby achieving a dynamic balance between segmentation quality, operating efficiency, and resource consumption.

[0136] As a specific implementation method, the target equilibrium point θ can be set to 0.6, indicating that the algorithm is expected to achieve a certain level of comprehensive performance in terms of both quality and efficiency. Assume that in a certain image segmentation task, the current optimal threshold number m... cur The value is 3. After calculation, the signal-to-noise ratio-efficiency matching coefficient C is obtained. se The segmentation accuracy coefficient C is 0.8. sa It is 0.9. At this time, C se C sa The product is 0.72. Substituting this into the threshold optimization model: m optimal =m cur (1+tanh(C se C sa -θ))=3.357. Considering that the number of thresholds is usually an integer, the system can round it up to 4, or process it according to the preset rounding rules. This indicates that when the current performance is better than expected, the system suggests increasing the number of thresholds to potentially further improve the segmentation effect. To give another example, in another scenario, if the current optimal number of thresholds m... cur The value remains 3, but the algorithm performance is poor, for example, C... se The value is 0.4, C sa It is 0.5. At this time, C se C sa The product is 0.2. Substituting into the model: m optimal =m cur (1+tanh(C se C sa -θ)) = 1.863. The system can round this down to 2. This indicates that, given the current performance is below expectations, the system suggests reducing the number of thresholds to decrease computational complexity or avoid over-splitting.

[0137] Through the above technical solution, this invention provides a specific and operable mathematical model for adaptively adjusting the optimal number of thresholds in the image segmentation process. This model utilizes the smoothing properties of the hyperbolic tangent function to effectively avoid abrupt changes or instabilities that may occur during threshold adjustment, thereby ensuring the accuracy and controllability of the adjustment. By employing signal-to-noise-efficiency matching coefficients and segmentation accuracy coefficients, this model can comprehensively evaluate the algorithm's overall performance in terms of quality, efficiency, and resource consumption, and make intelligent decisions based on a preset target balance point. This enables the image segmentation method to dynamically optimize the number of thresholds according to different image content and real-time performance requirements, thereby effectively controlling computational costs while ensuring segmentation quality, significantly improving the algorithm's adaptability and overall performance.

[0138] In an example using the multi-level threshold Kapur entropy image segmentation method based on the MSh model, Figure 2 and Figure 4 The original images from the BSD dataset selected in the image segmentation experiments are shown. Figure 3 Showing Figure 2 The iterative computation time for image segmentation of the original image under different computational methods. Figure 5 Showing Figure 4 The iterative computation time of image segmentation of the original image under different computational conditions, in Figure 4 and 5 In the diagram, the positions of the threshold values ​​for the image are marked with lines of the same color. The horizontal axis represents the size of the threshold set set for the image, with the equivalent threshold range set to three intervals: 2, 3, and 5. To better compare the performance of the proposed algorithm, image segmentation results obtained using the MFO, SSA, and EMO algorithms are compared with the proposed MSK algorithm. Figure 4 In the first experiment, the test image was a "couple". The overall operational efficiency of the MPO and SSA algorithms was not high. The MSK algorithm had the best operational efficiency, followed by the EMO algorithm. In the second experiment, the test image was a "photographer's image". The MPO algorithm took the longest time to converge. The MFO algorithm took 3.54 seconds, 5.26 seconds, and 8.65 seconds for thresholds of 2, 3, and 5, respectively. The MSK (Multi-Level Threshold Kapur Entropy Image Segmentation Method based on the MSh Model) algorithm performed best in terms of operational efficiency, with running times of 0.85 seconds, 2.15 seconds, and 3.46 seconds for thresholds of 2, 3, and 5, respectively. Therefore, the proposed MSK algorithm has excellent operational efficiency and requires the shortest time for image segmentation. The number of thresholds affects the time required for each algorithm to segment the image, but the proposed MSK algorithm is 356%, 289%, and 71% faster than the MPO, SSA, and EMO algorithms, respectively, in terms of running time efficiency.

[0139] In summary, this invention overcomes the limitations of existing technologies by constructing a multi-dimensional, dynamic evaluation system. By introducing a computational density coefficient, this invention comprehensively quantifies the algorithm's time efficiency, space efficiency, and convergence speed, contrasting with the coarse assessment of resource consumption in traditional methods. The introduction of an optimized convergence characteristic coefficient allows for accurate measurement of the algorithm's convergence robustness and efficiency, avoiding potential convergence instability or inefficiency issues in traditional methods. The segmentation accuracy coefficient comprehensively reflects the quality of the segmentation results from multiple dimensions, providing a more comprehensive picture than a single segmentation accuracy indicator. Through a signal-to-noise-efficiency matching model, this invention effectively combines computational efficiency, convergence characteristics, segmentation quality, and total running time, outputting a signal-to-noise-efficiency matching coefficient. This allows the algorithm to balance quality and efficiency within a unified framework, a feature lacking in existing technologies. Based on these comprehensive evaluation coefficients, the threshold optimization model dynamically outputs the optimal threshold number. This adaptive adjustment mechanism allows the algorithm to flexibly increase or decrease the threshold number based on the actual complexity of the image content and real-time performance, effectively solving the oversegmentation or undersegmentation problems caused by a fixed threshold number in traditional methods. This invention provides a precise and comprehensive method for evaluating the computational efficiency of algorithms. By standardizing and integrating data from multiple dimensions such as time efficiency, space efficiency, and convergence speed, it effectively solves the problems of inaccurate efficiency quantification and incomplete indicators in traditional evaluation methods. The computational density coefficient obtained thereby can accurately reflect the actual resource consumption of the algorithm, providing a reliable input for the subsequent signal-noise-efficiency matching model. This enables the entire image segmentation method to more accurately balance segmentation quality and computational efficiency when adaptively adjusting the number of thresholds, avoiding oversegmentation or undersegmentation caused by efficiency evaluation bias, and significantly improving the robustness and performance of the algorithm in practical applications. This invention provides a systematic and standardized method for calculating the optimal convergence characteristic coefficient, which can accurately and comprehensively evaluate the convergence performance of image segmentation algorithms. It solves the problems of single indicators, inconsistent dimensions, and inconsistent optimization directions in traditional evaluation methods. By obtaining multiple raw indicators such as the final energy function value, the average fitness value at convergence, and the smoothness of the convergence curve, and performing max-min normalization and complement transformation on them, it ensures that all evaluation indicators are compared on a unified scale and in a uniform optimization direction. This approach avoids evaluation bias caused by different indicator dimensions or conflicting optimization objectives, resulting in a higher optimization convergence characteristic coefficient C. oc This can truly reflect the overall convergence performance of the algorithm. Furthermore, the optimized convergence characteristic coefficient C... oc As input, with the density coefficient C cd They work together to affect the signal-to-noise-efficiency matching model, thus influencing the signal-to-noise-efficiency matching coefficient C. seThe calculation. This linkage mechanism allows the algorithm to consider not only computational efficiency and segmentation accuracy when evaluating its overall performance, but also fully incorporate the algorithm's own convergence quality and stability. Ultimately, in the threshold optimization model, based on a more comprehensive and accurate signal-to-noise-efficiency matching coefficient C... se And segmentation accuracy coefficient C saIt can determine the optimal threshold number of the target more intelligently and adaptively, which significantly improves the robustness and adaptability of the image segmentation method in complex scenarios. It can effectively balance the consumption of computing resources and convergence efficiency while ensuring the segmentation quality, and avoid the risk of over-segmentation or under-segmentation, thus achieving better overall performance in practical applications. This invention provides a more comprehensive and accurate segmentation quality evaluation mechanism, no longer limited to a single segmentation accuracy index, but comprehensively considering three key dimensions: segmentation accuracy, intra-class consistency, and inter-class separation. This multi-dimensional evaluation method allows the segmentation accuracy coefficient to more realistically reflect the actual effect of image segmentation, avoiding misjudgments caused by one-sided evaluation. For example, even if the segmentation accuracy is high, if the intra-class consistency is poor or the inter-class separation is low, the coefficient can effectively identify the shortcomings in segmentation quality. Furthermore, this comprehensive segmentation accuracy coefficient serves as an important input to the subsequent threshold optimization model, significantly improving the adaptability and robustness of the entire multi-level threshold Kapur entropy image segmentation method. Since this coefficient can accurately quantify the quality of the current segmentation result, the threshold optimization model can dynamically adjust the target optimal threshold number based on this information and in combination with the signal-to-noise-efficiency matching coefficient. This allows the algorithm to intelligently find the best balance between segmentation quality, computational efficiency, and resource consumption according to the complexity of different images and real-time performance requirements, thereby effectively solving the problem of the lack of flexibility and difficulty in adapting to complex scenarios in traditional methods with a fixed number of thresholds, ultimately achieving better image segmentation results. This invention provides a specific and quantitative method for calculating the signal-to-noise ratio (SNR)-efficiency matching coefficient, thereby solving the problem of lacking a concrete implementation method to dynamically evaluate the quality-time comprehensive benefits of the algorithm under resource consumption in multi-level threshold Kapur entropy image segmentation methods. This scheme eliminates the dimensional differences in quality evaluation between different images and algorithms by normalizing the peak signal-to-noise ratio (PSNR), ensuring the accuracy and comparability of the SNR index. At the same time, it performs a ratio processing of the total convergence running time to the reference running time, so that the time efficiency of the algorithm can be objectively quantified, avoiding the evaluation bias caused by absolute time values. Furthermore, by fusing the computational density coefficient and the optimized convergence characteristic coefficient through an efficiency-based model, this scheme can comprehensively evaluate the resource consumption and convergence quality of the algorithm, overcoming the one-sidedness of relying on a single indicator.Ultimately, the signal-to-noise ratio (SNR) matching model organically combines the efficiency base coefficient, the SNR exponent, and the runtime exponent to generate a single, comprehensive SNR-efficiency matching coefficient. This coefficient dynamically and accurately reflects the overall quality-time benefits of the algorithm under specific resource consumption, providing precise input for the upper-level threshold optimization model. Therefore, this scheme enables the threshold optimization model to adjust the target optimal threshold number based on a multi-dimensional, balanced performance evaluation index, significantly improving the adaptability and overall performance of the image segmentation algorithm. It ensures that the algorithm can achieve a better balance between segmentation quality, runtime efficiency, and resource overhead in practical applications, avoiding the problems of oversegmentation, undersegmentation, and performance instability caused by fixed threshold numbers or empirical settings in traditional methods. This invention provides a specific and operable mathematical model for adaptively adjusting the optimal number of thresholds in the image segmentation process. This model utilizes the smoothing properties of the hyperbolic tangent function to effectively avoid abrupt changes or instabilities that may occur during threshold adjustment, thus ensuring the accuracy and controllability of the adjustment. With the help of signal-to-noise-efficiency matching coefficients and segmentation accuracy coefficients, this model can comprehensively evaluate the algorithm's overall performance in terms of quality, efficiency, and resource consumption, and make intelligent decisions based on a preset target balance point. This enables the image segmentation method to dynamically optimize the number of thresholds according to different image content and real-time performance requirements, thereby effectively controlling computational costs while ensuring segmentation quality, and significantly improving the algorithm's adaptability and overall performance.

[0140] Although embodiments of the invention have been shown and described, it will be understood by those skilled in the art that various changes, modifications, substitutions and alterations can be made to these embodiments without departing from the principles and spirit of the invention, the scope of which is defined by the appended claims and their equivalents.

Claims

1. A multi-level threshold Kapur entropy image segmentation method based on the MSh model, characterized in that, Includes the following steps: S1. Based on the average running time of a single iteration, the peak memory usage, and the number of iterations required to achieve a specific accuracy, the calculated density coefficients are output through the calculated density model. S2. Based on the final energy function value, the average fitness value at convergence, and the smoothness of the convergence curve, the optimized convergence characteristic coefficients are output by optimizing the convergence characteristic model. S3. Based on segmentation accuracy, intra-class consistency, and inter-class separation, the segmentation accuracy coefficients are output through the segmentation accuracy model. S4. Based on the peak signal-to-noise ratio and total convergence running time under the calculated density coefficient and optimized convergence characteristic coefficient, the signal-to-noise-efficiency matching coefficient is output through the signal-to-noise-efficiency matching model. S5. Based on the signal-to-noise-efficiency matching coefficient, segmentation accuracy coefficient, and the current optimal threshold number, the target optimal threshold number is output through the threshold optimization model.

2. The multi-level threshold Kapur entropy image segmentation method based on the MSh model according to claim 1, characterized in that: In step S1, the steps for calculating density coefficients based on the average running time of a single iteration, the peak memory usage, and the number of iterations required to achieve a specific level of accuracy are as follows: S11. Obtain the average running time of a single iteration, the peak memory usage, and the number of iterations required to achieve a specific level of accuracy. S12. Ratio the average running time of a single iteration, the peak memory usage, and the number of iterations required to reach a specific accuracy with the corresponding reference values ​​to obtain the time efficiency index, space efficiency index, and convergence speed index. S13. Import the time efficiency index, space efficiency index, and convergence speed index into the computational density coefficient model to obtain the computational density coefficient.

3. The multi-level threshold Kapur entropy image segmentation method based on the MSh model according to claim 2, characterized in that: The computational density model is configured such that as the computational load reflected by multiple efficiency indices increases, the output computational density coefficient decreases accordingly; the computational density coefficient model is expressed as: C cd =exp(-t ind -M ind -N ind ); Among them, C cd This indicates the calculation of the density coefficient, t ind M represents the time efficiency index. ind N represents the space efficiency index. ind C represents the convergence rate exponent. cd ∈(0,1] and the larger the value, the lower the computational efficiency.

4. The multi-level threshold Kapur entropy image segmentation method based on the MSh model according to claim 1, characterized in that: In step S2, the step of optimizing the convergence characteristic coefficients by optimizing the convergence characteristic model based on the final energy function value, the average fitness value at convergence, and the smoothness of the convergence curve is as follows: S21. Obtain the final energy function value, the average fitness value at convergence, and the smoothness of the convergence curve; S22. Perform max-min normalization on the average fitness value at convergence to obtain the threshold quality index. S23. Perform max-min normalization on the final energy function value and the smoothness of the convergence curve to obtain the segmentation quality factor and smoothness factor. S24. Take the complements of the segmentation quality factor and the smoothing factor to obtain the segmentation quality index and the smoothing index; S25. Import the threshold quality index, segmentation quality index, and smoothness index into the optimization convergence characteristic model to obtain the optimization convergence characteristic coefficients.

5. The multi-level threshold Kapur entropy image segmentation method based on the MSh model according to claim 4, characterized in that: As the exponents reflecting threshold quality, segmentation quality, and convergence smoothness increase, the output optimization convergence characteristic coefficients also increase; the optimization convergence characteristic model is expressed as: C oc =a1F ind +a2E ind +a3σ ind ; Among them, C oc F represents the convergence characteristic coefficient of the optimization. ind E represents the threshold quality index. ind σ represents the segmentation quality index. ind The smoothing exponent, a i Represents the weight coefficient and C oc The larger the value in [0, 1], the better the optimization convergence characteristics.

6. The multi-level threshold Kapur entropy image segmentation method based on the MSh model according to claim 1, characterized in that: In step S3, the step of outputting the segmentation accuracy coefficients based on the segmentation accuracy model, considering segmentation accuracy, intra-class consistency, and inter-class separation is as follows: S31. Obtain the segmentation accuracy, intra-class consistency, and inter-class separation degree; S32. Perform max-min normalization on the segmentation accuracy, intra-class consistency, and inter-class separation to obtain the segmentation accuracy index, intra-class consistency index, and inter-class separation index. S33. Import the segmentation accuracy index, intra-class consistency index, and inter-class separation index into the segmentation accuracy model to obtain the segmentation accuracy coefficients.

7. The multi-level threshold Kapur entropy image segmentation method based on the MSh model according to claim 6, characterized in that: The segmentation accuracy is configured such that when the segmentation accuracy index and the inter-class separation index increase, and the intra-class consistency index decreases, the output segmentation accuracy coefficient increases; the segmentation accuracy model is expressed as: Among them, C sa A represents the segmentation precision coefficient. ind V represents the segmentation accuracy index. ind D represents the intra-class consistency index. ind b represents the inter-class separation index. i Represents the weight coefficient and C sa ∈[0.5, 1] ​​and the larger the value, the better the segmentation quality.

8. The multi-level threshold Kapur entropy image segmentation method based on the MSh model according to claim 1, characterized in that: In step S4, the step of outputting the signal-noise-efficiency matching coefficients based on the calculated density coefficients, the peak signal-to-noise ratio under optimized convergence characteristic coefficients, and the total convergence running time through the signal-to-noise-efficiency matching model is as follows: S41. Perform maximum-maximum normalization on the peak signal-to-noise ratio to obtain the signal-to-noise ratio exponent. S42. Calculate the ratio of the total convergence runtime to the reference runtime to obtain the runtime index; S43. Based on the calculated density coefficient and optimized convergence characteristic coefficient, the efficiency basic coefficient is obtained through the efficiency basic model. S44. Import the efficiency base coefficient, signal-to-noise ratio index, and runtime index into the signal-to-noise-efficiency matching model to obtain the signal-to-noise-efficiency matching coefficient.

9. The multi-level threshold Kapur entropy image segmentation method based on the MSh model according to claim 1, characterized in that: The efficiency-based model is expressed as follows: Among them, C z C represents the basic efficiency coefficient. cd C represents the density coefficient. oc This represents the convergence characteristic coefficient for optimization. The signal-to-noise-efficiency matching model is represented as: C se =C z p ind (1-exp(-η ind )); Among them, C se C represents the signal-to-noise-efficiency matching coefficient. z p represents the basic efficiency coefficient. ind Signal-to-noise ratio exponent, η ind C represents the runtime index. sa The larger the value of ∈[0,1], the higher the overall quality-time benefit of the algorithm under specific resource consumption.

10. The multi-level threshold Kapur entropy image segmentation method based on the MSh model according to claim 1, characterized in that: In step S5, the threshold optimization model adaptively adjusts the current optimal threshold number based on the difference between the product of the signal-to-noise ratio-efficiency matching coefficient and the segmentation accuracy coefficient and a preset target equilibrium point, using a smoothing adjustment function to output the target optimal threshold number. The threshold optimization model is expressed as follows: m optimal =m cur (1+tanh(C se C sa –θ)); Where, m optimal m represents the number of target optimal thresholds. cur C represents the current optimal threshold quantity. se C represents the signal-to-noise-efficiency matching coefficient. sa θ represents the segmentation accuracy coefficient, and θ represents the target equilibrium point.

Citation Information

Patent Citations

  • Two-dimensional segmentation method for multi-threshold images

    CN112200812B