A cross-domain brain vessel segmentation method based on vessel enhancement and active learning
Patent Information
- Application Number
- CN202611195670.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-08-07
- Publication Date
- 2026-10-27
AI Technical Summary
[0009]针对现有预训练脑血管分割模型因源域与目标域之间存在数据分布差异而产生大量高置信度漏分割,并且传统基于预测概率不确定性的主动学习方法难以发现该类漏分割血管的技术问题,本发明提供一种基于血管增强和主动学习的跨域脑血管分割方法,该方法形成“初始分割—血管增强—血管段构图—联合评分—记忆过滤—人工确认—三状态监督—模型适配—重新推理”的迭代闭环,具体利用不依赖分割模型预测概率的血管增强方法从目标域图像自身发现潜在管状结构,将中心线端点或分叉点之间的连续血管段定义为主动学习查询单位,结合候选血管段的深度特征价值、拓扑稳定性和历史记忆进行筛选,由人工仅确认少量高价值血管段,再通过三状态标签、原型对比学习、输出决策边界约束和管状拓扑约束对模型进行迭代适配,从而降低完整三维脑血管标注成本并提高目标域分割精度
[0081]与现有技术相比,本发明提供的基于血管增强和主动学习的跨域脑血管分割方法,具有以下有益效果:1)本发明不以模型预测不确定性作为发现漏分割血管的必要条件,利用不依赖分割模型预测概率的血管增强结果发现被预训练模型高置信度判断为背景的目标域真实血管,弥补传统不确定性主动学习无法发现预测概率接近0的漏分割血管的缺陷;2)通过血管段级特征分析和拓扑稳定性分析过滤血管增强结果中的噪声,相较于检查全部增强区域,可提高待检查候选中真实血管的比例;3)以血管段作为主动学习和人工确认单位,标注人员仅需对少量高价值血管段进行确认或局部修正,无需完整勾画三维脑血管;4)利用血管特征记忆库和噪声特征记忆库复用历史标注知识,可减少相似血管和相似噪声的重复人工判断;5)采用血管、背景和不确定区域三状态监督,不将未确认的区域直接视为背景,防止伪标签漏标对潜在真实血管产生错误抑制;6)通过Dice、交叉熵、clDice、原型对比、输出间隔及管状拓扑约束联合优化,可同时改善血管区域重叠、细血管识别、中心线连续性、目标域特征适配及孤立假阳性问题;7)通过多轮主动学习逐步补充最能反映目标域特征差异的血管样本,可在降低人工标注成本的同时提高模型在目标域TOF-MRA图像上的分割精度和适用性。
Smart Images

Figure SMS_3 
Figure SMS_4 
Figure SMS_11
Abstract
Description
Technical Field
[0001] This invention relates to the fields of medical image processing, artificial intelligence-assisted diagnosis, and cerebrovascular image analysis, specifically to a cross-domain cerebrovascular segmentation method for time-of-flight magnetic resonance angiography (TOF-MRA). This method utilizes a pre-trained cerebrovascular segmentation model, vessel enhancement, segment-level active learning, feature memory, and topological constraints to achieve low-cost annotation and segmentation model adaptation of target domain cerebrovascular data. Background Technology
[0002] Cerebral vascular segmentation is a fundamental step in cerebrovascular disease screening, vascular morphology analysis, vascular stenosis assessment, aneurysm-assisted diagnosis, and surgical planning. TOF-MRA, with its non-invasive nature, lack of contrast agent injection, and ability to clearly visualize cerebral vascular structures, has been widely used in cerebrovascular imaging and vascular structure analysis.
[0003] Existing deep learning-based methods for segmenting brain blood vessels typically require a large amount of accurately labeled data. Due to the wide range of diameter variations in brain blood vessels, the large number of branches, the small size of terminal vessels, low local contrast, and unclear boundaries with surrounding tissues, complete annotation of three-dimensional brain blood vessels usually requires professional personnel to examine and correct layer by layer, resulting in high annotation costs.
[0004] To reduce the workload of labeling target domain data from scratch, a brain vessel segmentation model trained on one or more public datasets can be used for initial segmentation, followed by manual correction. However, different datasets vary in terms of scanning equipment, magnetic field strength, scanning parameters, spatial resolution, image contrast, patient population, reconstruction methods, and preprocessing procedures. This can lead to performance degradation of pre-trained brain vessel segmentation models on target domain data, particularly in the missed segmentation and breakage of small vessels, low-contrast vessels, and vessels specific to the target domain.
[0005] Taking the previously used CESAR cerebral vessel segmentation network as an example, this network, trained on multiple source domain cerebral vessel datasets, exhibits a certain generalization ability, but still shows significant omissions in target domain TOF-MRA images. Feature analysis indicates that the depth features of correctly segmented target domain vessels are quite similar to those of source domain vessels; the features of omissions in segmenting real vessels deviate from those of source domain vessels, but do not completely overlap with the background features of the source domain. Therefore, these omissions can reflect the key feature differences between the source and target domains and have high adaptation value.
[0006] Traditional active learning methods typically select regions to be labeled based on prediction entropy, the degree to which the prediction probability approaches 0.5, or the prediction discrepancies between multiple models. However, in cases of severe domain shift, some real blood vessels may be predicted by the model as background with high confidence, resulting in a prediction probability close to 0 rather than close to 0.5. In such cases, traditional uncertainty metrics will treat these regions as low-uncertainty backgrounds, making it difficult to identify the truly high-confidence missed segments of blood vessels that need labeling.
[0007] The Frangi vessel enhancement algorithm analyzes tubular structures at different scales based on the eigenvalues of the local Hessian matrix of the image. It does not rely on manual annotation of the target domain, nor is it directly limited by the source domain feature distribution of the pre-trained brain vessel segmentation model. Therefore, even if a real blood vessel is predicted as background by the initial model, as long as the region still has tubular structures and vascular imaging features, it may still receive a response in the vessel enhancement result.
[0008] However, vascular enhancement results may also contain image noise, tissue edges, sulci, artifacts, and other non-vascular structures with local tubular features. Treating all enhancement results as pseudo-labels can easily introduce erroneous supervision; leaving all enhanced regions to manual inspection would result in a large amount of wasted work. Therefore, current technology lacks a closed-loop method that uses vascular anatomy as a unit, comprehensively utilizes feature differences, topological stability, and historical annotation knowledge to select candidate vascular segments, and completes target domain adaptation through partial supervision and feature optimization. Summary of the Invention
[0009] To address the technical problem that existing pre-trained cerebral vessel segmentation models generate a large number of high-confidence missed segments due to data distribution differences between the source and target domains, and that traditional active learning methods based on the uncertainty of prediction probabilities are unable to detect such missed segments, this invention provides a cross-domain cerebral vessel segmentation method based on vessel enhancement and active learning. This method forms an iterative closed loop of "initial segmentation—vessel enhancement—vessel segment mapping—joint scoring—memory filtering—manual confirmation—three-state supervision—model adaptation—re-inference". Specifically, it uses a vessel enhancement method that does not rely on the prediction probability of the segmentation model to discover potential tubular structures from the target domain image itself. Continuous vessel segments between the endpoints or bifurcation points of the centerline are defined as active learning query units. Candidate vessel segments are screened by combining depth feature value, topological stability, and historical memory. Only a small number of high-value vessel segments are manually confirmed. Then, the model is iteratively adapted through three-state labeling, prototype comparison learning, output decision boundary constraints, and tubular topological constraints, thereby reducing the cost of complete 3D cerebral vessel annotation and improving the segmentation accuracy of the target domain.
[0010] To solve the above-mentioned technical problems, the present invention adopts the following technical solution:
[0011] A cross-domain cerebral vascular segmentation method based on vascular enhancement and active learning includes the following steps:
[0012] S1. Constructing an initial cerebral blood vessel segmentation model and source domain feature prototype.
[0013] An initial cerebral blood vessel segmentation model is trained using one or more source domain cerebral blood vessel datasets. Source domain images with blood vessel annotations are input into the model, and feature maps from the terminal feature layer of the model decoder are extracted. Features of the source domain vascular region and the source domain background region are statistically analyzed to construct a prototype of source domain vascular features. and source domain background feature prototype :
[0014]
[0015]
[0016] in, and These represent the number of source domain vascular voxels and the number of background voxels, respectively, which are included in the statistics. Indicates the first Decoder feature vectors corresponding to each source domain vascular voxel. Indicates the first Decoder feature vectors corresponding to each source domain background voxel;
[0017] S2. Obtain the initial cerebral blood vessel segmentation results of the target domain.
[0018] The target domain TOF-MRA image is processed by orientation unification, spatial resampling, intensity normalization, brain region cropping or brain region masking, and the processed image is input into the initial brain blood vessel segmentation model to obtain the blood vessel prediction probability of each voxel; the obtained blood vessel prediction probability is thresholded according to a preset threshold to obtain the initial brain blood vessel segmentation mask, and small connected component removal and hole filling morphological post-processing are performed to obtain the initial brain blood vessel segmentation result of the target domain;
[0019] S3. Utilize multi-scale vascular enhancement to generate potential candidate regions for missed segmentation.
[0020] Multi-scale Frangi vascular enhancement is performed on the target domain TOF-MRA image. By calculating the eigenvalues of the local Hessian matrix at different scales and their combinations, a vascular enhancement response map is obtained. The maximum value or weighted fusion of responses at multiple scales in the vascular enhancement response map is taken, and a coarse vascular segmentation result is obtained based on a preset response threshold. The coarse vascular segmentation result is then compared with the initial brain vascular segmentation result to extract regions present in the vascular enhancement structure but not in the initial segmentation result, forming potential missed segmentation candidate regions.
[0021]
[0022] Among them, the first set This represents the binary region obtained from vascular enhancement, the second set. This represents the initial cerebral blood vessel segmentation result, and the difference between the two represents potential candidate regions that were missed during segmentation. ;
[0023] S4. Convert the candidate region into a vascular map and define vascular segments.
[0024] Three-dimensional centerlines are extracted from the coarse segmentation results of blood vessels or potential unsegmented candidate regions, and the centerlines are converted into a blood vessel map structure.
[0025]
[0026] in, Represents the structure of a blood vessel diagram. Represents the set of nodes along the center line. This represents the set of connecting edges between adjacent centralline nodes; endpoints, ordinary connecting points, and bifurcation points are identified based on the number of adjacencies of centralline voxels in the 3D neighborhood; a point with one adjacent centralline node is defined as an endpoint, and a point with three or more adjacent centralline nodes is defined as a bifurcation point; using endpoints and bifurcation points as break points, a continuous centralline path with no other bifurcation points between adjacent endpoints and bifurcation points is defined as a vascular segment; for multiple adjacent bifurcation voxels, they are first merged into one bifurcation node; for closed loop structures, break points are set at the point of maximum curvature, the point of minimum response, or a preset position; for each vascular segment, the centralline, centralline neighborhood, length, average diameter, average enhanced response, endpoint position, bifurcation relationship, and spatial position are recorded, and candidate segments with excessively short centralline lengths, excessively low responses, or located outside of ineffective brain regions are removed;
[0027] S5. Calculate the eigenvalue score of candidate vessel segments.
[0028] The target domain image is input into the initial cerebral blood vessel segmentation model, and the terminal feature map of the decoder is extracted. For each candidate blood vessel segment, feature sampling is performed within its centerline and a tubular neighborhood of a preset radius around the centerline. The blood vessel segment-level feature vector is obtained through average pooling, max pooling, attention pooling, or a combination thereof. The distance between the blood vessel segment-level feature vector of the candidate blood vessel segment and the source domain blood vessel feature prototype and the source domain background feature prototype are calculated respectively.
[0029] ,
[0030] in, Indicates the current candidate vessel segment. Indicates candidate vessel segment The vascular segment-level feature vector This is a prototype of source domain vascular features. As the prototype of the source domain background features, This represents the feature distance calculation function. and These represent candidate vessel segments. Distance to source domain vessel feature prototypes and source domain background feature prototypes; candidate vessel segments Two requirements must be met simultaneously: first, its features should not highly overlap with the source domain background and should have a certain vascular tendency; second, its features should differ from the existing vascular distribution in the source domain and be able to reflect the vascular performance of the target domain that the model has not yet fully learned; the feature value score of the candidate vascular segment is calculated as follows:
[0031]
[0032] ,
[0033] Among them, the feature value score is determined by the vascularity of the candidate segment. And domain offset degree Together, we determined that the vascular tendency Based on candidate vessel segments Blood vessel segment-level feature vector Calculation of the relative distance between the blood vessel prototype and the background prototype, and the degree of domain offset. Based on candidate vessel segments Blood vessel segment-level feature vector Calculation of the degree of offset from the source domain blood vessel distribution, normalization operation Used to standardize dimensions. To prevent constants with a denominator of zero;
[0034] S6. Calculate the topological stability score of the candidate vessel segment.
[0035] A slight perturbation that does not significantly alter the actual vascular anatomy is applied to the target domain image or the vessel enhancement process, and vessel enhancement, centerline extraction, and vessel segmentation are re-executed. For the original candidate vessel segments, vessel segments corresponding to spatial location, centerline direction, and endpoint relationships are searched in each perturbation result. The recurrence rate of candidate vessel segments, the degree of centerline overlap, changes in length and diameter, the degree of endpoint offset, and the consistency of connectivity with adjacent vessels are statistically analyzed. The topological stability score of the candidate vessel segments is calculated as follows:
[0036]
[0037] The topological stability score is determined by the proportion of candidate vessel segments retained under multiple perturbations. degree of overlap of center lines Stability of connection relationships and the degree of endpoint offset The weighted average is obtained by assigning weights from the first to the fourth. , , , Used to adjust the contribution of each indicator accordingly;
[0038] S7. Combined scoring and selection of the vessel segment to be examined.
[0039] The overall active learning score is calculated based on the feature value score and topological stability score of the candidate vessel segment:
[0040]
[0041] Among them, the comprehensive active learning score is composed of the feature value score. and topological stability score We get the weighted average. The weights of the feature value scores, The weights are assigned to the topological stability scores. The segments are sorted according to their comprehensive scores, and highly similar duplicate candidate segments are removed by feature clustering, spatial overlap suppression, or farthest point sampling. The prediction probability of the initial model is not a necessary condition for candidate selection. Even if the blood vessel prediction probability of a candidate segment is close to 0, it can still be selected as a high-value candidate as long as it has high blood vessel enhancement response, feature value, and topological stability.
[0042] S8. Manually confirm and locally correct candidate vessel segments.
[0043] The cerebrovascular analysis software displays the original image of the target domain, the initial segmentation results, the enhanced vascular response, the center line of the candidate vascular segment, the local 3D region of the candidate segment and its connection relationship with existing blood vessels to the annotators; the annotators confirm the candidate segment as a real blood vessel, as non-vascular noise, correct its endpoints or local range, confirm some sub-segments as blood vessels and the rest as background, or retain it as an uncertain region;
[0044] S9. Establish a vascular feature memory database and a noise feature memory database.
[0045] Manually verified features of real blood vessel segments are stored in a blood vessel feature memory database, and manually verified features of non-blood vessel noise segments are stored in a noise feature memory database. For subsequent candidate blood vessel segments, the maximum similarity between them and both the blood vessel feature memory database and the noise feature memory database is calculated.
[0046] ,
[0047] in, The maximum similarity between the candidate vessel segment and the vascular feature memory database. The maximum similarity between the candidate vessel segment and the noise feature memory. Candidate vessel segment The vascular segment-level feature vector For vascular feature memory bank The actual blood vessel segments in the middle, noise feature memory The non-vascular noise segment is selected; when the maximum similarity of a candidate vascular segment with the vascular feature memory is higher than the first threshold and significantly higher than its maximum similarity with the noise feature memory, the candidate vascular segment is automatically retained as a high-confidence vessel or its priority for manual inspection is reduced; conversely, when the maximum similarity of a candidate vascular segment with the noise vascular memory is higher than the second threshold and has a significant advantage, it is automatically filtered as high-confidence noise; only candidate vascular segments that cannot be reliably judged by either memory are submitted for manual inspection.
[0048] S10. Construct three-state supervised labels for blood vessels, background, and uncertain regions.
[0049] Based on the initial segmentation results, manual confirmation results, vascular enhancement response, and image intensity, a three-state supervised label is constructed. The post-processed reliable initial blood vessels, manually confirmed newly added blood vessels, and blood vessel regions determined with high confidence by the vascular feature memory are labeled as 1. Manually confirmed noise regions and high-confidence backgrounds that simultaneously meet the conditions of low vascular enhancement response and low image intensity are labeled as 0. Other regions that cannot be reliably determined are labeled as −1, as detailed below:
[0050]
[0051] In the formula, the three regions represent reliable vascular regions in sequence. Trustworthy background area and uncertain regions ;
[0052] S11. Use blood vessel segments as the query unit and three-dimensional sub-blocks as the training unit.
[0053] Active learning and manual annotation are performed on a segment-by-segment basis, but model training still takes 3D image sub-blocks as input. For each confirmed segment, multiple spatially overlapping 3D sub-blocks are extracted along the centerline, so that the sub-blocks simultaneously contain the target segment, adjacent vessels, surrounding tissues, and necessary background context. Each training batch simultaneously contains sub-blocks of newly confirmed segments in the current round, sub-blocks of confirmed noisy segments in the current round, sub-blocks of replays from previous rounds, sub-blocks of existing reliable vascular context, and random sub-blocks of the target domain.
[0054] S12. Calculate the basic segmentation loss in the clearly marked area.
[0055] Define regions with label values not equal to -1 as explicitly supervised regions:
[0056]
[0057] Dice loss, cross-entropy loss (CE), and clDice loss are calculated only within explicitly supervised regions. Uncertain regions do not participate in the corresponding direct classification supervision. The basic segmentation loss is:
[0058]
[0059] in, , , These represent the non-negative weight coefficients of Dice loss, cross-entropy loss CE, and clDice loss, respectively.
[0060] S13. Optimize target domain vascular features using prototype contrastive learning.
[0061] Prototype contrastive learning is implemented at the end feature layer of the decoder of the model to be adapted. The center line of the newly added blood vessel segment, the voxels inside the blood vessel segment, and the voxels near the blood vessel boundary, which are manually confirmed, are used as positive sample anchors. The noise segment and the high-confidence difficult background voxels, which are manually confirmed, are used as negative sample anchors. For positive sample anchors, their features are constrained to be close to the source domain blood vessel prototype and the target domain blood vessel memory prototype, and far away from the background prototype and the noise memory prototype. For negative sample anchors, their features are constrained to be close to the background prototype or the noise memory prototype, and far away from the blood vessel prototype. The prototype contrastive loss adopts InfoNCE loss, triplet loss, center loss, or classification loss based on prototype distance.
[0062] S14. Utilize output interval loss to enhance the decision boundary for newly added blood vessels.
[0063] For newly identified blood vessel regions confirmed manually, calculate the difference between the logit of the blood vessel category output by the current brain blood vessel segmentation model to be adapted and the logit of the background category, and require that this difference at least reaches a preset interval. The output interval loss is:
[0064]
[0065] in, Newly identified vascular areas (confirmed manually) For preset intervals, The output score is for the blood vessel category. Output scores for the background category;
[0066] S15. Apply tubular topology and seed connectivity constraints to the uncertain region.
[0067] For uncertain regions with a label value of -1, instead of directly designating them as vessels or background, structural constraints are imposed on the model-generated foreground predictions. First, a mask of non-tubular regions is constructed based on local Frangi response, Hessian features, or differentiable tubularity evaluation. This penalizes sheet-like predictions that lack tubular structural support but exhibit high vessel probabilities. Second, credible seeds are selected from credible initial vessels and manually confirmed vessels. Iterative propagation, geodesic connectivity analysis, or differentiable morphological expansion are performed on the predicted vessel probability map to obtain reachable regions that can be connected to credible seeds via high vessel probability paths. Seed connectivity loss is applied to isolated foreground regions that cannot be connected to credible seeds via high vessel probability paths. Subsequently, tubular loss Connection loss with seed Weighted combination to form the overall tubular topology constraint loss :
[0068]
[0069]
[0070] in, Indicates the position of a voxel; This indicates the predicted voxels of the current brain vessel segmentation model to be adapted. The probability of belonging to the vascular category; This represents the set of trusted seeds selected from trusted initial vessels and manually confirmed vessels; Voxel representation Relative to the set of trustworthy seeds The reachability function when voxels A value of 1 is assigned if the path can be connected to any trusted seed via a high-probability blood vessel path; otherwise, a value of 0 is assigned. This indicates summation of voxels over an uncertain region or a region with pre-defined constraints. This represents a positive integer to prevent the denominator from being zero. and These represent the non-negative weighting coefficients for tubular loss and seed connectivity loss, respectively.
[0071] S16, Jointly Optimized Target Domain Cerebral Blood Vessel Segmentation Model
[0072] The total loss function for adapting the target domain cerebral blood vessel segmentation model is:
[0073]
[0074] The total loss consists of the basic segmentation loss. Prototype contrast loss Output interval loss and tubular topology constraint loss Weighted composition, , , These represent the weighting coefficients for prototype contrast loss, output interval loss, and tubular topology constraint loss, respectively.
[0075] S17. Iteratively update candidate vessel segments, supervision labels, and model.
[0076] After completing one round of target domain adaptation, the updated model is used to re-infer the target domain image. The new segmentation results are compared with the blood vessel enhancement results, and candidate blood vessel segments that have not yet been identified are extracted again. They are scored and filtered based on feature value, topological stability, connectivity value, and similarity of the memory bank. A small number of high-value candidate segments that cannot be automatically judged are manually confirmed, and the blood vessel labels, background labels, uncertain regions, blood vessel memory bank, noise memory bank, and model parameters are updated.
[0077] Repeat the process of candidate generation, vessel segmentation, joint scoring, memory filtering, manual verification, and model training until the number of newly added high-value candidate vessel segments falls below a preset threshold, the validation performance no longer improves, the manual annotation budget is exhausted, or the segmentation results meet the preset analysis requirements.
[0078] Furthermore, in step S3, candidate regions that are directly connected to the initial blood vessel, are less than a preset threshold distance from the initial blood vessel, or can continue the direction of the existing blood vessel are preferentially retained.
[0079] Furthermore, the perturbation in step S6 includes one or more of the following: adjusting the enhancement threshold, adjusting the scale parameter, adding slight Gaussian noise, implementing intensity scaling or offset, small-angle rotation, translation, scale change, and adjusting morphological post-processing parameters.
[0080] Furthermore, in step S10, regions with a Frangi response less than 0.01 and an original image intensity less than 500 are designated as high-confidence backgrounds.
[0081] Compared with existing technologies, the cross-domain cerebral vascular segmentation method based on vascular enhancement and active learning provided by this invention has the following beneficial effects: 1) This invention does not rely on model prediction uncertainty as a necessary condition for discovering missed segmented vessels. It utilizes vascular enhancement results that do not depend on the prediction probability of the segmentation model to discover real vessels in the target domain that are judged as background with high confidence by the pre-trained model, thus overcoming the deficiency of traditional uncertainty active learning in failing to discover missed segmented vessels with prediction probabilities close to 0; 2) By filtering noise in vascular enhancement results through vascular segment-level feature analysis and topological stability analysis, the proportion of real vessels in the candidates to be examined can be increased compared to examining the entire enhanced region; 3) Using vascular segments as the unit of active learning and manual confirmation, the annotator only needs to confirm or locally correct a small number of high-value vascular segments, without needing to completely delineate them. 4) By reusing historical annotation knowledge using vascular feature memory and noise feature memory, repeated manual judgment of similar blood vessels and similar noise can be reduced; 5) Three-state supervision of blood vessels, background and uncertain regions is adopted to prevent unconfirmed regions from being directly regarded as background, thus preventing false labels from being missed and causing erroneous suppression of potential real blood vessels; 6) Through joint optimization of Dice, cross-entropy, clDice, prototype comparison, output interval and tubular topology constraints, the problems of overlapping blood vessel regions, fine blood vessel recognition, centerline continuity, target domain feature adaptation and isolated false positives can be improved simultaneously; 7) By gradually supplementing blood vessel samples that best reflect the differences in target domain features through multiple rounds of active learning, the segmentation accuracy and applicability of the model on target domain TOF-MRA images can be improved while reducing the cost of manual annotation. Detailed Implementation
[0082] To make the technical means, creative features, objectives and effects of this invention easier to understand, the invention is further described below.
[0083] This invention provides a cross-domain cerebral blood vessel segmentation method based on vascular enhancement and active learning, comprising the following steps:
[0084] S1. Constructing an initial cerebral blood vessel segmentation model and source domain feature prototype.
[0085] An initial cerebral blood vessel segmentation model is trained using one or more source domain cerebral blood vessel datasets. This model can be a CESAR cerebral blood vessel segmentation network, or other two-dimensional or three-dimensional cerebral blood vessel segmentation networks. Source domain images with blood vessel annotations are input into the model, and feature maps from the terminal feature layer of the model's decoder are extracted. The features of the source domain vascular region and the source domain background region are statistically analyzed to construct a source domain vascular feature prototype. and source domain background feature prototype :
[0086]
[0087]
[0088] in, and These represent the number of source domain vascular voxels and the number of background voxels, respectively, which are included in the statistics. Indicates the first Decoder feature vectors corresponding to each source domain vascular voxel. Indicates the first The decoder feature vectors corresponding to the source domain background voxels; in addition to using a single average prototype, multiple vessel sub-prototypes and background sub-prototypes can be established through clustering to represent different vessel diameters, different bifurcation morphologies and different background types.
[0089] S2. Obtain the initial cerebral blood vessel segmentation results of the target domain.
[0090] The target domain TOF-MRA image undergoes orientation unification, spatial resampling, intensity normalization, brain region cropping, or brain region masking. The processed image is then input into an initial brain vessel segmentation model to obtain the vessel prediction probability for each voxel. The obtained vessel prediction probabilities are thresholded according to a preset threshold to obtain an initial brain vessel segmentation mask. Small connected component removal, hole filling, or other morphological post-processing are then performed to obtain the initial brain vessel segmentation result for the target domain. The post-processed initial brain vessel segmentation mask represents the target domain vessels that the model can currently identify and serves as the basis for subsequent candidate extraction and reliable vessel seed construction.
[0091] S3. Utilize multi-scale vascular enhancement to generate potential candidate regions for missed segmentation.
[0092] Multi-scale Frangi vascular enhancement is performed on the target domain TOF-MRA image. By calculating the eigenvalues of the local Hessian matrix at different scales and their combinations, a vascular enhancement response map is obtained. The maximum value or weighted fusion of responses at multiple scales in the vascular enhancement response map is taken, and a coarse vascular segmentation result is obtained based on a preset response threshold. The coarse vascular segmentation result is then compared with the initial brain vascular segmentation result to extract regions present in the vascular enhancement structure but not in the initial segmentation result, forming potential missed segmentation candidate regions.
[0093]
[0094] Among them, the first set This represents the binary region obtained from vascular enhancement, the second set. This represents the initial cerebral blood vessel segmentation result, and the difference between the two represents potential candidate regions that were missed during segmentation. As a specific embodiment, candidate regions that are directly connected to the initial blood vessel, whose distance from the initial blood vessel is less than a preset threshold, or that can continue the direction of the existing blood vessel can be prioritized. This can reduce the probability of isolated noise structures being mistakenly included in false labels, improve the authenticity and reliability of candidate blood vessel regions, and reduce the workload of subsequent manual inspection and correction. The blood vessel enhancement results are only used to generate candidates and are not directly used as the whole as the true label.
[0095] S4. Convert the candidate region into a vascular map and define vascular segments.
[0096] Three-dimensional centerlines are extracted from the coarse segmentation results of blood vessels or potential unsegmented candidate regions, and the centerlines are converted into a blood vessel map structure.
[0097]
[0098] in, Represents the structure of a blood vessel diagram. Represents the set of nodes along the center line. This represents the set of connecting edges between adjacent centralline nodes. Endpoints, ordinary connecting points, and bifurcation points are identified based on the number of adjacencies of centralline voxels within the 3D neighborhood. Points with one adjacent centralline node are defined as endpoints, and points with three or more adjacent centralline nodes are defined as bifurcation points. Using endpoints and bifurcation points as breakpoints, a continuous centralline path with no other bifurcation points between adjacent endpoints and bifurcation points is defined as a vascular segment. For multiple adjacent bifurcation voxels, they are first merged into one bifurcation node. For closed loop structures, breakpoints are set at the point of maximum curvature, the point of minimum response, or a preset location. For each vascular segment, the centralline, centralline neighborhood, length, average diameter, average enhanced response, endpoint location, bifurcation relationship, and spatial location are recorded, and candidate segments with excessively short centralline lengths, excessively low responses, or located outside of ineffective brain regions are removed.
[0099] In this invention, the active learning query and manual confirmation unit is the blood vessel segment, rather than a single voxel or a fixed image block unrelated to the blood vessel structure.
[0100] S5. Calculate the eigenvalue score of candidate vessel segments.
[0101] The target domain image is input into the initial cerebral blood vessel segmentation model, and the terminal feature map of the decoder is extracted. For each candidate blood vessel segment, feature sampling is performed within its centerline and a tubular neighborhood of a preset radius around the centerline. The blood vessel segment-level feature vector is obtained through average pooling, max pooling, attention pooling, or a combination thereof. The distance between the blood vessel segment-level feature vector of the candidate blood vessel segment and the source domain blood vessel feature prototype and the source domain background feature prototype are calculated respectively.
[0102] ,
[0103] in, Indicates the current candidate vessel segment. Indicates candidate vessel segment The vascular segment-level feature vector This is a prototype of source domain vascular features. As the prototype of the source domain background features, This represents the feature distance calculation function. and These represent candidate vessel segments. Distance to the source domain vessel feature prototype and the source domain background feature prototype. Candidate vessel segment. Two requirements must be met simultaneously: first, its features should not highly overlap with the source domain background and should have a certain vascular tendency; second, its features should differ from the existing vascular distribution in the source domain, reflecting the vascular performance of the target domain that the model has not yet fully learned. The feature value score of candidate vessel segments is calculated as follows:
[0104]
[0105] ,
[0106] Among them, the feature value score is determined by the vascularity of the candidate segment. And domain offset degree Together, we determined that the vascular tendency Based on candidate vessel segments Blood vessel segment-level feature vector Calculation of the relative distance between the blood vessel prototype and the background prototype, and the degree of domain offset. Based on candidate vessel segments Blood vessel segment-level feature vector Calculation of the degree of offset from the source domain blood vessel distribution, normalization operation Used to standardize dimensions. To prevent constants with zero denominators, typical background segments receive lower scores, while candidate segments with vascular tendency that deviate from the source domain's vascular prototype receive higher annotation value.
[0107] S6. Calculate the topological stability score of the candidate vessel segment.
[0108] A slight perturbation that does not significantly alter the actual vascular anatomy is applied to the target domain image or the vascular enhancement process, and vascular enhancement, centerline extraction, and vascular segmentation are re-executed. As a specific embodiment, the perturbation includes one or more of the following: adjusting the enhancement threshold, adjusting scale parameters, adding slight Gaussian noise, implementing intensity scaling or offset, small-angle rotation, translation, scale changes, and adjusting morphological post-processing parameters. This allows for the assessment of the structural stability of candidate vascular segments by comparing changes in the centerline and topology of the vascular segments before and after the perturbation. Unstable vascular segments that are sensitive to slight perturbations and exhibit significant structural changes are preferentially marked as areas requiring manual review, thereby reducing the scope of manual inspection.
[0109] For the original candidate vessel segments, the spatial location, centerline direction, and endpoint relationship of the corresponding vessel segments are searched in each perturbation result. The recurrence rate of candidate vessel segments, the degree of centerline overlap, the changes in length and diameter, the degree of endpoint offset, and whether the connection relationship with adjacent vessels is consistent are statistically analyzed. The topological stability score of the candidate vessel segments is calculated as follows:
[0110]
[0111] The topological stability score is determined by the proportion of candidate vessel segments retained under multiple perturbations. degree of overlap of center lines Stability of connection relationships and the degree of endpoint offset The weighted average is obtained by assigning weights from the first to the fourth. , , , This is used to adjust the contributions of each indicator. Under reasonable perturbation, real vascular segments usually maintain a relatively stable centerline and connectivity, while pseudo-tubular structures formed by noise or tissue edges are more sensitive to parameter changes.
[0112] S7. Combined scoring and selection of the vessel segment to be examined.
[0113] The overall active learning score is calculated based on the feature value score and topological stability score of the candidate vessel segment:
[0114]
[0115] Among them, the comprehensive active learning score is composed of the feature value score. and topological stability score We get the weighted average. The weights of the feature value scores, The weights are assigned to the topological stability score; candidates are ranked according to their comprehensive scores, and highly similar duplicate candidate segments are removed through feature clustering, spatial overlap suppression, or farthest point sampling. The prediction probability of the initial model is not a necessary condition for candidate selection. Even if the blood vessel prediction probability of a candidate segment is close to 0, it can still be selected as a high-value candidate as long as it has high blood vessel enhancement response, feature value, and topological stability.
[0116] S8. Manually confirm and locally correct candidate vessel segments.
[0117] The cerebral vascular analysis software displays the original image of the target domain, initial segmentation results, vascular enhancement response, centerlines of candidate vascular segments, local 3D regions of candidate segments, and their connectivity with existing vessels to the annotators. Annotators then identify candidate segments as real vessels, as non-vascular noise, correct their endpoints or local areas, identify some sub-segments as vessels and the rest as background, or leave them as uncertain regions. This eliminates the need for manual redrawing of the complete 3D cerebral vascular system layer by layer.
[0118] S9. Establish a vascular feature memory database and a noise feature memory database.
[0119] Manually verified features of real blood vessel segments are stored in a blood vessel feature memory, while manually verified features of non-blood vessel noise segments are stored in a noise feature memory. The memory can store blood vessel segment feature vectors or representative features through clustering, fixed-length queues, moving averages, or prototype updates. For subsequent candidate blood vessel segments, the maximum similarity between them and both the blood vessel feature memory and the noise feature memory is calculated.
[0120] ,
[0121] in, The maximum similarity between the candidate vessel segment and the vascular feature memory database. The maximum similarity between the candidate vessel segment and the noise feature memory. Candidate vessel segment The vascular segment-level feature vector For vascular feature memory bank The actual blood vessel segments in the middle, noise feature memory The process involves identifying non-vascular noise segments within a vascular feature memory. When the maximum similarity of a candidate vascular segment to the vascular feature memory is higher than a first threshold and significantly higher than its maximum similarity to the noise feature memory, the candidate vascular segment is automatically retained as a high-confidence vessel or its manual inspection priority is reduced. Conversely, when the maximum similarity of a candidate vascular segment to the noisy vascular memory is higher than a second threshold and significantly higher, it is automatically filtered as high-confidence noise. Only candidate vascular segments that cannot be reliably identified by either memory are submitted for manual inspection. This reuse of historical manual verification knowledge reduces redundant labeling of similar vessels and similar noise.
[0122] S10. Construct three-state supervised labels for blood vessels, background, and uncertain regions.
[0123] Based on the initial segmentation results, manual confirmation results, vascular enhancement response, and image intensity, a three-state supervised label is constructed. The post-processed reliable initial blood vessels, manually confirmed newly added blood vessels, and blood vessel regions determined with high confidence by the vascular feature memory are labeled as 1. Manually confirmed noise regions and high-confidence backgrounds that simultaneously meet the conditions of low vascular enhancement response and low image intensity are labeled as 0. Other regions that cannot be reliably determined are labeled as −1, as detailed below:
[0124]
[0125] In the formula, the three regions represent reliable vascular regions in sequence. Trustworthy background area and uncertain regions As a specific embodiment, regions with a Frangi response less than 0.01 and an original image intensity less than 500 can be considered as high-confidence backgrounds; where 0.01 is the Frangi low response threshold used to determine high-confidence backgrounds, and 500 is the low intensity threshold of the original image. Both thresholds can be adjusted according to the image normalization method, scanning parameters, and the target domain image intensity range. Uncertain regions are not directly used as backgrounds in general supervision to avoid mistakenly suppressing undiscovered real blood vessels as background.
[0126] S11. Use blood vessel segments as the query unit and three-dimensional sub-blocks as the training unit.
[0127] Active learning and manual annotation are performed on a segment-by-segment basis, but model training still takes 3D image sub-blocks as input. For each confirmed segment, multiple spatially overlapping 3D sub-blocks are extracted along the centerline, so that the sub-blocks simultaneously contain the target segment, adjacent vessels, surrounding tissues, and necessary background context.
[0128] Each training batch simultaneously includes newly confirmed vessel segment blocks from the current round, confirmed noise segments from the current round, replay blocks from previous rounds, existing reliable vessel context blocks, and random blocks from the target domain. Through multi-source joint sampling, it avoids insufficient information and overfitting caused by training with only a small number of blocks from a single vessel segment, and enables vessel segment-level query results to be transformed into training data with sufficient context and sample diversity.
[0129] S12. Calculate the basic segmentation loss in the clearly marked area.
[0130] Define regions with label values not equal to -1 as explicitly supervised regions:
[0131]
[0132] Dice loss, cross-entropy loss (CE), and clDice loss are calculated only within explicitly supervised regions. Uncertain regions do not participate in the corresponding direct classification supervision. The basic segmentation loss is:
[0133]
[0134] in, , , These represent the non-negative weight coefficients of the Dice loss, cross-entropy loss (CE), and clDice loss, respectively, used to adjust the relative contributions of the three losses to the basic segmentation loss. Specifically:
[0135] Dice loss is used to alleviate the class imbalance between vascular voxels and background voxels, improve the overall overlap between the predicted vascular region and the supervised vascular region, and prevent the model from obtaining a low loss by predicting a large amount of background.
[0136] Cross-entropy loss (CE) is used to provide stable classification supervision for each clearly labeled voxel, improve vessel boundaries, reduce false positives in the background, and compensate for the Dice loss's insensitivity to local voxel errors.
[0137] clDice loss uses soft skeletonization to compare the centerline structure of predicted and supervised blood vessels, which can reduce capillary breakage, maintain the continuity of long blood vessels, and enhance the dendritic topology.
[0138] S13. Optimize target domain vascular features using prototype contrastive learning.
[0139] Prototype contrastive learning is implemented at the final feature layer of the decoder of the model to be adapted. Manually confirmed new vessel segment centerlines, voxels within vessel segments, and voxels near vessel boundaries are used as positive sample anchors, while manually confirmed noise segments and high-confidence, difficult background voxels are used as negative sample anchors. For positive sample anchors, their features are constrained to be close to the source domain vessel prototype and the target domain vessel memory prototype, and far from the background prototype and noise memory prototype. For negative sample anchors, their features are constrained to be close to the background prototype or noise memory prototype, and far from the vessel prototype. The prototype contrastive loss can be InfoNCE loss, triplet loss, center loss, or classification loss based on prototype distance.
[0140] The prototype contrastive loss directly optimizes the decoder feature distribution, enabling target domain vessels that initially deviated from the source domain vessel features and were missed by the initial model to gradually form clear vessel representations. After feature optimization, other real vessels in uncertain regions that are similar to the confirmed target domain vessel features can be identified by the updated model, even if they are not directly labeled.
[0141] S14. Utilize output interval loss to enhance the decision boundary for newly added blood vessels.
[0142] For newly identified blood vessel regions confirmed manually, calculate the difference between the logit of the blood vessel category output by the current brain blood vessel segmentation model to be adapted and the logit of the background category, and require that this difference at least reaches a preset interval. The output interval loss is:
[0143]
[0144] in, Newly identified vascular areas (confirmed manually) As a preset interval, in one embodiment Take 1.0, The output score is for the blood vessel category. The output score for the background category. The output interval loss. This not only requires newly added regions to be classified as blood vessels, but also requires that the blood vessel score be significantly higher than the background score, reducing the likelihood of small blood vessels disappearing again due to threshold changes or subsequent model updates. The prototype contrast loss is constrained by the feature space, and the output interval loss is constrained by the final decision boundary.
[0145] S15. Apply tubular topology and seed connectivity constraints to the uncertain region.
[0146] For uncertain regions with a label value of -1, instead of directly designating them as vessels or background, structural constraints are imposed on the model-generated foreground predictions. First, a non-tubular region mask is constructed based on local Frangi response, Hessian features, or differentiable tubularity evaluation. This penalizes sheet-like predictions with high vessel probabilities that lack tubular structural support. Second, credible seeds are selected from credible initial vessels and manually confirmed vessels. Iterative propagation, geodesic connectivity analysis, or differentiable morphological expansion are performed on the predicted vessel probability map to obtain reachable regions that can be connected to credible seeds via high vessel probability paths. Seed connectivity loss is applied to isolated foreground regions that cannot be connected to credible seeds via high vessel probability paths. Subsequently, tubular loss Connection loss with seed Weighted combination to form the overall tubular topology constraint loss :
[0147]
[0148]
[0149] in, Indicates the position of a voxel; This indicates the predicted voxels of the current brain vessel segmentation model to be adapted. The probability of belonging to the vascular category; This represents the set of trusted seeds selected from trusted initial vessels and manually confirmed vessels; Voxel representation Relative to the set of trustworthy seeds The reachability function when voxels A value of 1 is assigned if the path can be connected to any trusted seed via a high-probability blood vessel path; otherwise, a value of 0 is assigned. This indicates summation of voxels over an uncertain region or a region with pre-defined constraints. This represents a positive integer to prevent the denominator from being zero. and These represent the non-negative weighting coefficients of the tubularity loss and seed connectivity loss, respectively; tubularity loss Used to suppress predictions that clearly do not conform to tubular morphology. Tubular topology constraints do not require uncertain regions to be completely consistent with the current pseudo-labels, but only require that the newly discovered foreground of the model has basic tubular structures and vascular connectivity, thereby reducing patchy false positives and small isolated fragments while preserving the potential unsegmented vascular learning space. Seed connectivity constraints can be selectively enabled depending on the specific application.
[0150] S16, Jointly Optimized Target Domain Cerebral Blood Vessel Segmentation Model
[0151] The total loss function for adapting the target domain cerebral blood vessel segmentation model is:
[0152]
[0153] The total loss consists of the basic segmentation loss. Prototype contrast loss Output interval loss and tubular topology constraint loss Weighted composition, , , These represent the weight coefficients of the prototype contrast loss, output margin loss, and tubular topology constraint loss, respectively. The weights of each loss can be dynamically adjusted based on the target domain sample size, pseudo-label reliability, and training stage. Specifically, in the early stages of training, the weights of Dice loss and cross-entropy loss can be increased; in the later stages of training, the weights of prototype contrast, clDice, and tubular topology constraint can be gradually increased.
[0154] S17. Iteratively update candidate vessel segments, supervision labels, and model.
[0155] After completing one round of target domain adaptation, the updated model is used to re-infer the target domain image. The new segmentation results are compared with the blood vessel enhancement results, and candidate blood vessel segments that have not yet been identified are extracted again. They are scored and filtered based on feature value, topological stability, connectivity value, and similarity of the memory bank. A small number of high-value candidate segments that cannot be automatically judged are manually confirmed, and the blood vessel labels, background labels, uncertain regions, blood vessel memory bank, noise memory bank, and model parameters are updated.
[0156] Repeat the process of candidate generation, vessel segmentation, joint scoring, memory filtering, manual verification, and model training until the number of newly added high-value candidate vessel segments falls below a preset threshold, the validation performance no longer improves, the manual annotation budget is exhausted, or the segmentation results meet the preset analysis requirements.
[0157] To better understand the cross-domain cerebral blood vessel segmentation method based on blood vessel enhancement and active learning provided by this invention, the following will be described in conjunction with specific embodiments.
[0158] Example 1: Active Adaptation Process of Target Domain Based on CESAR Initial Model
[0159] Using 3D TOF-MRA images as the target domain data, a CESAR network trained on multiple source domain cerebral vascular datasets was used as the initial cerebral vascular segmentation model. First, the target domain images were subjected to orientation unification, resampling, brain region cropping, and intensity normalization. Then, the images were input into the CESAR network, and an initial vascular mask was obtained using 0.5 as the example segmentation threshold. Small connected regions with a voxel count lower than the preset threshold were removed.
[0160] The multi-scale Frangi algorithm is used to process images of the same target domain. The scale set can be set to 0.5, 1.0, 1.5, 2.0, and 3.0, and can also be adjusted according to the spatial resolution of the target domain and the range of vessel diameters. The maximum value of the multi-scale response is taken and normalized, and a vessel enhancement mask is obtained based on one or more candidate thresholds. The enhancement mask is subtracted from the initial segmentation mask to obtain potential unsegmented candidate regions.
[0161] The candidate region is 3D skeletonized, and the degree of the centerline nodes is counted using 26 neighborhoods or a preset 3D adjacency relationship. The endpoints and the merged bifurcation nodes are used as breakpoints, and the continuous path between them is divided into vascular segments. Candidate segments with a centerline length of less than 10 voxels or an average Frangi response lower than a preset value can be removed; the above values are only examples and do not constitute a limitation on the scope of protection.
[0162] Target domain features are extracted from the last layer of the CESAR decoder. Pooling is performed on the centerline and neighborhood of each candidate vessel segment to obtain vessel segment features. Feature values are calculated based on their relative distances to the source domain vessel prototype and the source domain background prototype. Simultaneously, vessel segments are repeatedly extracted under conditions of fluctuation around the Frangi threshold, scale set changes, and the addition of slight noise. Centerline coincidence, endpoint offset, and connectivity are statistically analyzed to calculate topological stability.
[0163] Candidate vessel segments with high overall scores and no overlap are displayed to the annotators. The annotators then identify these segments as real vessels, noise, or uncertain regions, and can adjust the local endpoints and diameter ranges of the candidate segments. The features of confirmed real vessel segments and noise segments are added to the vessel memory database and noise memory database, respectively. Subsequent candidates are first compared with these two databases; similar noise is automatically filtered out, and similar vessels are automatically retained or have their examination priority reduced.
[0164] Confident initial vessels, newly confirmed vessels, and high-confidence memory-matched vessels are marked as 1; manually confirmed noise and regions with a Frangi response less than 0.01 and an image intensity less than 500 are marked as 0; other regions are marked as -1. The above intensity thresholds apply to the corresponding original image intensity range. If a normalized image is used, the thresholds are re-determined according to the normalization rules.
[0165] Three-dimensional sub-blocks with overlap are extracted along the centerline of the confirmed vessel segment, such as 96×96×96 voxel sub-blocks. In addition to the newly added vessel segment sub-blocks in the current round, the training batch also includes confirmed noise sub-blocks, historical memory replay sub-blocks, existing reliable vessel context sub-blocks, and random target domain sub-blocks to ensure the diversity of training context and samples.
[0166] Calculate Dice loss, cross-entropy loss, and clDice loss in clearly defined regions with label values of 0 and 1; calculate prototype contrast loss in regions with newly identified vessels and difficult backgrounds; calculate logit margin loss in regions with newly identified vessels, with the example interval m set to 1.0; further enable non-tubular prediction penalty and reliable seed connectivity loss in uncertain regions. Adjust the weights of each loss and fine-tune the model according to the training phase.
[0167] After one round of training, the updated model is used to re-infer the target domain data. If the original candidate vessel segments have been stably identified by the model, they are included in the list of trustworthy vessels; new candidates that are still not identified are re-scored, filtered, and manually confirmed. The above process is repeated until the number of newly added high-value candidates is lower than the preset value or the segmentation results meet the usage requirements.
[0168] Example 2: An implementation method for topological stability evaluation
[0169] Multiple sets of Frangi parameters are set for the same target domain image, such as changing the enhancement threshold, scale set, and post-processing minimum connected component threshold, and amplitude-limited Gaussian noise or intensity perturbation is added to the image. Centerline extraction and vessel segmentation are performed independently for each set of results.
[0170] Using the centerline of the original candidate segment as a reference, candidate segments with a distance less than a preset value and consistent direction are searched among the perturbation results. The retention ratio is calculated by dividing the number of successful matches by the total number of perturbations. The consistency of the skeleton is evaluated by the Dice distance of the centerline or the average symmetrical centerline, and the stability of the endpoints is evaluated by the Euclidean distance of the endpoints. It is also determined whether the candidate segments still connect to the same existing blood vessels or bifurcation nodes.
[0171] The above indicators are normalized and weighted to form a topological stability score. Candidate segments that appear only briefly, exhibit significant endpoint drift, or show frequent changes in connectivity are given a lower priority for active learning; candidate segments that are stable under multiple parameters and can continue the existing vascular pathway are given a higher priority for active learning.
[0172] Example 3: An implementation method for memory update and duplicate label suppression
[0173] The vascular feature memory and noise feature memory each use fixed-length queues to store the normalized feature vectors of manually confirmed vascular segments and noise segments, respectively, and record their source images, spatial locations, vascular segment lengths, and confirmation times. When the memory capacity reaches its limit, the earliest features, redundant features most similar to existing prototypes, or multiple duplicate features can be deleted, or cluster centers can be used to replace them.
[0174] For each new candidate segment, calculate its cosine similarity with each feature in the two memory banks. If its maximum similarity with the vascular memory bank exceeds the vascular threshold and its maximum similarity with the noise memory bank is lower than the noise threshold, it is treated as a high-confidence vascular segment; otherwise, it is treated as a high-confidence noise segment. If both are close to or do not reach the threshold, manual inspection is required.
[0175] After manual verification, the new features are written into the corresponding memory, and the vascular prototype or noise prototype can be updated using exponential moving average. As the number of active learning rounds increases, recurring similar noise will be automatically filtered out, and confirmed vessels of the same target domain will be automatically retained, thereby gradually reducing the number of manual inspections.
[0176] Compared with existing technologies, the cross-domain cerebral vascular segmentation method based on vascular enhancement and active learning provided by this invention has the following beneficial effects: 1) This invention does not rely on model prediction uncertainty as a necessary condition for discovering missed segmented vessels. It utilizes vascular enhancement results that do not depend on the prediction probability of the segmentation model to discover real vessels in the target domain that are judged as background with high confidence by the pre-trained model, thus overcoming the deficiency of traditional uncertainty active learning in failing to discover missed segmented vessels with prediction probabilities close to 0; 2) By filtering noise in vascular enhancement results through vascular segment-level feature analysis and topological stability analysis, the proportion of real vessels in the candidates to be examined can be increased compared to examining the entire enhanced region; 3) Using vascular segments as the unit of active learning and manual confirmation, the annotator only needs to confirm or locally correct a small number of high-value vascular segments, without needing to completely delineate them. 4) By reusing historical annotation knowledge using vascular feature memory and noise feature memory, repeated manual judgment of similar blood vessels and similar noise can be reduced; 5) Three-state supervision of blood vessels, background and uncertain regions is adopted to prevent unconfirmed regions from being directly regarded as background, thus preventing false labels from being missed and causing erroneous suppression of potential real blood vessels; 6) Through joint optimization of Dice, cross-entropy, clDice, prototype comparison, output interval and tubular topology constraints, the problems of overlapping blood vessel regions, fine blood vessel recognition, centerline continuity, target domain feature adaptation and isolated false positives can be improved simultaneously; 7) By gradually supplementing blood vessel samples that best reflect the differences in target domain features through multiple rounds of active learning, the segmentation accuracy and applicability of the model on target domain TOF-MRA images can be improved while reducing the cost of manual annotation.
[0177] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention and are not intended to limit it. Although the present invention has been described in detail with reference to preferred embodiments, those skilled in the art should understand that modifications or equivalent substitutions can be made to the technical solutions of the present invention without departing from the spirit and scope of the technical solutions of the present invention, and all such modifications or substitutions should be covered within the scope of the claims of the present invention.
Claims
1. A cross-domain cerebral blood vessel segmentation method based on vascular enhancement and active learning, characterized in that, Includes the following steps: S1. Constructing an initial cerebral blood vessel segmentation model and source domain feature prototype. An initial cerebral blood vessel segmentation model is trained using one or more source domain cerebral blood vessel datasets. Source domain images with blood vessel annotations are input into the model, and feature maps from the terminal feature layer of the model decoder are extracted. Features of the source domain vascular region and the source domain background region are statistically analyzed to construct a prototype of source domain vascular features. and source domain background feature prototype : in, and These represent the number of source domain vascular voxels and the number of background voxels, respectively, which are included in the statistics. Indicates the first Decoder feature vectors corresponding to each source domain vascular voxel. Indicates the first Decoder feature vectors corresponding to each source domain background voxel; S2. Obtain the initial cerebral blood vessel segmentation results of the target domain. The target domain TOF-MRA image is processed by orientation unification, spatial resampling, intensity normalization, brain region cropping or brain region masking, and the processed image is input into the initial brain blood vessel segmentation model to obtain the blood vessel prediction probability of each voxel; the obtained blood vessel prediction probability is thresholded according to a preset threshold to obtain the initial brain blood vessel segmentation mask, and small connected component removal and hole filling morphological post-processing are performed to obtain the initial brain blood vessel segmentation result of the target domain; S3. Utilize multi-scale vascular enhancement to generate potential candidate regions for missed segmentation. Multi-scale Frangi vascular enhancement is performed on the target domain TOF-MRA image. By calculating the eigenvalues of the local Hessian matrix at different scales and their combinations, a vascular enhancement response map is obtained. The maximum value or weighted fusion of responses at multiple scales in the vascular enhancement response map is taken, and a coarse vascular segmentation result is obtained based on a preset response threshold. The coarse vascular segmentation result is then compared with the initial brain vascular segmentation result to extract regions present in the vascular enhancement structure but not in the initial segmentation result, forming potential missed segmentation candidate regions. Among them, the first set This represents the binary region obtained from vascular enhancement, the second set. This represents the initial cerebral blood vessel segmentation result, and the difference between the two represents potential candidate regions that were missed during segmentation. ; S4. Convert the candidate region into a vascular map and define vascular segments. Three-dimensional centerlines are extracted from the coarse segmentation results of blood vessels or potential unsegmented candidate regions, and the centerlines are converted into a blood vessel map structure. in, Represents the structure of a blood vessel diagram. Represents the set of nodes along the center line. This represents the set of connecting edges between adjacent centralline nodes; endpoints, ordinary connecting points, and bifurcation points are identified based on the number of adjacencies of centralline voxels in the 3D neighborhood; a point with one adjacent centralline node is defined as an endpoint, and a point with three or more adjacent centralline nodes is defined as a bifurcation point; using endpoints and bifurcation points as break points, a continuous centralline path with no other bifurcation points between adjacent endpoints and bifurcation points is defined as a vascular segment; for multiple adjacent bifurcation voxels, they are first merged into one bifurcation node; for closed loop structures, break points are set at the point of maximum curvature, the point of minimum response, or a preset position; for each vascular segment, the centralline, centralline neighborhood, length, average diameter, average enhanced response, endpoint position, bifurcation relationship, and spatial position are recorded, and candidate segments with excessively short centralline lengths, excessively low responses, or located outside of ineffective brain regions are removed; S5. Calculate the eigenvalue score of candidate vessel segments. The target domain image is input into the initial cerebral blood vessel segmentation model, and the terminal feature map of the decoder is extracted. For each candidate blood vessel segment, feature sampling is performed within its centerline and a tubular neighborhood of a preset radius around the centerline. The blood vessel segment-level feature vector is obtained through average pooling, max pooling, attention pooling, or a combination thereof. The distance between the blood vessel segment-level feature vector of the candidate blood vessel segment and the source domain blood vessel feature prototype and the source domain background feature prototype are calculated respectively. , in, Indicates the current candidate vessel segment. Indicates candidate vessel segment The vascular segment-level feature vector This is a prototype of source domain vascular features. As the prototype of the source domain background features, This represents the feature distance calculation function. and These represent candidate vessel segments. Distance to source domain vessel feature prototypes and source domain background feature prototypes; candidate vessel segments Two requirements must be met simultaneously: first, its features should not highly overlap with the source domain background and should have a certain vascular tendency; second, its features should differ from the existing vascular distribution in the source domain and be able to reflect the vascular performance of the target domain that the model has not yet fully learned; the feature value score of the candidate vascular segment is calculated as follows: , Among them, the feature value score is determined by the vascularity of the candidate segment. And domain offset degree Together, we determined that the vascular tendency Based on candidate vessel segments Blood vessel segment-level feature vector Calculation of the relative distance between the blood vessel prototype and the background prototype, and the degree of domain offset. Based on candidate vessel segments Blood vessel segment-level feature vector Calculation of the degree of offset from the source domain blood vessel distribution, normalization operation Used to standardize dimensions. To prevent constants with a denominator of zero; S6. Calculate the topological stability score of the candidate vessel segment. A slight perturbation that does not significantly alter the actual vascular anatomy is applied to the target domain image or the vessel enhancement process, and vessel enhancement, centerline extraction, and vessel segmentation are re-executed. For the original candidate vessel segments, vessel segments corresponding to spatial location, centerline direction, and endpoint relationships are searched in each perturbation result. The recurrence rate of candidate vessel segments, the degree of centerline overlap, changes in length and diameter, the degree of endpoint offset, and the consistency of connectivity with adjacent vessels are statistically analyzed. The topological stability score of the candidate vessel segments is calculated as follows: The topological stability score is determined by the proportion of candidate vessel segments retained under multiple perturbations. degree of overlap of center lines Stability of connection relationships and the degree of endpoint offset The weighted average is obtained by assigning weights from the first to the fourth. , , , Used to adjust the contribution of each indicator accordingly; S7. Combined scoring and selection of the vessel segment to be examined. The overall active learning score is calculated based on the feature value score and topological stability score of the candidate vessel segment: Among them, the comprehensive active learning score is composed of the feature value score. and topological stability score We get the weighted average. The weights of the feature value scores, The weights are assigned to the topological stability scores. The segments are sorted according to their comprehensive scores, and highly similar duplicate candidate segments are removed by feature clustering, spatial overlap suppression, or farthest point sampling. The prediction probability of the initial model is not a necessary condition for candidate selection. Even if the blood vessel prediction probability of a candidate segment is close to 0, it can still be selected as a high-value candidate as long as it has high blood vessel enhancement response, feature value, and topological stability. S8. Manually confirm and locally correct candidate vessel segments. The cerebrovascular analysis software displays the original image of the target domain, the initial segmentation results, the enhanced vascular response, the center line of the candidate vascular segment, the local 3D region of the candidate segment and its connection relationship with existing blood vessels to the annotators; the annotators confirm the candidate segment as a real blood vessel, as non-vascular noise, correct its endpoints or local range, confirm some sub-segments as blood vessels and the rest as background, or retain it as an uncertain region; S9. Establish a vascular feature memory database and a noise feature memory database. Manually verified features of real blood vessel segments are stored in a blood vessel feature memory database, and manually verified features of non-blood vessel noise segments are stored in a noise feature memory database. For subsequent candidate blood vessel segments, the maximum similarity between them and both the blood vessel feature memory database and the noise feature memory database is calculated. , in, The maximum similarity between the candidate vessel segment and the vascular feature memory database. The maximum similarity between the candidate vessel segment and the noise feature memory. Candidate vessel segment The vascular segment-level feature vector For vascular feature memory bank The actual blood vessel segments in the middle, noise feature memory The non-vascular noise segment is selected; when the maximum similarity of a candidate vascular segment with the vascular feature memory is higher than the first threshold and significantly higher than its maximum similarity with the noise feature memory, the candidate vascular segment is automatically retained as a high-confidence vessel or its priority for manual inspection is reduced; conversely, when the maximum similarity of a candidate vascular segment with the noise vascular memory is higher than the second threshold and has a significant advantage, it is automatically filtered as high-confidence noise; only candidate vascular segments that cannot be reliably judged by either memory are submitted for manual inspection. S10. Construct three-state supervised labels for blood vessels, background, and uncertain regions. Based on the initial segmentation results, manual confirmation results, vascular enhancement response, and image intensity, a three-state supervised label is constructed. The post-processed reliable initial blood vessels, manually confirmed newly added blood vessels, and blood vessel regions determined with high confidence by the vascular feature memory are labeled as 1. Manually confirmed noise regions and high-confidence backgrounds that simultaneously meet the conditions of low vascular enhancement response and low image intensity are labeled as 0. Other regions that cannot be reliably determined are labeled as −1, as detailed below: In the formula, the three regions represent reliable vascular regions in sequence. Trustworthy background area and uncertain regions ; S11. Use blood vessel segments as the query unit and three-dimensional sub-blocks as the training unit. Active learning and manual annotation are performed on a segment-by-segment basis, but model training still takes 3D image sub-blocks as input. For each confirmed segment, multiple spatially overlapping 3D sub-blocks are extracted along the centerline, so that the sub-blocks simultaneously contain the target segment, adjacent vessels, surrounding tissues, and necessary background context. Each training batch simultaneously contains sub-blocks of newly confirmed segments in the current round, sub-blocks of confirmed noisy segments in the current round, sub-blocks of replays from previous rounds, sub-blocks of existing reliable vascular context, and random sub-blocks of the target domain. S12. Calculate the basic segmentation loss in the clearly marked area. Define regions with label values not equal to -1 as explicitly supervised regions: Dice loss, cross-entropy loss (CE), and clDice loss are calculated only within explicitly supervised regions. Uncertain regions do not participate in the corresponding direct classification supervision. The basic segmentation loss is: in, , , These represent the non-negative weight coefficients of Dice loss, cross-entropy loss CE, and clDice loss, respectively. S13. Optimize target domain vascular features using prototype contrastive learning. Prototype contrastive learning is implemented at the end feature layer of the decoder of the model to be adapted. The center line of the newly added blood vessel segment, the voxels inside the blood vessel segment, and the voxels near the blood vessel boundary, which are manually confirmed, are used as positive sample anchors. The noise segment and the high-confidence difficult background voxels, which are manually confirmed, are used as negative sample anchors. For positive sample anchors, their features are constrained to be close to the source domain blood vessel prototype and the target domain blood vessel memory prototype, and far away from the background prototype and the noise memory prototype. For negative sample anchors, their features are constrained to be close to the background prototype or the noise memory prototype, and far away from the blood vessel prototype. The prototype contrastive loss adopts InfoNCE loss, triplet loss, center loss, or classification loss based on prototype distance. S14. Utilize output interval loss to enhance the decision boundary for newly added blood vessels. For newly identified blood vessel regions confirmed manually, calculate the difference between the blood vessel category logit and the background category logit output by the current brain blood vessel segmentation model to be adapted, and require that this difference at least reaches a preset interval. The output interval loss is: in, Newly identified vascular areas (confirmed manually) For preset intervals, The output score is for the blood vessel category. Output scores for the background category; S15. Apply tubular topology and seed connectivity constraints to the uncertain region. For uncertain regions with a label value of -1, instead of directly designating them as vessels or background, structural constraints are imposed on the model-generated foreground predictions. First, a mask of non-tubular regions is constructed based on local Frangi response, Hessian features, or differentiable tubularity evaluation. This penalizes sheet-like predictions that lack tubular structural support but exhibit high vessel probabilities. Second, credible seeds are selected from credible initial vessels and manually confirmed vessels. Iterative propagation, geodesic connectivity analysis, or differentiable morphological expansion are performed on the predicted vessel probability map to obtain reachable regions that can be connected to credible seeds via high vessel probability paths. Seed connectivity loss is applied to isolated foreground regions that cannot be connected to credible seeds via high vessel probability paths. Subsequently, tubular loss Connection loss with seed Weighted combination to form the overall tubular topology constraint loss : in, Indicates the position of a voxel; This indicates the predicted voxels of the current brain vessel segmentation model to be adapted. The probability of belonging to the vascular category; This represents the set of trusted seeds selected from trusted initial vessels and manually confirmed vessels; Voxel representation Relative to the set of trustworthy seeds The reachability function when voxels A value of 1 is assigned if the path can be connected to any trusted seed via a high-probability blood vessel path; otherwise, a value of 0 is assigned. This indicates summation of voxels over an uncertain region or a region with pre-defined constraints. This represents a positive integer to prevent the denominator from being zero. and These represent the non-negative weighting coefficients for tubular loss and seed connectivity loss, respectively. S16, Jointly Optimized Target Domain Cerebral Blood Vessel Segmentation Model The total loss function for adapting the target domain cerebral blood vessel segmentation model is: The total loss consists of the basic segmentation loss. Prototype contrast loss Output interval loss and tubular topology constraint loss Weighted composition, , , These represent the weighting coefficients for prototype contrast loss, output interval loss, and tubular topology constraint loss, respectively. S17. Iteratively update candidate vessel segments, supervision labels, and model. After completing one round of target domain adaptation, the updated model is used to re-infer the target domain image. The new segmentation results are compared with the blood vessel enhancement results, and candidate blood vessel segments that have not yet been identified are extracted again. They are scored and filtered based on feature value, topological stability, connectivity value, and similarity of the memory bank. A small number of high-value candidate segments that cannot be automatically judged are manually confirmed, and the blood vessel labels, background labels, uncertain regions, blood vessel memory bank, noise memory bank, and model parameters are updated. Repeat the process of candidate generation, vessel segmentation, joint scoring, memory filtering, manual verification, and model training until the number of newly added high-value candidate vessel segments falls below a preset threshold, the verification performance no longer improves, the manual annotation budget is exhausted, or the segmentation results meet the preset analysis requirements.
2. The cross-domain cerebral vessel segmentation method based on vessel enhancement and active learning according to claim 1, characterized in that, In step S3, candidate regions that are directly connected to the initial blood vessel, are less than a preset threshold distance from the initial blood vessel, or can continue the direction of the existing blood vessel are preferentially retained.
3. The cross-domain cerebral blood vessel segmentation method based on vascular enhancement and active learning according to claim 1, characterized in that, The perturbation in step S6 includes one or more of the following: adjusting the enhancement threshold, adjusting the scale parameter, adding slight Gaussian noise, implementing intensity scaling or offset, small-angle rotation, translation, scale change, and adjusting morphological post-processing parameters.
4. The cross-domain cerebral blood vessel segmentation method based on vascular enhancement and active learning according to claim 1, characterized in that, In step S10, regions with a Frangi response less than 0.01 and an original image intensity less than 500 are designated as high-confidence backgrounds.