An Ising model-based medical image region reliability map generation method and system
By constructing a credibility map of medical image regions using the Ising model, the problem of generating credibility maps with logical coherence and overall structural rationality in existing technologies is solved, achieving more accurate credibility map generation and improving the interpretability and clinical usability of medical image analysis.
Patent Information
- Application Number
- CN202611314325.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-08-27
- Publication Date
- 2026-11-20
AI Technical Summary
Existing medical image analysis models struggle to generate credibility maps that reflect the coherence of logical relationships between regions and the rationality of the overall structure when dealing with noise, artifacts, low contrast, or complex anatomical structures, thus affecting the reliability of clinical diagnosis.
The Ising model is used to optimize the relationships between regions by simulating the annealing process, construct a graph structure, and generate a confidence graph by combining the statistical attributes and connection weights of local regions, and label low confidence regions.
The generated confidence graph can more accurately identify errors or uncertainties in model predictions, improving the interpretability and clinical usability of the results.
Smart Images

Figure CN123141784A_ABST
Abstract
Description
Technical Field
[0001] This invention belongs to the field of image analysis technology, specifically relating to a method and system for generating a confidence map of medical image regions based on the Ising model. Background Technology
[0002] In the field of medical image analysis, automated models (such as deep learning networks) are widely used for tasks such as lesion segmentation, tissue identification, and image reconstruction. The predictions output by these models are typically presented as pixel-level labels or probability maps. However, due to issues such as noise, artifacts, low contrast, or complex anatomical structures in medical images, the model's predictions in certain areas may appear unstable or unreliable. If the system fails to identify and flag these low-confidence areas, it may mislead clinicians' judgments, thereby affecting the safety of the diagnosis.
[0003] In existing technologies, the predicted probability output by the model is typically used as a measure of uncertainty, or variance is estimated through multiple inferences (such as Dropout sampling) to generate a confidence map. However, these methods rely on the probability distribution within the model, making it difficult to effectively reflect the consistency of spatial context, and they lack effective modeling capabilities when dealing with ambiguous prediction boundaries or inconsistencies within regions. Therefore, how to generate a confidence map that can reflect the coherence of logical relationships between regions and the rationality of the overall structure has become a pressing technical challenge. Summary of the Invention
[0004] The purpose of this invention is to provide a method and system for generating a medical image region confidence map based on the Ising model. This method not only considers the prediction stability of a single region, but also introduces the interrelationships between regions. By simulating the annealing process, it optimizes the overall confidence configuration and effectively identifies prediction regions that are inconsistent with the surrounding environment or are unstable, thereby solving the problems mentioned in the background art.
[0005] To achieve the above objectives, the present invention adopts the following technical solution: a method for generating a medical image region confidence map based on the Ising model, comprising the following steps: The predicted output of the medical image is obtained, and the predicted output is smoothed to obtain a smoothed image. Based on the smoothed image, multiple local regions are divided, and the geometric and statistical properties of each region are recorded. A graph structure is constructed using the regions as nodes. Valid connection edges are filtered according to the adjacency relationship between regions. The comprehensive similarity between region pairs is calculated to determine the connection weight. The initial state variables of each node are set based on the connection weight and the statistical attributes of each region. Construct a global energy expression, which includes an inter-regional interaction energy term and an individual tendency energy term. The inter-regional interaction energy term is composed of the product of the connection weight and the state of the adjacent node, and the individual tendency energy term is composed of the product of the external tendency term and the node state. The execution state evolution process starts from the initial state variable, adjusts the node state through simulated annealing mechanism, and records the node state configuration after the last state change as the system stable state. The system's stable state is mapped back to the image space to generate a confidence map, and low-confidence regions are labeled. The labeling is based on the system's stable state and dynamic threshold segmentation.
[0006] Preferably, the smoothing process includes: The predicted output is filtered using an unsharpened mask operation to obtain the enhanced image; The image is convolved using a Gaussian kernel, and the standard deviation of the kernel is set according to the image resolution. The difference between the original image and the blurred image is multiplied by the enhancement intensity parameter to form a compensation term; The compensation term is added back to the original image to generate a smooth image.
[0007] Preferably, the division of multiple local regions includes: A superpixel segmentation algorithm is used to cluster the smooth image to generate initial region divisions; The number of regions is set based on the initial region division, and the distribution of cluster centers is determined according to the image size; Pixels are assigned a cluster center, and the centroid coordinates and average predicted value of each region are calculated. Update the cluster centers of each region and reallocate pixels, repeating the iteration until the region boundaries are stable.
[0008] Preferably, the construction graph structure includes: Construct an undirected graph, treating each local region as a node in the graph; Based on the region corresponding to the node, detect whether there is an intersection between the pixel boundaries of any two regions. If there is, generate candidate connection edges. For each candidate connection edge corresponding to a region pair, calculate the difference between their average predicted values and the distance between their centroids; Using the difference and distance as input, the connection weight of each candidate connection edge is calculated through an exponential decay function.
[0009] Preferably, setting the initial state variables for each node includes: Assign a binary state to each node, where +1 represents trustworthy and -1 represents untrustworthy; Based on the binary state setting rules, the standard deviation of the predicted values within each region is compared with a preset threshold. For regions where the standard deviation is less than the threshold, the initial state of the corresponding node is set to +1; The external tendency term is obtained by multiplying the average predicted value of the region by the scaling factor.
[0010] Preferably, the construction of the global energy expression includes: For each valid connection edge, calculate the product of its connection weight and the product of the states of the two connected nodes; Summing the products of all connected edges and taking the negative value yields the inter-regional interaction energy term; Based on the construction method of the inter-regional interaction energy term, the product of the external tendency term and the node state is calculated for each node; Summing the products corresponding to all nodes and taking the negative value yields the individual tendency energy term.
[0011] Preferably, the execution state evolution process includes: Set the initial temperature value and start the iterative loop; At the current temperature, randomly select a node and calculate the energy change caused by its state reversal based on the connection weight and the states of its neighboring nodes; If the energy change is less than zero, then the state of the receiving node is flipped. If the energy change is greater than zero, a random number is generated and compared with the exponential decay probability calculated based on the energy change and the current temperature. The result of the comparison determines whether to accept the state flip.
[0012] Preferably, the execution state evolution process further includes: After completing a round of status checks on all nodes, the current temperature is multiplied by the cooling coefficient to obtain the updated temperature; The next round of state adjustment will continue based on the updated temperature, and the temperature update and state adjustment process will be repeated. The iteration stops when the temperature drops to the preset lower limit, and the configuration after the last state adjustment is retained.
[0013] Preferably, the generation of the credibility map includes: The system steady state of each region is converted into a continuous value between 0 and 1; Assign continuous values to all pixel positions within the region; Perform bilinear interpolation on the pixel-level confidence map; Calculate the mean and standard deviation of the confidence level for the entire image, and use the mean minus a multiple of the standard deviation as the dynamic threshold.
[0014] On the other hand, this invention proposes a medical image region confidence map generation system based on the Ising model, comprising: The image processing module is used to receive the predicted output of medical images and perform smoothing processing; The region segmentation module is used to segment local regions based on a smooth image and record their attributes. The graph construction module is used to construct the graph structure between regions and calculate the connection weights. The energy optimization module is used to construct the global energy expression and perform state evolution; The results generation module is used to map the system's stable state into a confidence map and mark low-confidence regions. The feedback interface module is used to output credibility graphs and quality reports, and supports result evaluation in multi-task scenarios.
[0015] Technical effects and advantages of the present invention: The method and system for generating medical image region confidence maps based on the Ising model proposed in this invention have the following advantages compared with the prior art: This invention models local regions as graph nodes, constructs connection weights using inter-region similarity, sets initial states based on regional statistical characteristics, and optimizes the global state through an energy minimization mechanism, ultimately generating a confidence graph reflecting prediction consistency. This method not only considers the prediction stability of individual regions but also introduces inter-regional relationships, optimizing the overall confidence configuration through simulated annealing, effectively identifying prediction regions that are inconsistent with their surroundings or unstable. The resulting confidence graph more accurately labels regions where model predictions may contain errors or uncertainties, improving the interpretability and clinical usability of the results. Attached Figure Description
[0016] Figure 1 This is a flowchart of the medical image region confidence map generation method based on the Ising model of the present invention; Figure 2 This is a block diagram of the medical image region confidence map generation system based on the Ising model of the present invention. Detailed Implementation
[0017] 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. The specific embodiments described herein are merely used to explain the present invention and are not intended to limit the present invention. 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.
[0018] This invention provides, for example Figure 1This paper presents a method for generating a confidence map of medical image regions based on the Ising model. The aim is to generate a visual atlas reflecting the confidence level of each region by performing structured analysis on the predicted outputs of different regions in an image. This approach is independent of the internal structure of the original image processing workflow and can run independently based on any image prediction results. It is applicable to various imaging modalities and task types, such as MRI brain tissue segmentation, CT lung reconstruction, or quality assessment after ultrasound image registration. The method revolves around a graph structure composed of image regions. Utilizing the principle of physics-inspired energy minimization, it infers the stability and consistency of each region in the final result, thereby outputting a continuous or discrete confidence distribution map to assist clinical interpretation or further judgment by automated decision-making systems.
[0019] In this example, the method for generating a confidence map of a medical image region based on the Ising model includes the following steps: The predicted output of the medical image is obtained, and the predicted output is smoothed to obtain a smoothed image. Specifically, the smoothing process includes: filtering the predicted output using an unsharpened mask operation to obtain an enhanced image; convolving the image using a Gaussian kernel, with the standard deviation of the kernel set according to the image resolution; multiplying the difference between the original image and the blurred image by an enhancement intensity parameter to form a compensation term; and adding the compensation term back to the original image to generate a smoothed image.
[0020] A combination of unsharpened masks and Gaussian filtering is used to smooth medical images. This method not only effectively removes noise but also enhances image details. By flexibly adjusting the enhancement intensity parameter to adapt to different image characteristics, it improves image quality and the accuracy of subsequent analysis. This approach enhances the visual appeal and resolution of images while preserving key information, contributing to more accurate medical diagnosis.
[0021] The smooth image is divided into multiple local regions, and the geometric and statistical properties of each region are recorded. The division of multiple local regions includes: using a superpixel segmentation algorithm to cluster the smooth image to generate an initial region division; setting the number of regions based on the initial region division and determining the distribution of cluster centers according to the image size; assigning pixels to their respective cluster centers and calculating the centroid coordinates and average predicted value of each region; updating the cluster centers of each region and redistributing pixels, repeating the iteration until the region boundaries are stable.
[0022] By employing a superpixel segmentation algorithm to cluster smooth images and dynamically setting the cluster center distribution based on image size, and iteratively updating the region boundaries, uniform region division can be achieved while preserving local image details. The local region boundaries generated in this process are aligned with the image structure, and the recorded centroid coordinates, average predicted values, and other attributes provide a spatial and semantic consistency basis for subsequent construction of relationships between regions, thereby improving the geometric rationality and contextual consistency of the generated credibility map.
[0023] A graph structure is constructed using the regions as nodes, and valid connection edges are selected based on the adjacency relationships between regions. Specifically, this includes: establishing an undirected graph, with each local region as a node in the graph; based on the region corresponding to the node, detecting whether there is an intersection between the pixel boundaries of any two regions, and generating candidate connection edges if they do; for each pair of regions corresponding to a candidate connection edge, calculating the difference between their average predicted values and the distance between their centroids; and using the difference and distance as input, calculating the connection weight of each candidate connection edge through an exponential decay function.
[0024] By using local regions as nodes, establishing candidate connection edges based on pixel boundary intersections, and calculating connection weights by combining the difference in predicted values between regions and the centroid distance, a graph structure reflecting spatial adjacency and semantic similarity can be constructed. This approach effectively preserves the topological connection characteristics between regions, eliminates redundant associations between non-adjacent regions, and enables subsequent credibility assessments to be conducted on the basis of logically coherent regional relationships, thereby enhancing the structural constraints and the rationality of the results in the global state evolution process.
[0025] The comprehensive similarity between region pairs is calculated to determine the connection weights. Based on the connection weights and the statistical attributes of each region, the initial state variables of each node are set, specifically including: assigning a binary state to each node, where +1 represents trustworthy and -1 represents untrustworthy; comparing the standard deviation of the predicted values within each region with a preset threshold based on the binary state setting rules; for regions with a standard deviation less than the threshold, setting the initial state of the corresponding node to +1; and multiplying the average predicted value of the region by a scaling factor to obtain the extrinsic tendency term.
[0026] Using the standard deviation of predicted values within a region to determine the initial state of a node (+1 or -1) effectively distinguishes between reliable regions with high internal consistency and unreliable regions that may contain anomalies or uncertainties. A smaller standard deviation indicates that the predicted values within that region are more consistent and therefore more likely to be correct, while a larger standard deviation suggests potential problems. This method sets a basic binary state for each node and incorporates an external tendency term, providing a basis for subsequent possible state updates or adjustments. This allows the system to dynamically reassess the reliability of each region based on new information, further improving decision-making quality.
[0027] Construct a global energy expression, which includes an inter-regional interaction energy term and an individual tendency energy term. The inter-regional interaction energy term is composed of the product of the connection weight and the state of the adjacent node, and the individual tendency energy term is composed of the product of the external tendency term and the node state. Furthermore, constructing the global energy expression includes: for each valid connection edge, calculating the product of its connection weight and the product of the states of the two connected nodes; summing the products corresponding to all connection edges and taking the negative value to obtain the inter-regional interaction energy term; based on the construction method of the inter-regional interaction energy term, calculating the product of the external tendency term and the node state for each node; summing the products corresponding to all nodes and taking the negative value to obtain the individual tendency energy term.
[0028] By constructing a global energy expression that includes inter-regional interaction energy terms and individual tendency energy terms, and modeling the relationship between connection weights and adjacent node states, as well as the relationship between external tendency terms and node states, we can simultaneously consider the structural consistency between regions and the predictive reliability of each region within a unified energy framework. This expression quantifies the stability of the overall configuration by summing and taking the negative, making the energy minimization process tend to generate results where the inter-regional states are coordinated and the individual states conform to the predictive characteristics. This provides a reasonable evaluation criterion for subsequent global optimization through simulated annealing, and improves the spatial coherence and logical rationality of the credibility graph.
[0029] The execution state evolution process starts from the initial state variable, adjusts the node state through simulated annealing mechanism, and records the node state configuration after the last state change as the system stable state. The execution of the state evolution process further includes: setting an initial temperature value and starting an iterative loop; at the current temperature, randomly selecting a node and calculating the energy change caused by its state flip based on the connection weight and the states of adjacent nodes; if the energy change is less than zero, accepting the node's state flip; if the energy change is greater than zero, generating a random number and comparing the random number with the exponential decay probability calculated based on the energy change and the current temperature, and deciding whether to accept the state flip based on the comparison result.
[0030] It also includes: after completing a round of state checks on all nodes, multiplying the current temperature by a cooling coefficient to obtain the updated temperature; continuing the next round of state adjustment based on the updated temperature, and repeating the temperature update and state adjustment process; stopping iteration when the temperature drops to a preset lower limit value, and retaining the configuration after the last state adjustment.
[0031] By starting with the initial state variables and executing a state evolution process based on simulated annealing, the credible states of each node can be gradually optimized under the guidance of the global energy expression. This process dynamically adjusts the acceptance probability of state flips by controlling the temperature, allowing the crossing of local energy barriers at high temperatures and the stabilization at low temperatures, effectively avoiding getting trapped in local optima. By combining connection weights and neighboring states to calculate energy changes, and deciding whether to accept state flips based on the exponential relationship between energy changes and temperature, the system maintains consistency between regions while taking into account individual tendencies. Through periodic cooling and multiple rounds of state adjustments, it finally converges to a stable configuration with lower energy, improving the overall logic and structural rationality of the credibility graph, and ensuring that the output results are more stable and reliable in terms of spatial distribution and semantic judgment.
[0032] The system's stable state is mapped back to the image space to generate a confidence map, and low-confidence regions are labeled. The labeling is based on the system's stable state and dynamic threshold segmentation.
[0033] Generating a confidence map involves: converting the system's stable state in each region into a continuous value between 0 and 1; assigning the continuous value to all pixel positions within the region; performing bilinear interpolation on the pixel-level confidence map; calculating the confidence mean and standard deviation of the entire map, and using the mean minus a multiple of the standard deviation as a dynamic threshold.
[0034] The system's steady state is mapped back to the image space to generate a confidence map, and bilinear interpolation is used to achieve continuous pixel-level output. This preserves the geometric structure of region segmentation while eliminating block effects, resulting in a smoother confidence distribution that conforms to visual perception. The threshold is dynamically determined based on the mean and standard deviation of the confidence level of the entire image, adaptively identifying low-confidence regions and avoiding the problem of poor adaptability of fixed thresholds in different cases. This approach aligns the annotation results with the overall confidence level of the image, improving the robustness and consistency of low-confidence region detection. It ensures that the output confidence map has good discriminative ability and clinical interpretability under different imaging conditions and lesion features.
[0035] On the other hand, this invention proposes a medical image region confidence map generation system based on the Ising model, such as... Figure 2 As shown, it includes: The image processing module is used to receive the predicted output of medical images and perform smoothing processing; The region segmentation module is used to segment local regions based on a smooth image and record their attributes. The graph construction module is used to construct the graph structure between regions and calculate the connection weights. The energy optimization module is used to construct the global energy expression and perform state evolution; The results generation module is used to map the system's stable state into a confidence map and mark low-confidence regions. The feedback interface module is used to output credibility graphs and quality reports, and supports result evaluation in multi-task scenarios.
[0036] In addition, the modules mentioned above are also used to implement other steps of the above-described method for generating a medical image region confidence map based on the Ising model, as follows: Step 1: Obtain the initial prediction image and extract spatial structure features The goal of this stage is to obtain preliminary results from any medical image processing workflow and, based on these, identify local units with semantic or structural significance in the image, preparing for subsequent graph structure construction. This process does not impose restrictions on the original prediction method, only requiring that its output be a two-dimensional or three-dimensional spatial mapping result, such as a segmentation label map, a reconstructed density map, or a confidence intensity map. By dividing the image into several sub-regions with similar properties, the computational complexity of subsequent steps can be reduced, while preserving important structural information such as boundaries and textures.
[0037] Receive prediction output from the upstream image processing flow: Receive the prediction result of a medical image from an external flow. ,in and These represent the height and width of the image, respectively. This image may be a probability map of organ segmentation, an intensity enhancement map of a lesion region, or a reconstructed structural representation. This image serves as the starting point for this scheme and does not involve intervention or modification of its generation method. Its pixel values reflect the original process's judgment tendency for each location; for example, a probability value in the range [0,1] indicates the likelihood of the presence of a certain type of tissue.
[0038] This step decouples the solution from the upstream system, making it widely adaptable to different imaging tasks and data sources. Regardless of how the original workflow generates the results, subsequent analysis can be initiated simply by providing a spatial distribution map. This design enhances applicability, avoids the need to refactor existing systems, and facilitates rapid integration in real-world environments.
[0039] To reduce noise interference, the predicted image is smoothed: To suppress potential local jitter or isolated outliers in the predicted image, an unsharpening masking method is used. The image is smoothed by filtering. The specific steps are as follows: , formula 1; in The standard deviation is Gaussian kernel, This represents the convolution operation. Controlling the enhancement intensity. This operation preserves the main structure while reducing high-frequency noise, making it particularly suitable for outputs with random fluctuations generated by deep networks.
[0040] Unprocessed prediction graphs may contain locally unstable regions due to insufficient training samples or randomness in the inference process. By introducing Equation 1, the consistency within regions can be improved without obscuring the overall outline. This is particularly important for subsequent region segmentation, as overly fragmented regions can lead to an overly complex graph structure, affecting the efficiency of subsequent optimization.
[0041] Based on smoothing the image, the image is divided into multiple local regions: Superpixel segmentation algorithms (such as SLIC) are used to segment the image. Divided into Local area Each region contains a set of spatially adjacent pixels with similar properties. The number of superpixels... The settings can be adjusted based on image resolution and task requirements, typically ranging from several hundred to several thousand. Each region... With center coordinates Average forecast value .
[0042] Modeling directly on a pixel-by-pixel basis incurs a huge computational burden, and the subtle differences between adjacent pixels make it difficult to reflect structural hierarchy. By clustering to form superpixels, spatial dimensionality reduction is achieved while maintaining boundary alignment. Each region participates in subsequent analysis as an independent unit, reflecting local trends while avoiding the influence of fine-grained perturbations.
[0043] Record the geometric and statistical properties of each region for subsequent association analysis: for each region Create a list of attributes, including: area Location of the center of mass Average forecast value Standard deviation of predicted values and boundary length These attributes will be used in subsequent steps to measure the similarity, connectivity strength, and stability tendency between regions. In particular... This will serve as a preliminary basis for judging whether the area is reliable.
[0044] The statistical characteristics of a region reflect its internal consistency. If a region... A large value indicates significant fluctuations in its internal predicted values, potentially suggesting issues such as ambiguous boundaries or classification uncertainty; while A value close to 0 or 1 suggests a higher level of confidence. While this information alone cannot determine credibility, it provides a foundational input for establishing global relationships later.
[0045] Step 2: Construct the inter-region graph structure and define node state variables After image segmentation, the regions need to be organized into a graph structure to represent their spatial and attribute relationships. Nodes in the graph correspond to each region, and edges represent the adjacency or similarity between regions. Based on this, each node is assigned a binary state variable to indicate whether the region is "credible" in the final result. This state will be dynamically adjusted in subsequent optimizations, determined by the states of surrounding regions and its own performance.
[0046] The basic framework for building an undirected graph using regions as nodes: Constructing an undirected graph , where the node set Corresponding to the previous step each region Each node Representative area and carries its attributes The initial form of the graph contains only nodes, and no connections have been established.
[0047] Graph structures offer a flexible way to represent complex spatial dependencies. Unlike regular grids, graphs allow for non-uniform connectivity, more naturally reflecting the irregular shapes and large size variations of organs in medical images. Each node, as the basic unit of analysis, carries comprehensive information about the region, laying the foundation for subsequent state evolution.
[0048] Determine the set of candidate connection edges based on spatial adjacency: for any two nodes and If its corresponding area and If the boundary is shared spatially, then a potential edge is added to the graph. The determination of shared boundaries can be achieved by checking whether the intersection of the pixel sets of the two regions is non-empty. All edges that meet the conditions constitute a candidate edge set. Its size is usually much smaller than that of a complete graph. This effectively controlled the amount of subsequent computation.
[0049] Calculate the comprehensive similarity between pairs of regions to filter valid connections: for each candidate edge Calculate its connection weights , indicating region and The degree of similarity in predicted performance. Defined as follows: , formula 2; in To adjust the parameters, This represents the diagonal length of the image. This formula comprehensively considers both predicted value differences and spatial distance: the closer the values and the closer the distance, the higher the similarity. Spatial adjacency alone is insufficient to determine whether strong coupling is necessary between regions. Two adjacent regions with vastly different predicted values (such as the boundary between tumor and normal tissue) may be in a boundary transition zone, and their states should be allowed to differ. Formula 2, through a weighted attenuation mechanism, strengthens the connection between highly similar and adjacent regions, thus making them more inclined to maintain a consistent state in subsequent optimizations.
[0050] Set initial state variables for each node and introduce extrinsic tendencies: for each node Assign a state variable Where +1 represents "trustworthy" and -1 represents "untrustworthy". The initial state is set based on the stability within the region: , formula 3; in A preset threshold is used to distinguish between low-volatility and high-volatility regions. Simultaneously, an external tendency term is defined. This reflects the driving effect of the average prediction intensity on the credibility state of the region. This is the scaling factor.
[0051] Initial assignment based on internal region consistency is a reasonable starting point. External tendency term. It captures the "confidence" signal of the original prediction: regions with high predicted values are more likely to be considered credible. These two factors together form the basic input for the subsequent energy function.
[0052] Step 3: Construct the global energy expression and analyze its constituent elements. After establishing the graph structure and node states, a global energy function needs to be defined to quantify the overall "instability" of all current node state combinations. This energy consists of two parts: first, the conflict cost between regions due to state differences; and second, the degree of deviation between each region's own state and external tendencies. The lower the energy, the more coordinated and reliable the current state configuration.
[0053] Define an inter-region interaction energy term to reflect structural consistency pressure: for each edge If the states of the two nodes are different (i.e. This incurs a certain energy cost, representing structural inconsistency. This cost is related to the connection weights. This is directly proportional; that is, the stronger the connection, the greater the penalty for state inconsistency. The total interaction energy is: , formula 4; in This is the coupling strength coefficient. When... hour, If this value is negative, it decreases the total energy; conversely, if it is positive, it increases the energy.
[0054] Formula 4 embodies the principle of "like attracts like": connected regions with consistent states are more stable. This simulates the natural law of tissue continuity in medical images—the same organ should have a consistent level of reliability. State conflicts on strongly connected edges will significantly increase energy, prompting the optimization process to tend towards uniformity.
[0055] Define an individual propensity energy term to reflect the influence of local prediction strength: for each node It tends to favor a certain state due to its predictive performance. If its average predicted value is high and its fluctuation is small, it should be considered more "reliable". This tendency is reflected in the external field terms. The corresponding energy is: , formula 5; when and When the signs are the same, the term is negative, which helps to reduce the total energy; when the signs are opposite, it increases the energy. Therefore, high... The region tends to remain Formula 5 incorporates the quality information of the original predictions into the global optimization. Even if the surrounding states of a certain region are mostly "unreliable," it may still maintain a "reliable" state as long as its own predictions are very stable and have high values. This prevents misjudgments caused by over-smoothing and preserves high-quality local information.
[0056] Combining the interaction and tendency terms to form a complete energy expression: Adding the above two terms yields the total energy function of the system: , Formula 6; This function depends on the state combination of all nodes. The goal is to find the state configuration that makes... The minimum set of solutions. Equation 6 constitutes the objective of the entire optimization process. It balances the relationship between "structural consistency" and "individual performance": encouraging consistency in states between adjacent regions while respecting the prediction quality of each region itself. Minimizing this energy is equivalent to finding the most coordinated and stable reliable state distribution.
[0057] Analyzing the direction of minimization of the energy function to guide subsequent state evolution: Observing Equation 6, it can be seen that changing any node... status This will cause an energy change: , Formula 7; like Then Changing from +1 to -1 reduces energy; conversely, it should be maintained or changed to +1. This difference provides direction for state updates. Equation 7 reveals the impact of each node's state adjustment on overall stability. It combines the weighted sum of neighbor states with its own tendency to form a local decision-making basis. This expression provides a mathematical foundation for subsequent iterative optimization, allowing for gradual approximation of the optimal solution without traversing all combinations.
[0058] Step 4: Perform a state evolution process to approximate the lowest energy state. After the energy function is defined, the states of each node need to be adjusted through a dynamic process so that the system gradually approaches the stable configuration with the lowest energy. This process simulates the behavior of particles in a physical system searching for the ground state under thermal perturbation, allowing for brief state transitions with increased energy to escape local minima.
[0059] Set initial temperature parameters and start the state iteration process: introduce a temperature variable that decreases over time. The initial value is set to The high-temperature phase allows for larger state fluctuations, facilitating the exploration of various configurations; with... As the system declines, it gradually "freezes" to a stable state. State updates are performed by traversing all nodes in a random order.
[0060] Temperature parameters control the probability of adverse fluctuations. Initially high... This enables the system to overcome energy barriers and avoid falling into suboptimal solutions; low energy consumption in the later stages This enhances convergence. This gradual cooling process mimics the natural annealing process and helps to find a globally optimal state distribution.
[0061] Calculate the energy difference for state transitions for each node: for the current node The energy change required for its flipping state is calculated according to Formula 7. .like This indicates that flipping is beneficial and should be done; if If so, it is necessary to further determine whether to accept the adverse change.
[0062] This step reuses the result of Formula 7 as the basis for decision-making in each update. It combines the local environment (neighbor states) with individual tendencies (…). This ensures that every adjustment is supported by a rationale, rather than being a random disturbance.
[0063] The decision to accept an unfavorable change of state is based on a probability criterion: when... At that time, with probability Accept the change. The probability follows... Increase and decrease, with It decreases and decays rapidly. This can be achieved by generating random numbers. Implementation: If If so, then the flip will be performed.
[0064] , formula 8; Formula 8 is the core rule of simulated annealing. It allows the system to accept a certain degree of "chaos" early on, thus escaping local traps. For example, a high-quality region surrounded by "untrusted" regions may be temporarily forced to flip, but can eventually return to the correct state as the surroundings adjust.
[0065] After completing one round of traversal, reduce the temperature and repeat until convergence: After completing one round of checks on all nodes, update the temperature according to the cooling plan. , formula 9; Commonly used Repeat the above process until... Below the preset threshold The process continues until there are no further state changes for several consecutive rounds. Equation 9 ensures that the temperature decreases monotonically, gradually stabilizing the system. Each iteration is performed in a more "calm" state, ultimately reaching a low-energy, highly consistent state configuration. This process does not require absolute optimality, but it usually yields high-quality approximate solutions.
[0066] Step 5: Map the final state back to the image space to generate a confidence map. After the state evolution is complete, each region They all achieved a stable The next step is to convert it into a continuous credibility score and map it back into the original image space to form a credibility graph that can be viewed or used further.
[0067] Converting binary states into continuous credibility scores: To facilitate visualization and fusion, discrete states are... Mapping to an interval Continuous values within : , formula 10; Right now (Completely credible) (Unreliable). Formula 10 realizes the conversion from physical state to practical score. Continuous values are more suitable for display as heatmaps, and can also be used to weight the original prediction results to generate a "reliable region enhanced" version of the image.
[0068] Assign a region confidence value to all pixels it contains: Create a new image. For each pixel ,make In this way, each superpixel has the same confidence value, forming a blocky distribution. This operation completes the transition from region-level judgment to pixel-level output. Although there is a step at the superpixel boundaries, the overall structure is maintained in a consistent manner, and the computation is efficient.
[0069] To eliminate blockiness, the credibility map is interpolated: to improve visual quality, bilinear interpolation is used to smooth C, generating the final credibility heatmap. The interpolation process at each pixel location is based on the values of its four nearest superpixels. Value-weighted calculation. While block diagrams can reflect the general distribution, they are not conducive to detailed observation. Interpolation can make the transition more natural without destroying the overall trend, making it easier for doctors to intuitively identify "suspicious edges" or "low confidence areas".
[0070] Output a confidence level graph and mark low-confidence areas for manual review: A fused view is generated by overlaying pseudo-color onto the original image or prediction result. A threshold can also be set. ,Will Areas marked as "requiring manual confirmation" generate alert boxes or flashing prompts. The final output is not just a numerical graph, but also a tool to support decision-making. Automatic labeling of low-confidence areas can guide doctors to focus on potential errors, improve review efficiency, and reduce the risk of omissions.
[0071] Step Six: Deploy the system and support result evaluation in multi-task scenarios After generating the credibility graph, this solution enters the practical application phase. This phase focuses not only on the visualization of the results but also on its integration capabilities within real-world medical information systems, its dynamic response mechanisms, and its cross-task generalization performance. The system needs to support multiple deployment models, including embedded edge devices, cloud inference services, and local workstations, and be able to automatically adjust computing resource allocation based on the operating environment. Furthermore, it must provide interfaces for upper-layer applications to access the credibility graph data, enabling seamless integration with electronic medical record systems, image reading platforms, or automated diagnostic pipelines.
[0072] Constructing a credibility-weighted fusion image to enhance visual interpretation guidance: To improve the usability of the original prediction results, the final credibility map is... Compared with the initial predicted image Perform weighted fusion to generate visually enhanced output. This process employs a transparency blending mode, preserving the original intensity of high-confidence areas on the display while weakening the visual weight of low-confidence areas. , Formula 11; in The fusion coefficient controls the degree to which credibility affects the display. A background image (such as the original anatomical image or a grayscale background) is used to maintain the context of the anatomical structure. When the value approaches 0, the position tends to display the background, indicating to the user that the prediction is unstable at this location.
[0073] Formula 11 implements a visual guidance mechanism that "highlights credible areas and blurs suspicious areas." When doctors browse images, they naturally focus on areas with bright colors or preserved intensity, while blurred or transparent parts raise their alertness. This non-invasive annotation avoids forcibly modifying the original results while effectively conveying information about uncertainty.
[0074] A dynamic threshold segmentation mechanism is designed to identify areas requiring manual intervention: To further support decision-making, the system needs to automatically identify areas with a confidence level below a certain threshold and mark them as "suggested for review." Unlike a fixed threshold, this scheme adopts an adaptive segmentation strategy based on image statistical characteristics. Let the average confidence level of the entire image be... The standard deviation is The threshold for judgment is defined as follows: , Formula 12; in This is a sensitivity parameter that can be adjusted according to the task type. For example, in a screening task, it can be set... To retain more potential outlier areas; to set up more precise quantitative tasks Only highly uncertain regions are marked. Formula 12 avoids the problem of inconsistent performance of a globally fixed threshold across different cases. For images with high overall prediction quality, High, Moving the image upwards reduces false alarms; however, for images with large overall fluctuations, Automatic shifting ensures that no critical problem areas are missed. This dynamic response enhances the system's robustness and adaptability.
[0075] Extracting spatial features of low-confidence regions to generate structured quality reports: The system not only outputs graphical prompts but also generates structured data that can be archived and analyzed. For each connected region marked as low-confidence... (Right now (a collection of pixels), extract the following attributes: Area percentage: ; Centroid coordinates: ; Maximum circumcircle radius: ; Shape compactness: This reflects whether the area is concentrated or diffuse; all The quality events and their attributes constitute a list of quality events. The data can be serialized into JSON format and written to a log. These geometric features can be used for subsequent analysis. For example, multiple small, scattered low-confidence areas may indicate high overall image noise; a single large, irregularly shaped region may suggest blurred organ boundaries or strong lesion heterogeneity. Structured reports facilitate long-term tracking of system performance changes.
[0076] Establish a credibility feedback channel to support iterative model optimization: the generated credibility graph serves not only as the terminal output but also as a feedback signal for the upstream process. The system periodically... The list, along with the corresponding original images and prediction results, are packaged and uploaded to the training server to identify samples where the model performs poorly. If a certain type of case repeatedly appears in low-confidence reports, an active learning mechanism can be triggered to prioritize adding it to the retraining set.
[0077] Specifically, a sample importance score is defined: , Formula 13; in As weight, and Positive correlation, emphasizing widespread uncertainty. High Value samples are considered "high-value feedback," and manual review and label correction are recommended. Formula 13 integrates the breadth (area) and location (implied in) of uncertainty. ) and morphological complexity ( Diffuse and irregular low-confidence regions are more likely to reflect model comprehension deficiencies than random noise. Selective feedback can effectively improve model performance in critical scenarios.
[0078] Achieving multimodal credibility map fusion to address complex diagnostic tasks: In joint analysis involving multiple imaging modalities (such as PET / CT, MRI / DWI), the system can generate credibility maps for each modality separately. Then, cross-modal fusion is performed. The fusion strategy is as follows: , Formula 14; in For the first The confidence weights of modalities can be preset based on image signal-to-noise ratio or task relevance. For example, in tumor metabolic assessment, PET... It can be higher than CT. Equation 14 realizes the weighted integration of multi-source reliable information. If the reliability of one modality is low in a certain region (such as lung apex artifacts in CT), but the reliability of another modality is high (such as no abnormal uptake in PET), the fusion result can still maintain a high confidence level. This enhances the robustness of composite judgment.
[0079] A lightweight inference engine was developed to adapt to resource-constrained devices: To support operation on mobile terminals or embedded devices, the system provides a simplified inference path. This path employs a pre-computation graph structure and a lookup table method to accelerate energy optimization. Specifically, in the offline phase, state evolution is pre-executed using a large number of typical image samples to record the optimal state under common region configurations. Mapping relationships, constructing lookup tables .
[0080] During online inference, the regional features of the new image (such as...) Encode: Formula 15; then The system searches for the closest pattern and directly outputs the corresponding state, skipping the iteration process. Formula 15 abstracts the region into a low-dimensional feature vector, facilitating rapid matching. The lookup table method compresses the optimization process, which originally required hundreds of iterations, into a single retrieval, significantly reducing latency and power consumption, making it suitable for real-time or portable applications.
[0081] This embodiment fully demonstrates the entire process from the original predicted image to the generation of a confidence map. By constructing a region map, defining an energy function, and performing state evolution, a confidence distribution map reflecting structural consistency is finally output. This scheme is applicable to various medical imaging tasks and has good scalability and practicality.
[0082] Finally, it should be noted that the above description is only a preferred embodiment of the present invention and is not intended to limit the present invention. Although the present invention has been described in detail with reference to the foregoing embodiments, those skilled in the art can still modify the technical solutions described in the foregoing embodiments or make equivalent substitutions for some of the technical features. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of the present invention should be included within the protection scope of the present invention.
Claims
1. A method for generating a confidence map of a medical image region based on the Ising model, characterized in that, Includes the following steps: The predicted output of the medical image is obtained, and the predicted output is smoothed to obtain a smoothed image. Based on the smoothed image, multiple local regions are divided, and the geometric and statistical properties of each region are recorded. A graph structure is constructed using the regions as nodes. Valid connection edges are filtered according to the adjacency relationship between regions. The comprehensive similarity between region pairs is calculated to determine the connection weight. The initial state variables of each node are set based on the connection weight and the statistical attributes of each region. Construct a global energy expression, which includes an inter-regional interaction energy term and an individual tendency energy term. The inter-regional interaction energy term is composed of the product of the connection weight and the state of the adjacent node, and the individual tendency energy term is composed of the product of the external tendency term and the node state. The execution state evolution process starts from the initial state variable, adjusts the node state through simulated annealing mechanism, and records the node state configuration after the last state change as the system stable state. The system's stable state is mapped back to the image space to generate a confidence map, and low-confidence regions are labeled. The labeling is based on the system's stable state and dynamic threshold segmentation.
2. The method for generating a medical image region confidence map based on the Ising model according to claim 1, characterized in that, The smoothing process includes: The predicted output is filtered using an unsharpened mask operation to obtain the enhanced image; The image is convolved using a Gaussian kernel, and the standard deviation of the kernel is set according to the image resolution. The difference between the original image and the blurred image is multiplied by the enhancement intensity parameter to form a compensation term; The compensation term is added back to the original image to generate a smooth image.
3. The method for generating a medical image region confidence map based on the Ising model according to claim 1, characterized in that, The division of multiple local regions includes: A superpixel segmentation algorithm is used to cluster the smooth image to generate initial region divisions; The number of regions is set based on the initial region division, and the distribution of cluster centers is determined according to the image size; Pixels are assigned a cluster center, and the centroid coordinates and average predicted value of each region are calculated. Update the cluster centers of each region and reallocate pixels, repeating the iteration until the region boundaries are stable.
4. The method for generating a medical image region confidence map based on the Ising model according to claim 1, characterized in that, The construction graph structure includes: Construct an undirected graph, treating each local region as a node in the graph; Based on the region corresponding to the node, detect whether there is an intersection between the pixel boundaries of any two regions. If there is, generate candidate connection edges. For each candidate connection edge corresponding to a region pair, calculate the difference between their average predicted values and the distance between their centroids; Using the difference and distance as input, the connection weight of each candidate connection edge is calculated through an exponential decay function.
5. The method for generating a medical image region confidence map based on the Ising model according to claim 1, characterized in that, The initial state variables set for each node include: Assign a binary state to each node, where +1 represents trustworthy and -1 represents untrustworthy; Based on the binary state setting rules, the standard deviation of the predicted values within each region is compared with a preset threshold. For regions where the standard deviation is less than the threshold, the initial state of the corresponding node is set to +1; The external tendency term is obtained by multiplying the average predicted value of the region by the scaling factor.
6. The method for generating a medical image region confidence map based on the Ising model according to claim 1, characterized in that, The construction of the global energy expression includes: For each valid connection edge, calculate the product of its connection weight and the product of the states of the two connected nodes; Summing the products of all connected edges and taking the negative value yields the inter-regional interaction energy term; Based on the construction method of the inter-regional interaction energy term, the product of the external tendency term and the node state is calculated for each node; Summing the products corresponding to all nodes and taking the negative value yields the individual tendency energy term.
7. The method for generating a medical image region confidence map based on the Ising model according to claim 1, characterized in that, The execution state evolution process includes: Set the initial temperature value and start the iterative loop; At the current temperature, randomly select a node and calculate the energy change caused by its state reversal based on the connection weight and the states of its neighboring nodes; If the energy change is less than zero, then the state of the receiving node is flipped. If the energy change is greater than zero, a random number is generated and compared with the exponential decay probability calculated based on the energy change and the current temperature. The result of the comparison determines whether to accept the state flip.
8. The method for generating a medical image region confidence map based on the Ising model according to claim 7, characterized in that, The execution state evolution process also includes: After completing a round of status checks on all nodes, the current temperature is multiplied by the cooling coefficient to obtain the updated temperature; The next round of state adjustment will continue based on the updated temperature, and the temperature update and state adjustment process will be repeated. The iteration stops when the temperature drops to the preset lower limit, and the configuration after the last state adjustment is retained.
9. The method for generating a medical image region confidence map based on the Ising model according to claim 1, characterized in that, The generation of the credibility map includes: The system steady state of each region is converted into a continuous value between 0 and 1; Assign continuous values to all pixel positions within the region; Perform bilinear interpolation on the pixel-level confidence map; Calculate the mean and standard deviation of the confidence level for the entire image, and use the mean minus a multiple of the standard deviation as the dynamic threshold.
10. A medical image region confidence map generation system based on the Ising model for implementing the method as described in any one of claims 1-9, characterized in that, include: The image processing module is used to receive the predicted output of medical images and perform smoothing processing; The region segmentation module is used to segment local regions based on a smooth image and record their attributes. The graph construction module is used to construct the graph structure between regions and calculate the connection weights. The energy optimization module is used to construct the global energy expression and perform state evolution; The results generation module is used to map the system's stable state into a confidence map and mark low-confidence regions. The feedback interface module is used to output credibility graphs and quality reports, and supports result evaluation in multi-task scenarios.
