Method and electronic device for object segmentation of computed tomography images

By using the persistent homology algorithm and persistence graph in the segmentation process of computed tomography images, the topological error problem in the existing technology is solved, and the accuracy and structural correctness of the target segmentation are improved.

CN119273909BActive Publication Date: 2025-09-23BEIJING UNIV OF POSTS & TELECOMM
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202411137642.6
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-08-19
Publication Date
2025-09-23
Estimated Expiration
2044-08-19

AI Technical Summary

Technical Problem

In the prior art, there are topological errors in the segmentation method of computed tomography images, resulting in low target segmentation accuracy.

Method used

A persistent homology algorithm is used to process the true segmentation annotations and the training predicted segmentation annotations. The loss function and indicators are determined through the persistence graph. The initial model is trained to focus on the accuracy of the topological structure. The persistence graph is used to describe the topological structure of the target segmentation annotation to avoid topological errors.

Benefits of technology

The object segmentation accuracy of computed tomography images is improved, the overall structural correctness of the segmentation results is ensured, and topological errors are avoided.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119273909B_ABST
    Figure CN119273909B_ABST
Patent Text Reader

Abstract

The present application provides a method and electronic device for target segmentation of a computed tomography image. In the process of training an initial model, a loss function is determined based on a persistence graph obtained by processing a persistent homology algorithm to train the initial model, and an indicator that also uses a persistence graph to describe the topological structure of the target segmentation annotation is combined to obtain a segmentation model that can focus on the accuracy of the topological structure. In the prediction process, the obtained tomography image to be predicted is input into such a segmentation model, and then the segmentation model is used to perform segmentation prediction on at least one target in the tomography image to be predicted. This can ensure the correctness of the overall structure of the obtained scanned image with predicted segmentation annotations, thereby avoiding the occurrence of topological errors and improving the accuracy of target segmentation.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of image processing technology, and in particular to a method for object segmentation of a computed tomography image and an electronic device. Background Art

[0002] Tomography images are an important part of medical imaging and can be used to assist medical diagnosis.

[0003] However, in the prior art, there are cases where topological errors occur in the segmentation method of tomographic scan images, resulting in low target segmentation accuracy. Summary of the Invention

[0004] In view of this, the purpose of this application is to provide a method for object segmentation of a computed tomography image and an electronic device to solve the above technical problems.

[0005] Based on the above objectives, the first aspect of the present application provides a method for object segmentation in a computed tomography image, comprising:

[0006] Obtain training image samples with real segmentation annotations and build an initial model;

[0007] Inputting training image samples with real segmentation labels into the initial model, and outputting image samples with training predicted segmentation labels through the initial model;

[0008] Based on the training image samples with real segmentation labels and the image samples with training predicted segmentation labels, the persistent homology algorithm is used to process them to obtain a persistence map;

[0009] determining a loss function based on the persistence map, the true segmentation annotations, and the training predicted segmentation annotations;

[0010] Training and adjusting the initial model according to a minimization result obtained in the process of minimizing the loss function to obtain a trained and adjusted initial model, and determining an indicator corresponding to a target in the training image samples based on the training image samples with true segmentation annotations and the image samples with training predicted segmentation annotations;

[0011] In response to the indicator being less than a preset indicator threshold, continuously adjusting the trained and adjusted initial model; or,

[0012] In response to the indicator being greater than or equal to a preset indicator threshold, using the trained and adjusted initial model as a segmentation model;

[0013] acquiring a tomographic image to be predicted;

[0014] The tomographic image to be predicted is input into the segmentation model, and segmentation prediction is performed on at least one target in the tomographic image to be predicted by the segmentation model to obtain a scanned image with predicted segmentation annotations.

[0015] Based on the same inventive concept, the second aspect of this application provides an electronic device, comprising a memory, a processor, and a computer program stored on the memory and executable by the processor, wherein the processor implements the method described in the first aspect above when executing the computer program.

[0016] From the above description, it can be seen that the target segmentation method and electronic device for computed tomography images provided by the present application, in the process of training the initial model, determines the loss function based on the persistence graph obtained by processing the persistent homology algorithm to train the initial model, and combines the indicators that also use the persistence graph to describe the topological structure of the target segmentation annotation to obtain a segmentation model that can focus on the accuracy of the topological structure, so that in the prediction process, the obtained tomographic image to be predicted is input into such a segmentation model, and then the segmentation model is used to perform segmentation prediction on at least one target in the tomographic image to be predicted, which can ensure the correctness of the overall structure of the scanned image with the predicted segmentation annotation, thereby avoiding the occurrence of topological errors and improving the accuracy of target segmentation. BRIEF DESCRIPTION OF THE DRAWINGS

[0017] In order to more clearly illustrate the technical solutions in this application or related technologies, the following briefly introduces the drawings required for use in the embodiments or related technical descriptions. Obviously, the drawings described below are merely embodiments of this application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without any creative work.

[0018] Figure 1 Schematic diagram of the flow of the object segmentation method for computed tomography images according to an embodiment of the present application;

[0019] Figure 2A A schematic diagram of the process of preparing a data set according to an embodiment of the present application;

[0020] Figure 2B A schematic diagram of the training process of the model according to an embodiment of the present application;

[0021] Figure 2C Schematic diagram of the process of determining the loss function of an embodiment of the present application;

[0022] Figure 2D A schematic diagram of a process for determining an indicator according to an embodiment of the present application;

[0023] Figure 3This is a structural block diagram of a device for segmenting an object in a computed tomography image according to an embodiment of the present application;

[0024] Figure 4 A schematic diagram of an electronic device according to an embodiment of the present application. DETAILED DESCRIPTION

[0025] In order to make the objectives, technical solutions and advantages of this application more clear, this application is further described in detail below in combination with specific embodiments and with reference to the accompanying drawings.

[0026] It should be noted that, unless otherwise defined, the technical terms or scientific terms used in the embodiments of the present application should have the usual meanings understood by people with ordinary skills in the field to which this application belongs. The "first", "second" and similar words used in the embodiments of the present application do not indicate any order, quantity or importance, but are only used to distinguish different components. "Include" or "comprise" and similar words mean that the elements or objects appearing before the word cover the elements or objects listed after the word and their equivalents, without excluding other elements or objects. "Connect" or "connected" and similar words are not limited to physical or mechanical connections, but may include electrical connections, whether direct or indirect. "Up", "down", "left", "right" and the like are only used to indicate relative positional relationships. When the absolute position of the described object changes, the relative positional relationship may also change accordingly.

[0027] It is understandable that before using the technical solutions of each embodiment of this application, the type, scope of use, usage scenarios, etc. of the personal information involved will be informed to the user in an appropriate manner, and the user's authorization will be obtained.

[0028] For example, in response to receiving a user's active request, a prompt message is sent to the user to clearly inform the user that the operation requested will require the acquisition and use of the user's personal information. Thus, the user can independently choose whether to provide personal information to the electronic device, application, server, storage medium, or other software or hardware that performs the operation of the technical solution of this application based on the prompt message.

[0029] As an optional but non-limiting implementation, in response to a user's active request, the prompt information may be sent to the user in the form of a pop-up window, in which the prompt information may be presented in text form. Furthermore, the pop-up window may also contain a selection control for the user to select "agree" or "disagree" to provide personal information to the electronic device.

[0030] It is understandable that the above notification and user authorization process are merely illustrative and do not constitute a limitation on the implementation of this application. Other methods that comply with relevant laws and regulations may also be applied to the implementation of this application.

[0031] Computed tomography (CT) images are an important component of medical imaging and can be used to assist in medical diagnosis. Object segmentation in CT images is a critical task, involving the precise separation of different objects from the image. Deep learning models, particularly convolutional neural networks (CNNs), have made significant progress in this field. Compared to traditional object segmentation methods, deep learning models can automatically extract multi-level features from images and, compared to traditional image processing methods, maintain high accuracy even in complex backgrounds.

[0032] Deep learning model design involves model design, loss function design, and evaluation metric design. First, regarding model design, neural networks (U-Net) and its variants have demonstrated outstanding performance in multi-object segmentation in CT images. U-Net is a classic deep learning architecture widely used in medical image segmentation. It achieves precise segmentation through a symmetrical encoder-decoder structure and preserves high-resolution contextual information through skip connections.

[0033] On the other hand, the loss function is the learning objective of a deep learning model. It is a tool that measures the gap between the model's predicted results and the actual results, and is the core mechanism that guides model learning and optimization. Choosing an appropriate loss function has a significant impact on the model's training effect and final performance. Evaluation indicators provide a quantitative method to evaluate the performance of the model, which can ensure that the model meets specific business needs, such as clinical requirements for target segmentation accuracy. The goal of model training is to minimize the loss function and maximize the value of the evaluation indicator. Therefore, loss functions and evaluation indicators often appear in pairs. For example, based on the Dice similarity coefficient, the loss function is called Dice loss, and the evaluation indicator is called the Dice similarity coefficient.

[0034] While various variations of current deep learning models for multi-object segmentation in CT images have been proposed to improve segmentation accuracy, these models often fail to consider the topological structure of the segmented objects in their loss functions and evaluation metrics, leading to topological errors in the segmentation results. Specifically, while the model's segmentation metrics achieve relatively ideal values, the segmentation results exhibit an incorrect spatial structure.

[0035] Current loss functions and evaluation indicators can be divided into the following three categories: pixel-based, region-based, and edge-based. Pixel-based loss functions directly predict the difference between the image and the true label image at the pixel level, such as Cross-Entropy Loss and Mean Squared Error (MSE). Region-based loss functions emphasize the overall segmentation effect, focusing on the intersection of the segmentation results predicted by the model and the true value annotations, such as Intersection Over Union (IOU) and Dice Coefficient. Edge-based loss functions calculate the distance between edge point sets, focusing on the edge effect predicted by the model, such as Hausdorff Distance and Average Surface Distance (ASD).

[0036] The above loss functions and evaluation metrics can guide the model to effective convergence and achieve clinically acceptable segmentation results. However, their image processing often remains at the pixel level, lacking a holistic description of the segmentation target. In other words, they lack a topological description of the segmentation target, which can lead to topological errors in the segmentation results.

[0037] Topology studies the properties of geometric figures or spaces that remain unchanged under continuous transformations. Topology focuses not on the specific shape and size of geometric figures, but rather on their structural properties under continuous transformations. Leveraging topological information ensures that segmentation results maintain the integrity of these anatomical structures, avoiding unreasonable shapes and connection errors. For example, if the target is an organ, such as the small intestine, the inclusion of topological information allows the algorithm to more accurately identify and segment continuous and connected structures, improving the accuracy of the segmentation results.

[0038] Existing loss functions and evaluation metric models ignore topological information, resulting in segmentation results that lack coherence and incomplete target structures. For example, if the target is an organ and the organ is a blood vessel, the blood vessel may be segmented into discontinuous parts, or the organ's outline may be disjointed, which is unreasonable in practical applications.

[0039] This application aims to address the shortcomings of related technologies in not paying enough attention to target topology information. Considering the clinical need for target segmentation, related technologies can focus on the pixel-level differences between model predictions and ground truth annotations, but have difficulty identifying and correcting significant topological errors in model predictions, and lack attention to the correctness of the overall structure.

[0040] The advantage of this application lies in its integration with loss functions and evaluation metrics, emphasizing that the model focuses on the accuracy of topological structure during training. Persistent homology is a tool derived from topological data analysis, used to study the shape characteristics of data. It provides a multi-scale method for analyzing data shape by identifying and tracking the topological structure of data at different scales (such as connected components, holes, cavities, etc.).

[0041] An embodiment of the present application provides a method for target segmentation of a computed tomography image. In the process of training an initial model, a loss function is determined based on a persistence graph obtained by processing a persistent homology algorithm to train the initial model, and an indicator that also uses a persistence graph to describe the topological structure of the target segmentation annotation is combined to obtain a segmentation model that can focus on the accuracy of the topological structure. In the prediction process, the obtained tomography image to be predicted is input into such a segmentation model, and then the segmentation model is used to perform segmentation prediction on at least one target in the tomography image to be predicted. This can ensure the correctness of the overall structure of the scanned image with the predicted segmentation annotation, thereby avoiding the occurrence of topological errors and improving the accuracy of target segmentation.

[0042] like Figure 1 As shown, the method of this embodiment includes:

[0043] Step 101: obtain training image samples with real segmentation annotations and build an initial model.

[0044] In this step, a computed tomography (CT) image can be obtained by photographing with a computer tomography camera or scanning with an X-ray electronic computed tomography scanner, and then saved in DICOM (a medical image format that can be used for data exchange and can meet clinical needs) format. The CT image is annotated using medical image processing software to obtain a CT image with real segmentation annotations.

[0045] Then the tomographic images are preprocessed and the annotated DICOM files are converted into NII (medical image format) format CT images and annotations.

[0046] The CT image dataset was partitioned into a training set and a test set in a 4:1 ratio. Data augmentation was then performed on the constructed CT image dataset. The data augmentation methods used included image flipping, rotation, translation, cropping, brightness adjustment, and the addition of Gaussian noise, resulting in training image samples with true segmentation annotations.

[0047] In addition, the initial model of this application is a neural network (U-Net) model, which performs outstandingly in multi-target segmentation of CT images, achieves accurate segmentation through a symmetrical encoder-decoder structure, and retains high-resolution contextual information through jump connections.

[0048] Step 102: input the training image samples with real segmentation labels into the initial model, and output the image samples with training predicted segmentation labels through the initial model.

[0049] In this step, the CT image dataset was partitioned into a training set and a test set in a 4:1 ratio. Data augmentation was then performed using methods such as image flipping, rotation, translation, cropping, brightness adjustment, and Gaussian noise addition.

[0050] The data-augmented training set (i.e., training image samples with true segmentation annotations) is input into the U-Net model to obtain image samples with training predicted segmentation annotations.

[0051] Step 103 : Processing the training image samples with real segmentation labels and the image samples with training predicted segmentation labels by a persistent homology algorithm to obtain a persistence map.

[0052] In this step, the persistence graph is obtained using the true segmentation annotations and the training prediction segmentation annotations predicted by the model, thereby introducing topological information so that the model obtained by the loss function based on the persistence graph can more accurately identify and segment continuous and connected structures, thereby improving the accuracy of the segmentation results.

[0053] Persistent homology is a tool derived from topological data analysis that is used to study the shape characteristics of data. It provides a multi-scale way to analyze the shape of data by identifying and tracking the topological structure of data at different scales (such as connected components, holes, cavities, etc.).

[0054] Step 104: determining a loss function based on the persistence map, the true segmentation annotations, and the training predicted segmentation annotations.

[0055] In this step, the loss function determined using the persistence graph, the true segmentation annotations, and the training prediction segmentation annotations can identify and correct significant topological error areas in the model predictions, thereby increasing attention to the correctness of the overall structure.

[0056] Step 105: The initial model is trained and adjusted according to the minimization result obtained in the process of minimizing the loss function to obtain a trained and adjusted initial model, and the indicators corresponding to the targets in the training image samples are determined based on the training image samples with real segmentation annotations and the image samples with training predicted segmentation annotations.

[0057] In this step, the initial model is trained and adjusted based on the minimization result obtained in the process of minimizing the loss function. The gradient descent method is used in the training and adjustment process to update the network parameters of the initial model to obtain the trained and adjusted initial model.

[0058] In addition, it is also possible to determine whether a preset number of training iterations or a set number of times is reached or whether the loss function reaches a threshold. If so, a trained and adjusted initial model is obtained, otherwise the training iteration is continued.

[0059] We then used the test set to introduce a metric that also uses a persistence graph to describe the topological structure of the object segmentation annotations. This metric computes the persistence graph for the object annotations at different scales. This is because introducing multi-scale computation during model training can reduce training efficiency. This multi-scale perspective helps measure the topological correctness of the model's predicted annotations in various regions.

[0060] Among them, the target of this application is organs, including but not limited to blood vessels, small intestine, skeleton, joints, heart, liver, nose, throat, trachea, bronchi, and lungs.

[0061] Step 106: Determine whether the indicator is greater than or equal to a preset indicator threshold.

[0062] In this step, based on the comparison between the indicator and the preset indicator threshold, it can be quickly determined whether the trained and adjusted initial model meets the expected requirements.

[0063] Step 107: In response to the indicator being less than a preset indicator threshold, continuously adjust the trained and adjusted initial model. Or,

[0064] In this step, when the indicator is less than the preset indicator threshold, it means that the topological correctness of the predicted annotations in each area by the trained and adjusted initial model still does not meet the expected requirements. In this case, the trained and adjusted initial model is continuously adjusted until the expected requirements are met, thereby improving the accuracy of target segmentation.

[0065] Step 108: In response to the indicator being greater than or equal to a preset indicator threshold, the trained and adjusted initial model is used as a segmentation model.

[0066] In this step, when the indicator is greater than or equal to the preset indicator threshold, it means that the topological correctness of the prediction annotations in each area of ​​the initial model after training and adjustment has met the expected requirements. Using the trained and adjusted initial model as a segmentation model can improve the accuracy of target segmentation.

[0067] Step 109: Acquire the tomographic image to be predicted.

[0068] In this step, a computed tomography (CT) image may be obtained by photographing with a computerized tomography camera or scanning with an X-ray electronic computed tomography scanner to serve as the tomography image to be predicted.

[0069] Step 1010: Input the tomographic image to be predicted into the segmentation model, and perform segmentation prediction on at least one target in the tomographic image to be predicted by the segmentation model to obtain a scanned image with predicted segmentation annotations.

[0070] In this step, since the segmentation model can focus on the accuracy of the topological structure, the tomographic image to be predicted is input into such a segmentation model, and then the segmentation model is used to perform segmentation prediction on at least one target in the tomographic image to be predicted. This can ensure the correctness of the overall structure of the scanned image with predicted segmentation annotations, thereby avoiding the occurrence of topological errors and improving the accuracy of target segmentation.

[0071] Through the above scheme, in the process of training the initial model, the loss function is determined based on the persistence graph obtained by processing the persistent homology algorithm to train the initial model, and the index of the topological structure of the target segmentation annotation that also uses the persistence graph to describe the target segmentation annotation is combined to obtain a segmentation model that can focus on the accuracy of the topological structure. In the prediction process, the obtained tomographic image to be predicted is input into such a segmentation model, and then the segmentation model is used to perform segmentation prediction on at least one target in the tomographic image to be predicted, which can ensure the correctness of the overall structure of the scanned image with predicted segmentation annotations, thereby avoiding the occurrence of topological errors and improving the accuracy of target segmentation.

[0072] In some embodiments, the true segmentation annotation corresponds to multiple targets, and the training predicted segmentation annotation corresponds to multiple targets.

[0073] Step 103 includes:

[0074] Step A1: Based on the real segmentation labels corresponding to the multiple targets, the training image samples are respectively one-hot encoded to obtain multiple first encoded binary images, and based on the training predicted segmentation labels corresponding to the multiple targets, the image samples are respectively one-hot encoded to obtain multiple second encoded binary images.

[0075] In step A2, for any of the multiple targets, perform the following operations:

[0076] Step A21 : determining a first target binary image corresponding to the target from the plurality of first coded binary images, and determining a second target binary image corresponding to the target from the plurality of second coded binary images.

[0077] Step A22: Determine the intersection of the first target binary image and the second target binary image, and determine the union of the first target binary image and the second target binary image.

[0078] Step A23: Process the intersection using a convex hull algorithm to obtain a first edge point set, and process the union using a convex hull algorithm to obtain a second edge point set.

[0079] Step A24: determining a first persistence graph based on the first edge point set, and determining a second persistence graph based on the second edge point set, and using the first persistence graph and the second persistence graph as the persistence graph.

[0080] In the above scheme, during deep learning model training, both the predicted segmentation annotations for the current iteration and the true segmentation annotations are represented as tensors of size (B, H, W, Z). B is the batch size for model training. For medical image segmentation models, the batch size represents the number of images fed into the model at each iteration. H, W, and Z are the length, width, and number of slices of the CT image, respectively. Typically, H and W are 512, meaning each slice is a 512x512 image. For these two tensors, the value range for any element is [1, C]. C is the total number of objects to be segmented.

[0081] One-hot encoding is a common method for converting categorical data into numerical data. It separates the labels of different segmentation targets. First, it identifies all unique categories in the categorical variable and creates a binary vector of length N for each category, where N is the total number of categories. The index position corresponding to the category is set to 1, and all other positions are set to 0. For a tensor of size (B, H, W, Z), the total number of segmentation targets is C, and its one-hot encoding tensor size is (B, C, H, W, Z).

[0082] Then obtain the training prediction segmentation annotation and the true segmentation annotation corresponding to one of the targets c, that is, obtain two binary images. This step is to take c(c∈[1, C]) from the training prediction segmentation annotation and the true segmentation annotation of the size (B, C, H, W, Z) calculated in the previous step, and obtain two binary images, referred to as the first target binary image gt c and the second target binary map pred c The size is (B, H, W, Z), the pixel value of 1 represents the marked area of ​​the target, and the pixel value of 0 represents the marked area of ​​the non-target.

[0083] Recalculate gt c and pred c Intersection I c and the union U c All intersections can be calculated by element-wise multiplication. If two binary images are both 1 at a certain coordinate, the intersection is 1 at that coordinate; if either is 0, the intersection is 0 at that coordinate. The union can be calculated by element-wise addition. If two binary images are both 0 at a certain coordinate, the union is 0 at that coordinate; otherwise, the union is 1 at that coordinate. The resulting intersection and union are also two binary images of size (B, H, W, Z).

[0084] Intersection I c and the union U c Use the convex hull algorithm to extract two point sets, referred to as the first edge point set S i and the second edge point set S u .

[0085] Convex hull algorithms are a class of algorithms used to compute the smallest convex polygon for a set of points. A convex hull is the smallest convex polygon that contains the set of points. This means that all points within the polygon lie within its boundary or interior, and none are outside the polygon. The goal of using a convex hull algorithm is to provide a tightly bounding boundary for subsequent topological data analysis.

[0086] This step can also be replaced by gradient calculation. For a point set, use the central difference formula to calculate the gradient of the interior points, and use the forward difference and backward difference formulas to calculate the gradient of the boundary points. Points with a non-zero gradient in any dimension are retained as edge points for subsequent calculations.

[0087] Then, using the persistent homology theory, we analyze the first edge point set S i and the second edge point set S u The persistence graph is calculated to obtain a first persistence graph D1 and a second persistence graph D2.

[0088] In some embodiments, in step A24, determining a first persistence graph based on the first edge point set includes:

[0089] In step B1, for any of the multiple targets, perform the following operations:

[0090] Step B11: constructing a first simplicial complex according to the first edge point set using a preset scale parameter.

[0091] Step B12: determining a first homology group based on the first simplicial complex.

[0092] Step B13: Perform topological feature tracking processing on the first homology group to obtain the first persistence graph.

[0093] In the above scheme, for the first edge point set, the first persistence diagram is calculated in the following steps:

[0094] 1) Constructing the first simplicial complex: Starting from the data points, we gradually construct a series of nested simplicial complexes by selecting different scale parameters. The data points are connected using simple geometric objects (such as points, line segments, and triangles) to form a simplicial complex. These geometric objects are called simplices, and a simplicial complex is a collection of simplices.

[0095] 2) Compute the first homology group: At each scale, compute the corresponding homology group to identify the topological characteristics of the data at that scale. The 0-dimensional homology group H0 describes the number of connected components in space. The 1-dimensional homology group H1 describes 1-dimensional holes in space, i.e., rings or cycles. The 2-dimensional homology group H2 describes 2-dimensional holes in space, i.e., cavities.

[0096] 3) Compute the first persistence diagram: By tracking the birth and death of topological features at different scales, a persistence bar diagram or persistence diagram is generated. A persistence bar diagram uses the length of the bar to represent the persistence of the topological feature, while a persistence diagram uses the coordinates of the points (birth scale and death scale) to represent the persistence of the feature.

[0097] In some embodiments, in step A24, determining a second persistence graph based on the second edge point set includes:

[0098] In step C1, for any of the multiple targets, perform the following operations:

[0099] Step C11: constructing a second simplicial complex according to the second edge point set using a preset scale parameter.

[0100] Step C12: determining a second homology group based on the second simplicial complex.

[0101] Step C13: Perform topological feature tracking processing on the second homology group to obtain the second persistence graph.

[0102] In the above scheme, for the second edge point set, the second persistence diagram is calculated by the following steps:

[0103] 1) Constructing the Second Simplicial Complex: Starting from the data points, a series of nested simplicial complexes are constructed by selecting different scale parameters. The data points are connected using simple geometric objects (such as points, line segments, and triangles) to form a simplicial complex. These geometric objects are called simplices, and a simplicial complex is a collection of simplices.

[0104] 3) Computing the Second Homology Group: At each scale, the corresponding homology group is calculated to identify the topological characteristics of the data at that scale. The 0-dimensional homology group H0 describes the number of connected components in space. The 1-dimensional homology group H1 describes 1-dimensional holes in space, i.e., rings or cycles. The 2-dimensional homology group H2 describes 2-dimensional holes in space, i.e., cavities.

[0105] 3) Computing a second persistence diagram: By tracking the birth and death of topological features at different scales, we generate a persistence bar diagram or persistence diagram. A persistence bar diagram uses the length of the bar to represent the persistence of the topological feature, while a persistence diagram uses the coordinates of the points (birth scale and death scale) to represent the persistence of the feature.

[0106] In some embodiments, step 104 includes:

[0107] In step D1, for any of the multiple targets, perform the following operations:

[0108] Step D11 : determining the difference between the first persistence map and the second persistence map.

[0109] Step D12: Determine the Diess similarity coefficient based on the true segmentation annotation and the training predicted segmentation annotation using the following formula:

[0110]

[0111] in, Denotes the Dyss similarity coefficient, p i represents the training prediction segmentation label of the i-th pixel in the image sample, g i represents the true segmentation label of the i-th pixel in the training image sample.

[0112] Step D13, determining a sub-loss function corresponding to the target based on the difference and the Dice similarity coefficient using the following formula:

[0113]

[0114] in, represents the Dyss similarity coefficient, d represents the difference, represents the sub-loss function;

[0115] The sub-loss functions corresponding to each target are summed to obtain the loss function.

[0116] In the above scheme, the real segmentation annotation corresponds to multiple targets, and the training prediction segmentation annotation

[0117] Using the definition of the Dice Loss similarity coefficient loss function, we can get the value of the loss function between the true segmentation label of the current target and the training predicted segmentation label.

[0118] The Dice Similarity Coefficient loss function is a loss function used to evaluate the performance of image segmentation models. It is particularly suitable for tasks such as medical image segmentation that require accurate calculation of overlapping areas. It is based on the Dice Similarity Coefficient (DSC), and its goal is to maximize the overlap between the training predicted segmentation annotations and the true segmentation annotations.

[0119] For the segmentation target c, the Dice similarity coefficient loss function is defined as:

[0120]

[0121] On the basis of the Dyss similarity coefficient loss function, the difference d calculated in the previous step is added as a coefficient to obtain a new loss function (i.e., sub-loss function), which is referred to as

[0122]

[0123] Repeat this process until all the sub-loss functions of the segmentation targets are calculated, and the loss functions of all targets are summed up and returned to obtain the final loss function for network optimization, which is shown below:

[0124]

[0125] Where C is the total number of segmentation targets.

[0126] This loss function is based on the theory of persistent homology and takes into account the topological differences between the intersection and union of model predictions and true annotations. It enables the model to focus on segmentation targets whose topological structures are difficult to correctly describe during training, thereby improving the overall segmentation accuracy and topological correctness, making it more suitable for clinical use.

[0127] In some embodiments, the difference comprises a bottleneck distance.

[0128] Step D11 includes:

[0129] For any of the multiple targets, do the following:

[0130] The bottleneck distance is determined based on the first persistence graph and the second persistence graph using the following formula:

[0131]

[0132] Among them, d b (D1, D2) represents the bottleneck distance, D1 represents the first persistence map, D2 represents the second persistence map, γ(x) represents all bijective mappings from D1 to D2, ||·|| represents the Euclidean distance, and x represents a pixel in the first persistence map.

[0133] In the above scheme, the bottleneck distance is used to measure the difference between two persistence graphs, which is defined as the minimum maximum matching distance between the two graphs.

[0134] The difference between two persistence graphs can be better determined by the bottleneck distance.

[0135] In some embodiments, the difference comprises a Wasserstein distance.

[0136] Step D11 includes:

[0137] For any of the multiple targets, do the following:

[0138] The Wasserstein distance is determined based on the first persistence graph and the second persistence graph using the following formula:

[0139]

[0140] Among them, d w (D1, D2) represents the Wasserstein distance, D1 represents the first persistence map, D2 represents the second persistence map, γ(x) represents all bijective mappings from D1 to D2, x represents a pixel point in the first persistence map, and p takes the value 1 or 2.

[0141] In the above scheme, Wasserstein distance is used to measure the minimum total distance between all point pairs between two persistence graphs.

[0142] The difference between two persistence graphs can be better determined by the Wasserstein distance.

[0143] In some embodiments, the difference comprises a matching distance.

[0144] Step D11 includes:

[0145] For any of the multiple targets, do the following:

[0146]

[0147] Among them, d M (D1, D2) represents the matching distance, D1 represents the first persistence map, D2 represents the second persistence map, γ(x) represents all bijective mappings from D1 to D2, x represents a pixel point in the first persistence map, and Δ represents a diagonal line.

[0148] In the above scheme, the matching distance is calculated based on the best matching of points in two persistence graphs. Unlike the bottleneck distance and Wasserstein distance, it considers not only the distance between paired points but also the distance from unmatched points to the diagonal of the graph.

[0149] The difference between two persistence graphs can be better determined by matching distance.

[0150] In some embodiments, the true segmentation annotation corresponds to multiple targets, and the training predicted segmentation annotation corresponds to multiple targets.

[0151] In step 105, determining the index corresponding to the target in the training image sample based on the training image sample with the real segmentation annotation and the image sample with the training predicted segmentation annotation includes:

[0152] Step E1, based on the real segmentation labels corresponding to the multiple targets, the training image samples are respectively one-hot encoded to obtain multiple first encoded binary images, and based on the training predicted segmentation labels corresponding to the multiple targets, the image samples are respectively one-hot encoded to obtain multiple second encoded binary images.

[0153] In step E2, for any of the multiple targets, perform the following operations:

[0154] Step E21 : determining a first target binary image corresponding to the target from the plurality of first coded binary images, and determining a second target binary image corresponding to the target from the plurality of second coded binary images.

[0155] Step E22: determining the intersection of the first target binary image and the second target binary image, and determining the union of the first target binary image and the second target binary image.

[0156] Step E23 : Processing the intersection by a convex hull algorithm to obtain a first edge point set, and processing the union by a convex hull algorithm to obtain a second edge point set.

[0157] Step E24 : dividing the corresponding first edge point set and the second edge point set according to a preset division scale to obtain a plurality of edge sub-point set pairs, each edge sub-point set pair including a first edge sub-point set and a second edge sub-point set.

[0158] Step E25: For each edge sub-point set pair, construct a third simplicial complex based on the first edge sub-point set using a preset scale parameter, and construct a fourth simplicial complex based on the second edge sub-point set using a preset scale parameter.

[0159] Step E26, determining a third homology group based on the third simplicial complex, and determining a fourth homology group based on the fourth simplicial complex.

[0160] Step E27: performing topological feature tracking processing on the third homology group to obtain a third persistence graph, and performing topological feature tracking processing on the fourth homology group to obtain a fourth persistence graph.

[0161] Step E28: For each pair of sub-edge sub-point sets, determine the difference between the corresponding third persistence map and the fourth persistence map, and multiply the coordinates of the image sample where the training prediction segmentation annotation corresponding to the target is located with the difference to obtain a product processing result.

[0162] Step E29: Determine the index based on the multiplication result and the first target binary image using the following formula:

[0163]

[0164] Among them, Topo DSC (pred, gt) represents the index, pred topo Represents the product processing result, and gt represents the first target binary image.

[0165] In the above scheme, this application proposes a target segmentation metric based on the theory of persistent homology. Similar to the implementation process of the proposed loss function, this metric also calculates a persistence graph for the true segmentation annotations and the training prediction segmentation annotations to measure the topological differences between the two. Its implementation process is as follows:

[0166] Obtain CT image data and its corresponding true segmentation annotations and training prediction segmentation annotations, and perform one-hot encoding on the true segmentation annotations and the training prediction segmentation annotations.

[0167] The true segmentation annotations and training prediction segmentation annotations are represented as arrays of size (H, W, Z). H, W, and Z are the length, width, and number of slices of the CT image, respectively. One-hot encoding separates the annotations of different segmentation targets. After one-hot encoding, the true segmentation annotations and training prediction segmentation annotations have a size of (C, H, W, Z).

[0168] Get the true segmentation annotation and training prediction segmentation annotation corresponding to one of the targets c, that is, obtain two binary images, referred to as the first target binary image gt c and the second target binary map pred c .

[0169] Use the convex hull algorithm to extract the first target binary image gt c and the second target binary map pred c Draw the edge and get two edge point sets S pred and S gt .

[0170] This step is similar to the calculation step of the loss function defined previously, and can also be replaced by gradient calculation. The obtained edge point set S pred and S gt It is composed of three-dimensional coordinates. For any of the two coordinates (x, y, z), 1≤x≤H, 1≤y≤W, and 1≤z≤Z are satisfied. H, W, and Z are the length, width, and number of slices of the CT image, respectively.

[0171] Given a partition scale of r∈[2, 3, 4], the edge point set S pred and S gt The coordinate size of the stronghold is divided into edge point subsets according to the division scale r and Get edge point subset pairs

[0172] According to the division scale r, S pred and S gt The points in are divided according to the size of the coordinates. Let the integers 0≤a, b, c≤r-1, and the number of non-repeating arrays composed of these three integers is r 3 For a given array [a, b, c], satisfy

[0173] That is, the data is divided into the categories corresponding to the array. Given different scales r, repeat this process.

[0174] Using the persistent homology theory, the edge point subset pairs Calculate the persistence graph and obtain the persistence graph pair set Similar to the calculation steps of the previous loss function, the steps for calculating the persistence graph are: constructing a simplicial complex, calculating the homology group, and calculating the persistence graph. Take i∈[1, r 3 ], respectively calculated The corresponding persistence graph and Corresponding persistence graph. Traverse all possible values ​​of i and obtain the persistence graph pair set

[0175] right Calculate the bottleneck distance pair by pair, and get This step is similar to the previous loss function calculation step and can also be replaced by Wasserstein distance and matching distance.

[0176] Repeat the above steps until all the division scales are traversed and the The bottleneck distance d b As a coefficient, and the corresponding coordinate range of pred c Multiply.

[0177]

[0178] Where i = r 2 ·a+r·b+c. For a certain i and a certain The values ​​of the coordinates (x, y, z) satisfy

[0179] Using the definition of the Dice similarity coefficient, we can get the values ​​of the evaluation indicators of the true segmentation annotation of the current target and the training prediction segmentation annotation:

[0180] Dyss similarity coefficient is a commonly used metric to measure the similarity between two sample sets. In image segmentation, DSC is used to compare the degree of overlap between the true segmentation annotation and the training prediction segmentation annotation. t And the training prediction segmentation annotation pred, DSC is defined as:

[0181]

[0182] Where |pred| and |gt| represent the size of the training predicted segmentation annotation pred and the true segmentation annotation gt, respectively, and |pred∩gt| represents the size of the intersection of the training predicted segmentation annotation pred and the true segmentation annotation gt. Taking into account the correction of the training predicted segmentation annotation pred in the previous step, the indicators are defined as follows:

[0183]

[0184] Repeat this process until all the metrics of the segmentation targets are calculated.

[0185] This metric, like the previously defined loss function, uses a persistence graph to describe the topological structure of the object segmentation annotations. The difference lies in the calculation of the persistence graph for the object annotations at different scales. This is because multi-scale computation reduces model training efficiency during model training. The multi-scale perspective in the metric calculation helps measure the topological correctness of the model's predicted annotations in various regions.

[0186] In some embodiments, the data set preparation process is divided into the following steps: Figure 2A As shown:

[0187] Step 2011: Collect CT images.

[0188] Step 2012: Use professional medical image processing software to manually annotate the CT image.

[0189] Step 2013: Confirm the annotation result to see if it is correct. If not, return to step 202 to modify the incorrect annotation. If yes, proceed to step 2014.

[0190] Step 2014: Check the completeness of the CT image annotation.

[0191] Step 2015: pre-process the CT image.

[0192] Step 2016: divide the CT image dataset.

[0193] Step 2017: Obtain a CT image dataset containing manual segmentation and annotation.

[0194] In some embodiments, after the dataset is constructed, the model training process is divided into the following steps: Figure 2B As shown:

[0195] Step 2021, CT image training dataset.

[0196] Step 2022, data enhancement.

[0197] Step 2023, segmentation model based on U-Net.

[0198] In step 2024 , a loss function based on persistent homology is calculated in combination with the actual segmentation map annotation.

[0199] Step 2025: update the network parameters of the segmentation model by gradient descent.

[0200] Step 2026: Determine whether the number of training iterations or the set number of times has been reached or the loss function has reached a threshold. If not, return to step 2023; if so, proceed to step 2027.

[0201] Step 2027, trained segmentation model.

[0202] Step 2028: Calculate an evaluation index based on persistent homology.

[0203] In some embodiments, the determination process of the target segmentation loss function based on persistent homology is as follows: Figure 2C As shown:

[0204] In step 2031 , one-hot encoding is performed using the real annotations of the CT image and the segmentation map predicted by the model.

[0205] Step 2032: Obtain the model prediction and true label corresponding to one of the organs (ie, the target).

[0206] Step 2033: Calculate the intersection and union of the model predictions and the true annotations.

[0207] Step 2034: Obtain edge point sets using a convex hull algorithm.

[0208] Step 2035: Calculate the persistence graph.

[0209] Step 2036, calculate the bottleneck distance.

[0210] Step 2037, determine whether all segmentation targets have been traversed, if not, return to step 2032, if so, execute step 2038.

[0211] Step 2038, calculate the loss function.

[0212] In some embodiments, the indicator also calculates a persistence graph for the model prediction and the true value annotation to measure the topological difference between the two. The determination process is as follows: Figure 2D As shown:

[0213] In step 2041 , one-hot encoding is performed using manual annotation and model prediction of the CT image.

[0214] Step 2042: Obtain a binary image corresponding to an uncalculated organ (ie, target).

[0215] Step 2043: Use the convex hull algorithm to obtain two edge point sets.

[0216] Step 2044: Divide the above point set into N subset pairs (subset pair 1, subset pair 2, ..., subset pair N) according to the coordinate size of the points and the division scale.

[0217] Step 2045, calculate the persistence graph.

[0218] Step 2046, calculate the bottleneck distance.

[0219] Step 2047 , determining whether all division scales have been traversed, if not, returning to step 2044 , if so, executing step 2048 .

[0220] Step 2048: Calculate the evaluation index of the current organ.

[0221] Step 2049, determine whether all segmentation targets have been traversed, if not, return to step 2042, if so, execute step 20410.

[0222] Step 20410, calculate the overall evaluation index.

[0223] It should be noted that the method of the embodiment of the present application can be performed by a single device, such as a computer or server. The method of this embodiment can also be applied in a distributed scenario and performed by multiple devices working together. In such a distributed scenario, one of the multiple devices may only perform one or more steps of the method of the embodiment of the present application, and the multiple devices will interact with each other to complete the method.

[0224] It should be noted that the above description is limited to some embodiments of the present application. Other embodiments are within the scope of the appended claims. In some cases, the actions or steps recited in the claims may be performed in an order different from that described in the above embodiments and still achieve the desired results. Furthermore, the processes depicted in the accompanying drawings do not necessarily require the specific order or sequential order shown to achieve the desired results. In certain embodiments, multitasking and parallel processing are also possible or may be advantageous.

[0225] Based on the same inventive concept, corresponding to any of the above-mentioned embodiments and methods, the present application also provides a device for object segmentation of a computed tomography image.

[0226] refer to Figure 3 , the object segmentation device of the computer tomography image comprises:

[0227] The sample acquisition module 301 is configured to acquire training image samples with real segmentation annotations and build an initial model;

[0228] A training input module 302 is configured to input training image samples with real segmentation labels into the initial model, and output image samples with training predicted segmentation labels via the initial model;

[0229] The persistent homology processing module 303 is configured to process the training image samples with real segmentation labels and the image samples with training predicted segmentation labels using a persistent homology algorithm to obtain a persistence map;

[0230] a loss function determination module 304 configured to determine a loss function based on the persistence map, the true segmentation annotations, and the training predicted segmentation annotations;

[0231] a training adjustment module 305 configured to perform training adjustment on the initial model based on a minimization result obtained during the minimization process of the loss function, thereby obtaining a trained and adjusted initial model, and determine an indicator corresponding to an object in the training image sample based on the training image sample with the true segmentation annotation and the image sample with the training predicted segmentation annotation;

[0232] The continuous adjustment module 306 is configured to continuously adjust the trained and adjusted initial model in response to the indicator being less than a preset indicator threshold; or

[0233] The model determination module 307 is configured to use the trained and adjusted initial model as a segmentation model in response to the indicator being greater than or equal to a preset indicator threshold;

[0234] The prediction acquisition module 308 is configured to acquire a tomographic image to be predicted;

[0235] The prediction segmentation module 309 is configured to input the tomographic image to be predicted into the segmentation model, perform segmentation prediction on at least one target in the tomographic image to be predicted through the segmentation model, and obtain a scanned image with predicted segmentation annotations.

[0236] For the convenience of description, the above devices are described as being divided into various modules according to their functions. Of course, when implementing this application, the functions of each module can be implemented in the same or multiple software and / or hardware.

[0237] The apparatus of the above embodiment is used to implement the object segmentation method of the corresponding computed tomography image in any of the above embodiments, and has the beneficial effects of the corresponding method embodiment, which will not be described in detail here.

[0238] Based on the same inventive concept, corresponding to any of the above-mentioned embodiments and methods, the present application also provides an electronic device, including a memory, a processor, and a computer program stored in the memory and runnable on the processor, wherein when the processor executes the program, the target segmentation method of the computed tomography image described in any of the above embodiments is implemented.

[0239] Figure 4A more specific hardware structure diagram of an electronic device provided in this embodiment is shown. The device may include: a processor 401, a memory 402, an input / output interface 403, a communication interface 404, and a bus 405. The processor 401, the memory 402, the input / output interface 403, and the communication interface 404 are communicatively connected to each other within the device via the bus 405.

[0240] The processor 401 can be implemented using a general-purpose CPU (Central Processing Unit), a microprocessor, an application-specific integrated circuit (ASIC), or one or more integrated circuits, and is used to execute relevant programs to implement the technical solutions provided in the embodiments of this specification.

[0241] The memory 402 can be implemented in the form of ROM (Read Only Memory), RAM (Random Access Memory), static storage devices, dynamic storage devices, etc. The memory 402 can store an operating system and other application programs. When the technical solutions provided in the embodiments of this specification are implemented through software or firmware, the relevant program code is stored in the memory 402 and is called and executed by the processor 401.

[0242] The input / output interface 403 is used to connect to input / output modules to implement information input and output. The input / output modules can be configured as components within the device (not shown in the figure) or can be externally connected to the device to provide corresponding functions. Input devices may include a keyboard, mouse, touch screen, microphone, various sensors, etc., and output devices may include a display, speaker, vibrator, indicator light, etc.

[0243] The communication interface 404 is used to connect to a communication module (not shown) to enable communication between the device and other devices. The communication module can communicate via a wired method (such as USB, network cable, etc.) or a wireless method (such as mobile network, WIFI, Bluetooth, etc.).

[0244] The bus 405 comprises a pathway for transmitting information between various components of the device (eg, the processor 401 , the memory 402 , the input / output interface 403 , and the communication interface 404 ).

[0245] It should be noted that although the above device only shows the processor 401, the memory 402, the input / output interface 403, the communication interface 404, and the bus 405, in a specific implementation, the device may also include other components necessary for normal operation. In addition, it will be understood by those skilled in the art that the above device may only include the components necessary to implement the embodiments of this specification, and does not necessarily include all the components shown in the figure.

[0246] The electronic device of the above embodiment is used to implement the corresponding target segmentation method of the computed tomography image in any of the above embodiments, and has the beneficial effects of the corresponding method embodiment, which will not be repeated here.

[0247] Based on the same inventive concept, corresponding to any of the above-mentioned embodiment methods, the present application also provides a non-transitory computer-readable storage medium, wherein the non-transitory computer-readable storage medium stores computer instructions, and the computer instructions are used to enable the computer to execute the target segmentation method of the computed tomography image as described in any of the above embodiments.

[0248] The computer-readable media of this embodiment include permanent and non-permanent, removable and non-removable media that can be used to store information by any method or technology. The information can be computer-readable instructions, data structures, program modules or other data. Examples of computer storage media include, but are not limited to, phase change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory or other memory technology, read-only compact disc read-only memory (CD-ROM), digital versatile disc (DVD) or other optical storage, magnetic cassettes, magnetic tape magnetic disk storage or other magnetic storage devices or any other non-transmission media that can be used to store information that can be accessed by a computing device.

[0249] The computer instructions stored in the storage medium of the above embodiment are used to enable the computer to execute the object segmentation method of the computed tomography image as described in any of the above embodiments, and have the beneficial effects of the corresponding method embodiments, which will not be repeated here.

[0250] Those skilled in the art should understand that the discussion of any of the above embodiments is merely illustrative and is not intended to imply that the scope of the present application is limited to these examples. In line with the present application, the technical features in the above embodiments or different embodiments may be combined, the steps may be implemented in any order, and there are many other variations of the different aspects of the embodiments of the present application as described above, which are not provided in detail for the sake of simplicity.

[0251] In addition, for simplicity of description and discussion, and in order not to make the embodiment of the application difficult to understand, the known power supply / ground connection with integrated circuit (IC) chip and other components may or may not be shown in the accompanying drawings provided. In addition, the device can be shown in the form of a block diagram to avoid making the embodiment of the application difficult to understand, and this also takes into account the following fact, that is, the details of the embodiment of these block diagram devices are highly dependent on the platform to be implemented in the embodiment of the application (that is, these details should be fully within the scope of understanding of those skilled in the art). When specific details (for example, circuit) are set forth to describe exemplary embodiments of the application, it will be apparent to those skilled in the art that the embodiment of the application can be implemented without these specific details or when these specific details are changed. Therefore, these descriptions should be considered to be illustrative rather than restrictive.

[0252] Although the present invention has been described in conjunction with specific embodiments thereof, many alternatives, modifications, and variations of these embodiments will be apparent to those skilled in the art based on the foregoing description. For example, other memory architectures (e.g., dynamic RAM (DRAM)) may utilize the embodiments discussed.

[0253] The embodiments of the present application are intended to cover all such substitutions, modifications, and variations that fall within the broad scope of the present application. Therefore, any omissions, modifications, equivalent substitutions, improvements, etc. made within the spirit and principles of the embodiments of the present application should be included in the scope of protection of the present application.

Claims

1. A method for object segmentation in a computed tomography image, characterized in that: include: Obtain training image samples with real segmentation annotations and build an initial model; Inputting training image samples with real segmentation labels into the initial model, and outputting image samples with training predicted segmentation labels through the initial model; Based on the training image samples with real segmentation annotations and the image samples with training predicted segmentation annotations, the persistent homology algorithm is used to process them to obtain a persistence map; determining a loss function based on the persistence map, the true segmentation annotations, and the training predicted segmentation annotations; Training and adjusting the initial model according to a minimization result obtained in the process of minimizing the loss function to obtain a trained and adjusted initial model, and determining an indicator corresponding to a target in the training image samples based on the training image samples with true segmentation annotations and the image samples with training predicted segmentation annotations; In response to the indicator being less than a preset indicator threshold, continuously adjusting the trained and adjusted initial model; or, In response to the indicator being greater than or equal to a preset indicator threshold, using the trained and adjusted initial model as a segmentation model; acquiring a tomographic image to be predicted; Inputting the tomographic image to be predicted into the segmentation model, performing segmentation prediction on at least one target in the tomographic image to be predicted using the segmentation model, and obtaining a scanned image with predicted segmentation annotations; The true segmentation annotation corresponds to multiple targets, and the training prediction segmentation annotation corresponds to multiple targets; The training image samples with real segmentation labels and the image samples with training predicted segmentation labels are processed by a persistent homology algorithm to obtain a persistence map, including: One-hot encoding is performed on the training image samples based on the true segmentation labels corresponding to the multiple targets to obtain a plurality of first encoded binary images, and one-hot encoding is performed on the image samples based on the training predicted segmentation labels corresponding to the multiple targets to obtain a plurality of second encoded binary images; For any of the multiple targets, do the following: Determine a first target binary image corresponding to the target from the plurality of first coded binary images, and determine a second target binary image corresponding to the target from the plurality of second coded binary images; Determining an intersection between the first target binary image and the second target binary image, and determining a union between the first target binary image and the second target binary image; Processing the intersection using a convex hull algorithm to obtain a first edge point set, and processing the union using a convex hull algorithm to obtain a second edge point set; Determining a first persistence graph based on the first edge point set, and determining a second persistence graph based on the second edge point set, and using the first persistence graph and the second persistence graph as the persistence graph; The determining of a first persistence graph based on the first edge point set includes: For any of the multiple targets, do the following: constructing a first simplicial complex according to the first edge point set using a preset scale parameter; determining a first homology group based on the first simplicial complex; Performing topological feature tracking processing on the first homology group to obtain the first persistence graph; The determining of a second persistence graph based on the second edge point set includes: For any of the multiple targets, do the following: constructing a second simplicial complex according to the second edge point set using a preset scale parameter; determining a second homology group based on the second simplicial complex; Perform topological feature tracking on the second homology group to obtain the second persistence graph.

2. The method according to claim 1, characterized in that The determining of a loss function according to the persistence map, the true segmentation annotation, and the training predicted segmentation annotation comprises: For any of the multiple targets, do the following: determining a difference between the first persistence map and the second persistence map; The Dice similarity coefficient is determined based on the true segmentation annotation and the training prediction segmentation annotation using the following formula: in, represents the Dyss similarity coefficient, Indicates the image sample The training prediction segmentation annotation of pixels, Indicates the first The true segmentation annotation of pixels; The sub-loss function corresponding to the target is determined by the following formula based on the difference and the Dice similarity coefficient: in, represents the Dyss similarity coefficient, Indicates the difference, represents the sub-loss function; The sub-loss functions corresponding to each target are summed to obtain the loss function.

3. The method according to claim 2, characterized in that Said differences include bottleneck distance; The determining a difference between the first persistence map and the second persistence map comprises: For any of the multiple targets, do the following: The bottleneck distance is determined based on the first persistence graph and the second persistence graph using the following formula: in, represents the bottleneck distance, represents the first persistence graph, represents the second persistence graph, Indicates from arrive All bijective mappings of represents the Euclidean distance, Represents a pixel in the first persistence map.

4. The method according to claim 2, characterized in that Said differences include Wasserstein distance; The determining a difference between the first persistence map and the second persistence map comprises: For any of the multiple targets, do the following: The Wasserstein distance is determined based on the first persistence graph and the second persistence graph using the following formula: in, represents the Wasserstein distance, represents the first persistence graph, represents the second persistence graph, Indicates from arrive All bijective mappings of represents the pixel in the first persistence map, The value is 1 or 2.

5. The method according to claim 2, characterized in that Said differences include matching distances; The determining a difference between the first persistence map and the second persistence map comprises: For any of the multiple targets, do the following: in, represents the matching distance, represents the first persistence graph, represents the second persistence graph, Indicates from arrive All bijective mappings of represents the pixel in the first persistence map, Represents a diagonal line.

6. The method according to claim 1, characterized in that The true segmentation annotation corresponds to multiple targets, and the training prediction segmentation annotation corresponds to multiple targets; The determining of the index corresponding to the target in the training image sample based on the training image sample with the real segmentation annotation and the image sample with the training predicted segmentation annotation includes: One-hot encoding is performed on the training image samples based on the true segmentation labels corresponding to the multiple targets to obtain a plurality of first encoded binary images, and one-hot encoding is performed on the image samples based on the training predicted segmentation labels corresponding to the multiple targets to obtain a plurality of second encoded binary images; For any of the multiple targets, do the following: Determine a first target binary image corresponding to the target from the plurality of first coded binary images, and determine a second target binary image corresponding to the target from the plurality of second coded binary images; Determining an intersection between the first target binary image and the second target binary image, and determining a union between the first target binary image and the second target binary image; Processing the intersection using a convex hull algorithm to obtain a first edge point set, and processing the union using a convex hull algorithm to obtain a second edge point set; Dividing the corresponding first edge point set and the second edge point set according to a preset division scale to obtain a plurality of edge sub-point set pairs, each edge sub-point set pair including a first edge sub-point set and a second edge sub-point set; For each pair of edge sub-point sets, constructing a third simplicial complex based on the first edge sub-point set using a preset scale parameter, and constructing a fourth simplicial complex based on the second edge sub-point set using a preset scale parameter; determining a third homology group based on the third simplicial complex, and determining a fourth homology group based on the fourth simplicial complex; Performing topological feature tracing processing on the third homology group to obtain a third persistence graph, and performing topological feature tracing processing on the fourth homology group to obtain a fourth persistence graph; For each pair of sub-edge sub-point sets, determining a difference between the corresponding third persistence map and the fourth persistence map, and multiplying the difference with the coordinates of the image sample where the training prediction segmentation annotation corresponding to the target is located to obtain a product processing result; The indicator is determined based on the product processing result and the first target binary image using the following formula: in, Indicates the indicator, Represents the result of product processing, Represents the first target binary image.

7. An electronic device comprising a memory, a processor, and a computer program stored in the memory and running on the processor, characterized in that: When the processor executes the program, the method according to any one of claims 1 to 6 is implemented.

Citation Information

Patent Citations

  • Topology awareness-based point cloud segmentation network construction method, segmentation method and device

    CN115222747A

  • Microvascular decompression-oriented multi-modal multi-target segmentation method and system

    CN117671748A