Training method and detection method of polyp detection model, device, medium and equipment

By extracting foreground node correlation parameters from source and target domain images in the polyp detection model and updating features to adapt to different data distributions, the problems of model adaptability and annotation workload are solved, and high-accuracy polyp detection is achieved.

CN115375655BActive Publication Date: 2026-04-24DOUYIN VISION CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
DOUYIN VISION CO LTD
Filing Date
2022-08-23
Publication Date
2026-04-24

AI Technical Summary

Technical Problem

In existing technologies, polyp detection models based on physician annotations are difficult to adapt to the differences in data distribution among different hospitals or equipment, resulting in insufficient detection accuracy and a large workload for manual annotation.

Method used

By extracting foreground and background features from source and target domain images based on a polyp detection model, the correlation parameters of foreground nodes in the source and target domains are determined, features are updated to reduce domain differences, and the model is trained using labeled source domain data, reducing the need for manual annotation.

Benefits of technology

It improves the accuracy of polyp detection, reduces the workload of manual annotation, and enables the model to adapt to detection under different data distributions, thereby enhancing the discriminative power of polyp foreground features.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115375655B_ABST
    Figure CN115375655B_ABST
Patent Text Reader

Abstract

The present disclosure relates to a polyp detection model training method, a polyp detection model detection method, a polyp detection model training device, a polyp detection model detection device, a medium and an apparatus, comprising: performing foreground-background feature extraction on source domain images in a source domain data set and target domain images in a target domain data set based on a polyp detection model to obtain first source domain features and first target domain features; determining source domain foreground nodes and target domain foreground nodes based on the first source domain features and the first target domain features; determining a correlation parameter between each source domain foreground node and each target domain foreground node; updating the first source domain features and the first target domain features according to the correlation parameter respectively to obtain second source domain features and second target domain features; obtaining a prediction result corresponding to the source domain images according to the second source domain features; determining a target loss of the polyp detection model according to the prediction result corresponding to the source domain images and a polyp label, and the second source domain features and the second target domain features, and training the polyp detection model according to the target loss.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This disclosure relates to the field of image processing, and more specifically, to a training method, detection method, apparatus, medium, and device for a polyp detection model. Background Technology

[0002] Most colorectal cancers do not occur suddenly; their development is a relatively slow process that can take 5-10 years, from small polyps to large polyps, and then to dysplasia. Since most colonic polyps are asymptomatic, accurate polyp detection during examinations plays a crucial role in the early prevention, intervention, and detection of colorectal cancer.

[0003] In related technologies, polyp detection models can be trained based on images annotated by physicians. However, this relies not only on accurate and extensive user annotations, but also on the difficulty of achieving accurate polyp detection through a comprehensive model due to the differences in data distribution across different hospitals or devices. Summary of the Invention

[0004] This summary section is provided to briefly introduce the concepts, which will be described in detail in the detailed description section below. This summary section is not intended to identify key or essential features of the claimed technical solution, nor is it intended to limit the scope of the claimed technical solution.

[0005] Firstly, this disclosure provides a method for training a polyp detection model, the method comprising:

[0006] Based on the polyp detection model, foreground and background features are extracted from source domain images in the source domain dataset and target domain images in the target domain dataset to obtain first source domain features and first target domain features. The images in the source domain dataset are labeled with polyp tags, while the images in the target domain dataset are not labeled. The data distributions of the source domain dataset and the target domain dataset are different.

[0007] Based on the first source domain features and the first target domain features, source domain foreground nodes in the source domain image and target domain foreground nodes in the target domain image are determined.

[0008] Based on the source domain foreground nodes and the target domain foreground nodes, determine the correlation parameters between each source domain foreground node and each target domain foreground node;

[0009] The first source domain features and the first target domain features are updated according to the correlation parameters to obtain the second source domain features and the second target domain features.

[0010] The prediction result corresponding to the source domain image is obtained based on the second source domain feature;

[0011] Based on the prediction results corresponding to the source domain image, the polyp label, the second source domain features, and the second target domain features, the target loss of the polyp detection model is determined, and the polyp detection model is trained based on the target loss.

[0012] Secondly, this disclosure provides a method for detecting polyps, the method comprising:

[0013] Received the target image for detection;

[0014] The target image is input into the trained polyp detection model to obtain the polyp detection result corresponding to the target image, wherein the polyp detection model is trained based on the training method of the polyp detection model described in the first aspect.

[0015] Thirdly, this disclosure provides a training apparatus for a polyp detection model, the apparatus comprising:

[0016] The feature extraction module is used to extract foreground and background features from source domain images in the source domain dataset and target domain images in the target domain dataset based on the polyp detection model, to obtain first source domain features and first target domain features. The images in the source domain dataset are labeled with polyp tags, while the images in the target domain dataset are not labeled. The data distributions of the source domain dataset and the target domain dataset are different.

[0017] The first determining module is used to determine the source domain foreground node in the source domain image and the target domain foreground node in the target domain image based on the first source domain features and the first target domain features.

[0018] The second determining module is used to determine the correlation parameter between each source domain foreground node and each target domain foreground node based on the source domain foreground node and the target domain foreground node;

[0019] The update module is used to update the first source domain features and the first target domain features according to the correlation parameters respectively, so as to obtain the second source domain features and the second target domain features.

[0020] The prediction module is used to obtain the prediction result corresponding to the source domain image based on the second source domain features;

[0021] The training module is used to determine the target loss of the polyp detection model based on the prediction results corresponding to the source domain image, the polyp label, the second source domain features, and the second target domain features, and to train the polyp detection model based on the target loss.

[0022] Fourthly, this disclosure provides a polyp detection device, the device comprising:

[0023] The receiving module is used to receive the detected target image;

[0024] The processing module is used to input the target image into the trained polyp detection model to obtain the polyp detection result corresponding to the target image, wherein the polyp detection model is trained based on the training method of the polyp detection model described in the first aspect.

[0025] Fifthly, this disclosure provides a computer-readable medium having a computer program stored thereon, which, when executed by a processing device, implements the steps of the method described in the first aspect.

[0026] Sixthly, this disclosure provides an electronic device, comprising:

[0027] A storage device on which computer programs are stored;

[0028] A processing device for executing the computer program in the storage device to implement the steps of the method described in the first aspect.

[0029] The above technical solution allows for training of a polyp detection model based on labeled source domain data and unlabeled target domain data. On the one hand, it effectively reduces the workload and technical requirements of manual annotation. On the other hand, during training, by determining the correlation between foreground features in the source domain image and foreground features in the target domain image, foreground features of both the source and target domain images are enhanced. By constructing a cross-domain graph topology based on the correlation between cross-domain types, domain differences are reduced to improve the discriminative power of polyp features, thereby ensuring the detection accuracy of cross-domain polyp detection. This approach is suitable for application scenarios where polyps have strong foreground camouflage.

[0030] Other features and advantages of this disclosure will be described in detail in the following detailed description section. Attached Figure Description

[0031] The above and other features, advantages, and aspects of the embodiments of this disclosure will become more apparent from the accompanying drawings and the following detailed description. Throughout the drawings, the same or similar reference numerals denote the same or similar elements. It should be understood that the drawings are schematic, and the originals and elements are not necessarily drawn to scale. In the drawings:

[0032] Figure 1 This is a flowchart of a training method for a polyp detection model provided according to one embodiment of the present disclosure;

[0033] Figure 2 This is a block diagram of a training apparatus for a polyp detection model provided according to one embodiment of the present disclosure;

[0034] Figure 3 A schematic diagram of the structure of an electronic device suitable for implementing embodiments of the present disclosure is shown. Detailed Implementation

[0035] Embodiments of this disclosure will now be described in more detail with reference to the accompanying drawings. While some embodiments of this disclosure are shown in the drawings, it should be understood that this disclosure can be implemented in various forms and should not be construed as limited to the embodiments set forth herein. Rather, these embodiments are provided to provide a more thorough and complete understanding of this disclosure. It should be understood that the accompanying drawings and embodiments of this disclosure are for illustrative purposes only and are not intended to limit the scope of protection of this disclosure.

[0036] It should be understood that the steps described in the method embodiments of this disclosure may be performed in different orders and / or in parallel. Furthermore, the method embodiments may include additional steps and / or omit the steps shown. The scope of this disclosure is not limited in this respect.

[0037] The term "comprising" and its variations as used herein are open-ended inclusion, meaning "including but not limited to". The term "based on" means "at least partially based on". The term "one embodiment" means "at least one embodiment"; the term "another embodiment" means "at least one additional embodiment"; the term "some embodiments" means "at least some embodiments". Definitions of other terms will be given in the description below.

[0038] It should be noted that the concepts of "first" and "second" mentioned in this disclosure are used only to distinguish different devices, modules or units, and are not used to limit the order of functions performed by these devices, modules or units or their interdependencies.

[0039] It should be noted that the terms "a" and "a plurality of" used in this disclosure are illustrative rather than restrictive, and those skilled in the art should understand that, unless otherwise expressly indicated in the context, they should be understood as "one or more".

[0040] The names of messages or information exchanged between multiple devices in the embodiments of this disclosure are for illustrative purposes only and are not intended to limit the scope of such messages or information.

[0041] It is understood that before using the technical solutions disclosed in the various embodiments of this disclosure, users should be informed of the types, scope of use, and usage scenarios of the personal information involved in this disclosure in an appropriate manner in accordance with relevant laws and regulations, and user authorization should be obtained.

[0042] For example, upon receiving a user's active request, a prompt message is sent to the user to explicitly inform them that the requested operation will require the acquisition and use of the user's personal information. This allows the user to independently choose whether to provide personal information to the software or hardware, such as the electronic device, application, server, or storage medium performing the operations of this disclosed technical solution, based on the prompt message.

[0043] As an optional but non-limiting implementation, in response to a user's active request, sending a prompt message to the user can be done via a pop-up window, where the prompt message can be presented in text format. Furthermore, the pop-up window can also include a selection control allowing the user to choose whether to "agree" or "disagree" to provide personal information to the electronic device.

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

[0045] Meanwhile, it is understood that the data involved in this technical solution (including but not limited to the data itself, the acquisition or use of the data) shall comply with the requirements of relevant laws, regulations and related provisions.

[0046] Figure 1 The diagram shows a flowchart of a training method for a polyp detection model according to one embodiment of this disclosure. Figure 1 As shown, the method may include:

[0047] In step 11, foreground and background features are extracted from source domain images in the source domain dataset and target domain images in the target domain dataset based on the polyp detection model to obtain first source domain features and first target domain features. The images in the source domain dataset are labeled with polyp tags, while the images in the target domain dataset are not labeled. The data distributions of the source domain dataset and the target domain dataset are different.

[0048] The polyp detection model can be implemented based on a detection network, such as the Faster-RCNN network. In the Faster-RCNN network: the feature extraction subnetwork can be used to extract features, such as through the backbone network, or by extracting feature maps of the input image based on a set of conv+relu+pooling layers; the region proposal network (RPN) can obtain a large number of foreground regions by inputting the features extracted by the feature extraction subnetwork into the region proposal network. The foreground regions and the input features are then input into the Region of Interest (ROI) Align subnetwork, thereby obtaining the region of interest (ROI) features corresponding to a large number of foreground features.

[0049] As an example, a source domain image can be input into the polyp detection model to obtain the ROI features corresponding to the source domain image, i.e., the first source domain features, using the above method. Similarly, a target domain image can be input into the polyp detection model to obtain the ROI features corresponding to the target domain image, i.e., the first target domain features, using the above steps. For example, 128 foreground and background features corresponding to the source domain image and 128 foreground and background features corresponding to the target domain image can be obtained respectively. The foreground and background features can include foreground and background features in the image. The number of features can be set based on the actual application scenario, and this disclosure does not limit this.

[0050] In this process, the source image can be annotated by a physician with some experience to obtain corresponding polyp labels. In the field of polyp detection, the polyp label can include a classification label and a location label to indicate what type of polyp is contained in the source image and its specific location in the source image.

[0051] As described in the background section of this disclosure, data from different modalities, devices, or hospitals may have different distributions. Therefore, a polyp detection model trained on images from the source domain dataset may struggle to directly detect polyps in images from the target domain. Furthermore, in the field of polyp detection, due to the relatively small amount of data and high annotation requirements, the workload of annotating training images is substantial. Therefore, this disclosure allows for simultaneous training of the model on images from both the source and target domain datasets, enabling the trained polyp detection model to be adapted for polyp detection in images from the target domain without requiring annotation of the data in the target domain dataset.

[0052] For example, the source domain dataset could be image data from Hospital Hs1 with corresponding polyp labels, while the target domain dataset could be image data from Hospital Hs2.

[0053] In step 12, based on the first source domain features and the first target domain features, source domain foreground nodes in the source domain image and target domain foreground nodes in the target domain image are determined.

[0054] In this process, the polyp is usually located in the foreground of the image in both the source and target domain images. Accordingly, in this step, the source domain foreground node is used to represent the predicted feature points corresponding to the foreground in the source domain image, and the target domain foreground node is used to represent the predicted feature points corresponding to the foreground in the target domain image, so as to accurately detect the polyp.

[0055] In step 13, the correlation parameters between each source domain foreground node and each target domain foreground node are determined based on the source domain foreground node and the target domain foreground node.

[0056] In this step, for each source domain foreground node, correlation calculation is performed with each target domain foreground node to characterize the feature association between the source domain features and the target domain features, so as to shorten the distribution difference between the source domain features and the target domain features.

[0057] In step 14, the first source domain features and the first target domain features are updated according to the correlation parameters to obtain the second source domain features and the second target domain features.

[0058] In the case of polyp detection, the polyp's color and texture are very similar to the surrounding normal tissue, resulting in low contrast and giving the polyp a strong camouflage characteristic, which leads to insufficient detection accuracy.

[0059] In the steps, the correlation parameter is used to represent the correlation between the foreground features of the source domain and the foreground features of the target domain. Based on this correlation parameter, the foreground features of the first source domain and the first target domain can be enhanced respectively to highlight the contrast between the foreground features corresponding to the polyp and other regions. This can improve the foreground feature expression in the feature image corresponding to the source domain image to a certain extent, which is suitable for application scenarios where the foreground of the polyp is strongly camouflaged.

[0060] In step 15, the prediction result corresponding to the source domain image is obtained based on the second source domain features. This step can be based on the classifier and regressor in the Faster-RCNN network to obtain the prediction result. For example, foreground features can be extracted from the second source domain features and input into the classifier of the fully connected layer to obtain the corresponding predicted classification, and input into the regressor of the fully connected layer to obtain the corresponding predicted location.

[0061] In step 16, the target loss of the polyp detection model is determined based on the prediction results and polyp labels corresponding to the source domain image, as well as the second source domain features and the second target domain features, and the polyp detection model is trained based on the target loss.

[0062] The detection accuracy of the polyp detection model can be determined based on the prediction results and polyp labels corresponding to the source domain image. Based on the second source domain features and the second target domain features, cross-domain detection of polyps can be achieved by constraining the distributions of the two to be close. Therefore, the target loss can include the accuracy of the polyp detection model and the distance between the distributions of the source domain features and the target domain features.

[0063] For example, training can be stopped when the target loss is less than the loss threshold, or when the number of training iterations reaches the threshold. Otherwise, the parameters in the polyp detection model can be updated using gradient descent based on the target loss, and the training can be repeated through the steps described above until the model training is complete.

[0064] Therefore, the above technical solution allows for the training of a polyp detection model based on labeled source domain data and unlabeled target domain data. On the one hand, it effectively reduces the workload and technical requirements of manual annotation. On the other hand, during training, by determining the correlation between foreground features in the source domain image and foreground features in the target domain image, foreground features of both the source and target domain images are enhanced. By constructing a cross-domain graph topology based on the correlation between cross-domain types, domain differences are reduced to improve the discriminative power of polyp features, thereby ensuring the detection accuracy under cross-domain polyp detection. This approach is suitable for application scenarios where polyps have strong foreground camouflage.

[0065] As another example, step 11, which involves extracting foreground and background features from the source domain images in the source domain dataset and the target domain images in the target domain dataset based on the polyp detection model to obtain the first source domain features and the first target domain features, may include:

[0066] For the target image, feature extraction is performed on the target image based on the backbone network in the polyp detection model to obtain image features, wherein the target image includes the source domain image and the target domain image;

[0067] The region of interest (ROI) features are extracted from the image features to obtain the ROI features;

[0068] The image features and the region of interest features are fused to obtain first domain features, wherein the first domain features include first source domain features corresponding to the source domain image and first target domain features corresponding to the target domain image.

[0069] The following explanation uses a source domain image as an example. The source domain image can be input into the backbone network for feature extraction in a similar manner to that described above. The extracted image features are then further input into a region candidate subnetwork and an interest feature matching subnetwork to extract region-of-interest (ROI) features, thus obtaining ROI features. In this embodiment, the ROI features possess rich high-level semantic information but lack contextual information (such as location information). Therefore, in this embodiment, the low-level contextual information can be fused with the high-level semantic information; that is, the image features and the ROI features are fused to enhance the contextual information representation of instance-level features.

[0070] In this process, after the backbone network extracts features from the source domain image, it obtains low-level output features c1, c2, and c3 under different receptive fields. Then, c1, c2, and c3 are mapped to the same size, and feature concatenation is performed to obtain the low-level fused features, which are the features obtained from feature extraction of the source domain image, i.e., the image features corresponding to the source domain image. The image features and the region of interest features can then be fused using the following formula to obtain the first domain features:

[0071]

[0072] Among them, f' ins Used to represent the first domain feature, that is, for the source domain image, the first domain feature is the first source domain feature; for the target domain image, the first domain feature is the first target domain feature.

[0073] f c Used to represent the image features corresponding to the target image;

[0074] f ins Used to represent the region of interest features corresponding to the target image;

[0075] Used to represent the cross product operation of matrices.

[0076] Therefore, by using the above technical solution, when extracting image features from source and target domain images, the obtained domain features can include both high-level semantic information and low-level contextual information, thereby improving the accuracy and feature diversity of the domain features obtained from image feature extraction, and improving the training efficiency and accuracy of the polyp detection model.

[0077] In one possible embodiment, an exemplary implementation of determining the source domain foreground node in the source domain image and the target domain foreground node in the target domain image based on the first source domain features and the first target domain features in step 12 is as follows: This step may include:

[0078] The set of candidate foreground nodes corresponding to the first source domain feature is determined based on the polyp label.

[0079] The polyp label includes a location label, which allows us to obtain features at the corresponding location. For example, the first source domain feature is f. s Then, the features corresponding to the position labels in the first source domain features can be used as the candidate foreground node set f. s obj That is, f s obj ∈f s .

[0080] For each candidate foreground node in the candidate foreground node set, determine the target domain matching foreground node in the first target domain feature corresponding to the candidate foreground node, and determine the source domain matching foreground node in the first source domain feature of the target domain matching foreground node.

[0081] For the i-th candidate foreground node f s obj,i The candidate foreground node f can be calculated separately. s obj,i Features f of the first target domain t Each feature f in t j The cosine similarity between the nodes is used to determine the feature with the highest cosine similarity as the candidate foreground node f. s obj,i The corresponding target domain matches the foreground node, and the index representation of the target domain matching foreground node is as follows:

[0082] j'=arg max cos(f s obj,i ,f t j )

[0083]

[0084] That is, with candidate foreground node f s obj,i The corresponding target domain matching foreground node is the j'th feature point in the first target domain features. This is used to represent the number of features in the first target domain feature set, continuing from the example above. The value is 128.

[0085] Furthermore, for the target domain matching foreground node, i.e., the j'-th feature point in the first target domain features, the cosine similarity between each feature in the first source domain features can be calculated, and the feature with the largest corresponding cosine similarity is determined as the source domain matching foreground node of the target domain matching foreground node in the first source domain features. For example, the j'-th feature point f in the first target domain features is determined as follows: t j The source domain matching foreground node in the first source domain feature is the i'th feature point in the first source domain feature.

[0086] Subsequently, if the source domain matching foreground node belongs to the candidate foreground node set, the candidate foreground node is determined as the source domain foreground node, and the target domain matching foreground node is determined as the target domain foreground node.

[0087] If the i'-th feature point in the first source domain features belongs to f s obj At this point, the candidate foreground node f in the first source domain feature can be considered as s obj,i As a source domain foreground node, it can also determine feature f in the first target domain features. t j 'Foreground node of the target domain.

[0088] Therefore, through the above technical solution, the source domain foreground nodes in the source domain features and the target domain foreground nodes in the target domain features can be filtered based on the feature similarity between the source domain features and the target domain features. On the one hand, this can improve the accuracy of the source domain foreground nodes, and on the other hand, it can accurately determine the target domain foreground nodes without labeling the target domain image, thus expanding the application scope of the method.

[0089] In one possible embodiment, an exemplary implementation of determining the correlation parameter between each source domain foreground node and each target domain foreground node in step 13 based on the source domain foreground node and the target domain foreground node is as follows, which may include:

[0090] The correlation parameter between the i-th source domain foreground node and the j-th target domain foreground node is determined by the following formula.

[0091]

[0092] in, The first source domain feature is used to represent the i-th source domain foreground node in the source domain image s;

[0093] The first target domain feature used to represent the j-th target domain foreground node in the target domain image t;

[0094] σ is used to represent the tuning hyperparameter.

[0095] In this context, the source domain foreground node represents the foreground features in the source domain image, and the target domain foreground node represents the foreground features in the target domain image. The above formula can determine the correlation between the foreground features in the source domain and the target domain. This not only facilitates subsequent foreground feature enhancement based on the correlation parameter, but also provides reliable data support for narrowing the feature distribution differences between the foreground features in the source domain and the target domain, ensuring accurate identification of polyp features in the target domain in cross-domain scenarios.

[0096] In one possible embodiment, in step 14, the first source domain features and the first target domain features are updated according to the correlation parameters to obtain the second source domain features and the second target domain features, including:

[0097] Based on the correlation parameters, multi-layer convolutional feature extraction is performed on the first source domain features to obtain the second source domain features;

[0098] Based on the correlation parameters, multi-layer convolutional feature extraction is performed on the first target domain features to obtain the second target domain features, wherein the number of convolutional feature extraction layers corresponding to the first source domain features and the first target domain features is the same.

[0099] The number of convolutional feature extraction layers can be set according to the actual application scenario, and this disclosure does not limit this. For example, the second source domain features can be obtained by performing multi-layer convolutional feature extraction on the first source domain features based on the correlation parameters using the following formula:

[0100]

[0101] Among them, A st A matrix of correlation parameters between source domain foreground nodes in source domain image s and target domain foreground nodes in target domain image t.

[0102] I is used to denote the identity matrix;

[0103] D' is used to represent A st The degree matrix, where D' ii =∑ j A' ij ;

[0104] H (l) Used to represent the convolutional features corresponding to the l-th layer, where the convolutional features corresponding to the 0-th layer are the first source domain features;

[0105] Hl+1 Used to represent the convolutional features corresponding to the (l+1)th layer;

[0106] W (l) Used to represent the weight parameters corresponding to the l-th layer;

[0107] η() is used to represent nonlinear activation functions, such as the ReLU function.

[0108] Similarly, based on the aforementioned correlation parameters, multi-layer convolutional feature extraction can be performed on the first target domain features to obtain the second target domain features, which will not be elaborated further here.

[0109] In this technical solution, by determining A st The degree matrix can determine the comprehensive correlation between the i-th source domain foreground node and the target domain foreground node, thereby realizing the overall association between the source domain features and the target domain features, determining the overall correlation between the source domain features and the target domain features, ensuring the consistency of updating the first source domain features and the first target domain features, and facilitating the constraint of the consistency between the obtained second source domain features and the second target domain features.

[0110] In one possible embodiment, the polyp label includes a location label and a classification label;

[0111] Accordingly, an exemplary implementation of determining the target loss of the polyp detection model based on the prediction result corresponding to the source domain image, the polyp label, the second source domain features, and the second target domain features is as follows, which may include:

[0112] The regression loss is determined based on the predicted location information and the location label in the prediction results;

[0113] The classification loss is determined based on the predicted classification information and the classification label in the prediction results;

[0114] The methods for determining regression loss and classification loss can be determined based on the corresponding loss calculation methods in the Faster-RCNN network in this field. For example, classification loss can be calculated based on cross-entropy loss, and regression loss can be calculated based on smooth L1 loss, which will not be elaborated here.

[0115] The feature loss is determined based on the second source domain features and the second target domain features.

[0116] For example, the feature loss L can be determined based on the second source domain features and the second target domain features using the following formula. cst :

[0117]

[0118] Where, N s Used to represent the number of foreground nodes in the source domain;

[0119] N t Used to indicate the number of foreground nodes in the target domain;

[0120] x i s Used to represent the feature corresponding to the i-th source domain foreground node in the second source domain features;

[0121] x j t This is used to represent the feature corresponding to the j-th target domain foreground node in the second target domain features.

[0122] Therefore, this feature loss can be used to narrow down the feature distribution between source domain features and target domain features, thereby adjusting the accuracy of the cross-domain detection results of the polyp detection model based on this loss.

[0123] Then, the target loss can be determined based on the regression loss, the classification loss, and the feature loss.

[0124] For example, the target loss can be obtained by weighted summation based on the weights corresponding to the regression loss, classification loss, and feature loss, respectively. Thus, through the above technical solution, the target loss can include both a loss constraining the accuracy of polyp detection results and a loss constraining the feature distribution between source and target domain features. This improves the model's detection accuracy during training while also making the model applicable to polyp detection images within the target domain, enhancing the accuracy of polyp detection in cross-domain situations, and broadening the scope of application of the polyp detection model.

[0125] As another example, the method may also include:

[0126] Based on the feature maps obtained by feature extraction from the source domain image and the target domain image using the backbone network, the adversarial loss is calculated. This adversarial loss can be implemented based on the adversarial loss commonly used in generative adversarial networks in this field, and this disclosure does not limit it.

[0127] Furthermore, determining the target loss for the polyp detection model can include:

[0128] The target loss is determined based on the regression loss, the classification loss, the feature loss, and the adversarial loss, which can further enhance the loss constraint in the target loss, ensure the accuracy and effectiveness of parameter adjustment of the polyp detection model based on the target loss, and improve the training efficiency of the polyp detection model to a certain extent.

[0129] This disclosure also provides a method for detecting polyps, the method comprising:

[0130] The target image to be detected is received, wherein the target image may be an image acquired from an endoscope for real-time detection.

[0131] The target image is input into the trained polyp detection model to obtain the polyp detection result corresponding to the target image. The polyp detection model is trained based on any of the polyp detection model training methods described above.

[0132] The above technical solution enables polyp detection in target images based on a trained polyp detection model, ensuring both accuracy and efficiency. Furthermore, this polyp detection model is trained using source and target domain images as training samples. During this process, the correlation parameters between polyp foreground features in the source and target domain images can be used to enhance foreground feature representation. This allows the trained polyp detection model to reduce detection errors caused by the strong camouflage of polyp foreground features, further broadening the application scope of the polyp detection method and improving the accuracy of the detection results.

[0133] This disclosure also provides a training device for a polyp detection model, such as... Figure 2 As shown, the device 10 includes:

[0134] The feature extraction module 101 is used to extract foreground and background features from source domain images in the source domain dataset and target domain images in the target domain dataset based on the polyp detection model, to obtain first source domain features and first target domain features. The images in the source domain dataset are labeled with polyp tags, while the images in the target domain dataset are not labeled. The data distribution of the source domain dataset and the target domain dataset is different.

[0135] The first determining module 102 is used to determine the source domain foreground node in the source domain image and the target domain foreground node in the target domain image based on the first source domain features and the first target domain features.

[0136] The second determining module 103 is used to determine the correlation parameter between each source domain foreground node and each target domain foreground node based on the source domain foreground node and the target domain foreground node;

[0137] The update module 104 is used to update the first source domain features and the first target domain features according to the correlation parameters respectively, so as to obtain the second source domain features and the second target domain features.

[0138] Prediction module 105 is used to obtain the prediction result corresponding to the source domain image based on the second source domain features;

[0139] The training module 106 is used to determine the target loss of the polyp detection model based on the prediction result corresponding to the source domain image, the polyp label, the second source domain feature, and the second target domain feature, and to train the polyp detection model based on the target loss.

[0140] Optionally, the first determining module includes:

[0141] The first determining submodule is used to determine the set of candidate foreground nodes corresponding to the first source domain features based on the polyp label;

[0142] The second determining submodule is used to determine, for each candidate foreground node in the candidate foreground node set, the target domain matching foreground node corresponding to the candidate foreground node in the first target domain feature, and to determine the source domain matching foreground node in the first source domain feature of the target domain matching foreground node;

[0143] The third determining submodule is used to determine the candidate foreground node as the source domain foreground node and the target domain matching foreground node as the target domain foreground node if the source domain matching foreground node belongs to the candidate foreground node set.

[0144] Optionally, the second determining module is used to:

[0145] The correlation parameter between the i-th source domain foreground node and the j-th target domain foreground node is determined by the following formula.

[0146]

[0147] in, The first source domain feature is used to represent the i-th source domain foreground node in the source domain image s; σ is used to represent the first target domain feature corresponding to the j-th target domain foreground node in the target domain image t; σ is used to represent the adjustment hyperparameter.

[0148] Optionally, the update module includes:

[0149] The first extraction submodule is used to perform multi-layer convolutional feature extraction on the first source domain features based on the correlation parameters to obtain the second source domain features;

[0150] The second extraction submodule is used to perform multi-layer convolutional feature extraction on the first target domain features based on the correlation parameters to obtain the second target domain features, wherein the number of layers of convolutional feature extraction corresponding to the first source domain features and the first target domain features is the same.

[0151] Optionally, the first extraction submodule performs multi-layer convolutional feature extraction on the first source domain features based on the correlation parameters using the following formula to obtain the second source domain features:

[0152]

[0153] Among them, A st A matrix representing the correlation parameters between source foreground nodes in source image s and target foreground nodes in target image t; I represents the identity matrix; D' represents A. st The degree matrix, where D' ii =∑ j A' ij H (l) Used to represent the convolutional features corresponding to the l-th layer, where the convolutional features corresponding to the 0th layer are the first source domain features; H l+1 Used to represent the convolutional features corresponding to the (l+1)th layer; W (l) The parameter η is used to represent the weight parameters corresponding to the l-th layer; η() is used to represent the nonlinear activation function.

[0154] Optionally, the feature extraction module includes:

[0155] The third extraction submodule is used to extract features from the target image based on the backbone network in the polyp detection model to obtain image features, wherein the target image includes the source domain image and the target domain image; the fourth extraction submodule is used to extract region of interest features from the image features to obtain region of interest features; the fusion submodule is used to fuse the image features and the region of interest features to obtain first domain features, wherein the first domain features include the first source domain features corresponding to the source domain image and the first target domain features corresponding to the target domain image.

[0156] Optionally, the polyp label includes a location label and a classification label; the training module includes: a regression loss determination submodule, used to determine a regression loss based on the predicted location information in the prediction result and the location label; a classification loss determination submodule, used to determine a classification loss based on the predicted classification information in the prediction result and the classification label; a feature loss determination submodule, used to determine a feature loss based on the second source domain features and the second target domain features; and a ninth determination submodule, used to determine the target loss based on the regression loss, the classification loss, and the feature loss.

[0157] Optionally, the feature loss determination submodule determines the feature loss based on the second source domain features and the second target domain features using the following formula:

[0158]

[0159] Among them, L cst Used to represent the feature loss; N s N is used to represent the number of foreground nodes in the source domain; t Used to represent the number of foreground nodes in the target domain; x i s Used to represent the feature corresponding to the i-th source domain foreground node in the second source domain features; x j t This is used to represent the feature corresponding to the j-th target domain foreground node in the second target domain features.

[0160] This disclosure also provides a polyp detection device, the device comprising:

[0161] The receiving module is used to receive the detected target image;

[0162] The processing module is used to input the target image into the trained polyp detection model to obtain the polyp detection result corresponding to the target image, wherein the polyp detection model is trained based on any of the polyp detection models described above.

[0163] The following is for reference. Figure 3 This diagram illustrates a structural schematic of an electronic device 600 suitable for implementing embodiments of the present disclosure. The terminal devices in the embodiments of the present disclosure may include, but are not limited to, mobile terminals such as mobile phones, laptops, digital broadcast receivers, PDAs (personal digital assistants), PADs (tablet computers), PMPs (portable multimedia players), in-vehicle terminals (e.g., in-vehicle navigation terminals), and fixed terminals such as digital TVs and desktop computers. Figure 3 The electronic device shown is merely an example and should not be construed as limiting the functionality and scope of the embodiments disclosed herein.

[0164] like Figure 3 As shown, electronic device 600 may include a processing device (e.g., a central processing unit, a graphics processor, etc.) 601, which can perform various appropriate actions and processes according to a program stored in read-only memory (ROM) 602 or a program loaded from storage device 608 into random access memory (RAM) 603. RAM 603 also stores various programs and data required for the operation of electronic device 600. Processing device 601, ROM 602, and RAM 603 are interconnected via bus 604. Input / output (I / O) interface 605 is also connected to bus 604.

[0165] Typically, the following devices can be connected to I / O interface 605: input devices 606 including, for example, touchscreens, touchpads, keyboards, mice, cameras, microphones, accelerometers, gyroscopes, etc.; output devices 607 including, for example, liquid crystal displays (LCDs), speakers, vibrators, etc.; storage devices 608 including, for example, magnetic tapes, hard disks, etc.; and communication devices 609. Communication device 609 allows electronic device 600 to communicate wirelessly or wiredly with other devices to exchange data. Although Figure 3 An electronic device 600 with various devices is shown; however, it should be understood that it is not required to implement or possess all of the devices shown. More or fewer devices may be implemented or possessed alternatively.

[0166] In particular, according to embodiments of this disclosure, the processes described above with reference to the flowcharts can be implemented as computer software programs. For example, embodiments of this disclosure include a computer program product comprising a computer program carried on a non-transitory computer-readable medium, the computer program containing program code for performing the methods shown in the flowcharts. In such embodiments, the computer program can be downloaded and installed from a network via a communication device 609, or installed from a storage device 608, or installed from a ROM 602. When the computer program is executed by the processing device 601, it performs the functions defined in the methods of embodiments of this disclosure.

[0167] It should be noted that the computer-readable medium described in this disclosure can be a computer-readable signal medium or a computer-readable storage medium, or any combination thereof. A computer-readable storage medium can be, for example,—but not limited to—an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination thereof. More specific examples of a computer-readable storage medium may include, but are not limited to: an electrical connection having one or more wires, a portable computer disk, a hard disk, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or flash memory), optical fiber, portable compact disk read-only memory (CD-ROM), optical storage device, magnetic storage device, or any suitable combination thereof. In this disclosure, a computer-readable storage medium can be any tangible medium containing or storing a program that can be used by or in connection with an instruction execution system, apparatus, or device. In this disclosure, a computer-readable signal medium can include a data signal propagated in baseband or as part of a carrier wave, carrying computer-readable program code. Such propagated data signals can take various forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination thereof. A computer-readable signal medium can be any computer-readable medium other than a computer-readable storage medium, which can send, propagate, or transmit a program for use by or in connection with an instruction execution system, apparatus, or device. The program code contained on the computer-readable medium can be transmitted using any suitable medium, including but not limited to: wires, optical fibers, RF (radio frequency), etc., or any suitable combination thereof.

[0168] In some implementations, clients and servers can communicate using any currently known or future-developed network protocol such as HTTP (Hypertext Transfer Protocol) and can interconnect with digital data communication (e.g., communication networks) of any form or medium. Examples of communication networks include local area networks (“LANs”), wide area networks (“WANs”), the Internet (e.g., the Internet of Things), and peer-to-peer networks (e.g., ad hoc peer-to-peer networks), as well as any currently known or future-developed networks.

[0169] The aforementioned computer-readable medium may be included in the aforementioned electronic device; or it may exist independently and not assembled into the electronic device.

[0170] The aforementioned computer-readable medium carries one or more programs that, when executed by the electronic device, cause the electronic device to: extract foreground and background features from source domain images in a source domain dataset and target domain images in a target domain dataset based on a polyp detection model, obtaining first source domain features and first target domain features, wherein the images in the source domain dataset are labeled with polyp tags, the images in the target domain dataset are not labeled, and the data distributions of the source domain dataset and the target domain dataset are different; and, based on the first source domain features and the first target domain features, determine source domain foreground nodes in the source domain images and foreground nodes in the target domain images. The target domain foreground node; based on the source domain foreground node and the target domain foreground node, determine the correlation parameter between each source domain foreground node and each target domain foreground node; update the first source domain feature and the first target domain feature according to the correlation parameter to obtain the second source domain feature and the second target domain feature; obtain the prediction result corresponding to the source domain image according to the second source domain feature; determine the target loss of the polyp detection model according to the prediction result corresponding to the source domain image, the polyp label, the second source domain feature and the second target domain feature, and train the polyp detection model according to the target loss.

[0171] Alternatively, the aforementioned computer-readable medium carries one or more programs that, when executed by the electronic device, cause the electronic device to: receive a detected target image; input the target image into a trained polyp detection model to obtain a polyp detection result corresponding to the target image, wherein the polyp detection model is trained based on the polyp detection model training method described above.

[0172] Computer program code for performing the operations of this disclosure can be written in one or more programming languages ​​or a combination thereof, including but not limited to object-oriented programming languages ​​such as Java, Smalltalk, and C++, as well as conventional procedural programming languages ​​such as the "C" language or similar programming languages. The program code can be executed entirely on the user's computer, partially on the user's computer, as a standalone software package, partially on the user's computer and partially on a remote computer, or entirely on a remote computer or server. In cases involving remote computers, the remote computer can be connected to the user's computer via any type of network—including a local area network (LAN) or a wide area network (WAN)—or can be connected to an external computer (e.g., via the Internet using an Internet service provider).

[0173] The flowcharts and block diagrams in the accompanying drawings illustrate the architecture, functionality, and operation of possible implementations of systems, methods, and computer program products according to various embodiments of this disclosure. In this regard, each block in a flowchart or block diagram may represent a module, segment, or portion of code containing one or more executable instructions for implementing a specified logical function. It should also be noted that in some alternative implementations, the functions indicated in the blocks may occur in a different order than those indicated in the drawings. For example, two consecutively indicated blocks may actually be executed substantially in parallel, and they may sometimes be executed in reverse order, depending on the functions involved. It should also be noted that each block in the block diagrams and / or flowcharts, and combinations of blocks in the block diagrams and / or flowcharts, can be implemented using a dedicated hardware-based system that performs the specified function or operation, or using a combination of dedicated hardware and computer instructions.

[0174] The modules described in the embodiments of this disclosure can be implemented in software or in hardware. The names of the modules do not necessarily limit the module itself; for example, a feature extraction module can also be described as "a module that extracts foreground and background features from source domain images in a source domain dataset and target domain images in a target domain dataset based on a polyp detection model, to obtain first source domain features and first target domain features."

[0175] The functions described above in this document can be performed, at least in part, by one or more hardware logic components. For example, exemplary types of hardware logic components that can be used, without limitation, include: Field Programmable Gate Arrays (FPGAs), Application-Specific Integrated Circuits (ASICs), Application Standard Products (ASSPs), System-on-Chip (SoCs), Complex Programmable Logic Devices (CPLDs), and so on.

[0176] In the context of this disclosure, a machine-readable medium can be a tangible medium that may contain or store a program for use by or in conjunction with an instruction execution system, apparatus, or device. A machine-readable medium can be a machine-readable signal medium or a machine-readable storage medium. A machine-readable medium can be, but is not limited to, electronic, magnetic, optical, electromagnetic, infrared, or semiconductor systems, apparatus, or devices, or any suitable combination of the foregoing. More specific examples of machine-readable storage media include electrical connections based on one or more wires, portable computer disks, hard disks, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or flash memory), optical fiber, portable compact disk read-only memory (CD-ROM), optical storage devices, magnetic storage devices, or any suitable combination of the foregoing.

[0177] According to one or more embodiments of this disclosure, Example 1 provides a training method for a polyp detection model, wherein the method includes: extracting foreground and background features from source domain images in a source domain dataset and target domain images in a target domain dataset based on the polyp detection model to obtain first source domain features and first target domain features, wherein the images in the source domain dataset are labeled with polyp tags, the images in the target domain dataset are not labeled, and the data distributions of the source domain dataset and the target domain dataset are different; and determining source domain foreground nodes in the source domain images and target nodes in the target domain images based on the first source domain features and the first target domain features. The process involves identifying foreground nodes in the source and target domains; determining correlation parameters between each source and target foreground node based on these parameters; updating the first source domain features and the first target domain features according to these correlation parameters to obtain second source domain features and second target domain features; obtaining a prediction result corresponding to the source domain image based on the second source domain features; determining the target loss of the polyp detection model based on the prediction result corresponding to the source domain image, the polyp label, the second source domain features, and the second target domain features; and training the polyp detection model based on the target loss.

[0178] According to one or more embodiments of this disclosure, Example 2 provides the method of Example 1, wherein determining a source domain foreground node in the source domain image and a target domain foreground node in the target domain image based on the first source domain feature and the first target domain feature includes: determining a set of candidate foreground nodes corresponding to the first source domain feature based on the polyp label; for each candidate foreground node in the set of candidate foreground nodes, determining a target domain matching foreground node in the first target domain feature corresponding to the candidate foreground node, and determining the source domain matching foreground node in the first source domain feature as the source domain matching foreground node of the target domain matching foreground node; if the source domain matching foreground node belongs to the set of candidate foreground nodes, determining the candidate foreground node as the source domain foreground node, and determining the target domain matching foreground node as the target domain foreground node.

[0179] According to one or more embodiments of this disclosure, Example 3 provides the method of Example 1, wherein determining the correlation parameter between each source domain foreground node and each target domain foreground node based on the source domain foreground node and the target domain foreground node includes: determining the correlation parameter between the i-th source domain foreground node and the j-th target domain foreground node using the following formula.

[0180] in, The first source domain feature is used to represent the i-th source domain foreground node in the source domain image s;

[0181] The first target domain feature used to represent the j-th target domain foreground node in the target domain image t;

[0182] σ is used to represent the tuning hyperparameter.

[0183] According to one or more embodiments of this disclosure, Example 4 provides the method of Example 1, wherein updating the first source domain feature and the first target domain feature according to the correlation parameter to obtain the second source domain feature and the second target domain feature respectively includes: performing multi-layer convolutional feature extraction on the first source domain feature based on the correlation parameter to obtain the second source domain feature; and performing multi-layer convolutional feature extraction on the first target domain feature based on the correlation parameter to obtain the second target domain feature, wherein the number of convolutional feature extraction layers corresponding to the first source domain feature and the first target domain feature is the same.

[0184] According to one or more embodiments of this disclosure, Example 5 provides the method of Example 4, wherein the second source domain features are obtained by performing multi-layer convolutional feature extraction on the first source domain features based on the correlation parameter using the following formula:

[0185]

[0186] Among them, A st A matrix representing the correlation parameters between source foreground nodes in source image s and target foreground nodes in target image t; I represents the identity matrix; D' represents A. st The degree matrix, where D' ii =∑ j A' ij H (l) Used to represent the convolutional features corresponding to the l-th layer, where the convolutional features corresponding to the 0th layer are the first source domain features; H l+1 Used to represent the convolutional features corresponding to the (l+1)th layer; W (l) The parameter η is used to represent the weight parameters corresponding to the l-th layer; η() is used to represent the nonlinear activation function.

[0187] According to one or more embodiments of this disclosure, Example 6 provides the method of Example 1, wherein the foreground and background feature extraction of a source domain image in a source domain dataset and a target domain image in a target domain dataset based on a polyp detection model to obtain a first source domain feature and a first target domain feature includes: for a target image, performing feature extraction on the target image based on the backbone network in the polyp detection model to obtain image features, wherein the target image includes the source domain image and the target domain image; performing region of interest feature extraction on the image features to obtain region of interest features; and fusing the image features and the region of interest features to obtain a first domain feature, wherein the first domain feature includes a first source domain feature corresponding to the source domain image and a first target domain feature corresponding to the target domain image.

[0188] According to one or more embodiments of this disclosure, Example 7 provides the method of Example 1, wherein the polyp label includes a location label and a classification label; the step of determining the target loss of the polyp detection model based on the prediction result corresponding to the source domain image and the polyp label, as well as the second source domain features and the second target domain features, includes: determining a regression loss based on the predicted location information in the prediction result and the location label; determining a classification loss based on the predicted classification information in the prediction result and the classification label; determining a feature loss based on the second source domain features and the second target domain features; and determining the target loss based on the regression loss, the classification loss, and the feature loss.

[0189] According to one or more embodiments of this disclosure, Example 8 provides the method of Example 7, wherein the feature loss is determined based on the second source domain features and the second target domain features using the following formula:

[0190]

[0191] Among them, L cst Used to represent the feature loss; N s N is used to represent the number of foreground nodes in the source domain; t Used to represent the number of foreground nodes in the target domain; x i s Used to represent the feature corresponding to the i-th source domain foreground node in the second source domain features; x j t This is used to represent the feature corresponding to the j-th target domain foreground node in the second target domain features.

[0192] According to one or more embodiments of this disclosure, Example 9 provides a polyp detection method, the method comprising: receiving a target image to be detected; inputting the target image into a trained polyp detection model to obtain a polyp detection result corresponding to the target image, wherein the polyp detection model is trained based on the training method of the polyp detection model in any one of Examples 1-8.

[0193] According to one or more embodiments of this disclosure, Example 10 provides a training apparatus for a polyp detection model, the apparatus comprising: a feature extraction module, configured to extract foreground and background features from source domain images in a source domain dataset and target domain images in a target domain dataset based on the polyp detection model, to obtain first source domain features and first target domain features, wherein the images in the source domain dataset are labeled with polyp tags, the images in the target domain dataset are not labeled, and the data distributions of the source domain dataset and the target domain dataset are different; a first determination module, configured to determine source domain foreground nodes in the source domain images and target domain foreground nodes in the target domain images based on the first source domain features and the first target domain features; The two modules are: a determination module, used to determine the correlation parameter between each source domain foreground node and each target domain foreground node based on the source domain foreground node and the target domain foreground node; an update module, used to update the first source domain feature and the first target domain feature respectively based on the correlation parameter to obtain the second source domain feature and the second target domain feature; a prediction module, used to obtain the prediction result corresponding to the source domain image based on the second source domain feature; and a training module, used to determine the target loss of the polyp detection model based on the prediction result corresponding to the source domain image, the polyp label, and the second source domain feature and the second target domain feature, and to train the polyp detection model based on the target loss.

[0194] According to one or more embodiments of this disclosure, Example 11 provides a polyp detection device, the device comprising: a receiving module for receiving a target image to be detected; and a processing module for inputting the target image into a trained polyp detection model to obtain a polyp detection result corresponding to the target image, wherein the polyp detection model is trained based on the training method of the polyp detection model in any one of Examples 1-8.

[0195] According to one or more embodiments of the present disclosure, Example 12 provides a computer-readable medium having a computer program stored thereon that, when executed by a processing device, implements the steps of the method described in any one of Examples 1-9.

[0196] According to one or more embodiments of this disclosure, Example 13 provides an electronic device comprising:

[0197] A storage device having a computer program stored thereon; a processing device for executing the computer program in the storage device to implement the steps of any of the methods described in Examples 1-9.

[0198] The above description is merely a preferred embodiment of this disclosure and an explanation of the technical principles employed. Those skilled in the art should understand that the scope of this disclosure is not limited to technical solutions formed by specific combinations of the above-described technical features, but should also cover other technical solutions formed by arbitrary combinations of the above-described technical features or their equivalents without departing from the above-described concept. For example, technical solutions formed by substituting the above features with (but not limited to) technical features disclosed in this disclosure that have similar functions.

[0199] Furthermore, while the operations are described in a specific order, this should not be construed as requiring these operations to be performed in the specific order shown or in a sequential order. In certain environments, multitasking and parallel processing may be advantageous. Similarly, while several specific implementation details are included in the above discussion, these should not be construed as limiting the scope of this disclosure. Certain features described in the context of individual embodiments may also be implemented in combination in a single embodiment. Conversely, various features described in the context of a single embodiment may also be implemented individually or in any suitable sub-combination in multiple embodiments.

[0200] Although the subject matter has been described using language specific to structural features and / or methodological logic, it should be understood that the subject matter defined in the appended claims is not necessarily limited to the specific features or actions described above. Rather, the specific features and actions described above are merely illustrative forms of implementing the claims. Regarding the apparatus in the above embodiments, the specific manner in which the various modules perform their operations has been described in detail in the embodiments relating to the method, and will not be elaborated upon here.

Claims

1. A training method for a polyp detection model, characterized in that, The method includes: Based on the polyp detection model, foreground and background features are extracted from source domain images in the source domain dataset and target domain images in the target domain dataset to obtain first source domain features and first target domain features. The images in the source domain dataset are labeled with polyp tags, while the images in the target domain dataset are not labeled. The data distributions of the source domain dataset and the target domain dataset are different. The set of candidate foreground nodes corresponding to the first source domain feature is determined based on the polyp label; For each candidate foreground node in the candidate foreground node set, determine the target domain matching foreground node in the first target domain feature corresponding to the candidate foreground node, and determine the source domain matching foreground node in the first source domain feature of the target domain matching foreground node; If the source domain matching foreground node belongs to the candidate foreground node set, the candidate foreground node is determined as the source domain foreground node in the source domain image, and the target domain matching foreground node is determined as the target domain foreground node in the target domain image; Based on the source domain foreground nodes and the target domain foreground nodes, determine the correlation parameters between each source domain foreground node and each target domain foreground node; The first source domain features and the first target domain features are updated according to the correlation parameters to obtain the second source domain features and the second target domain features. The prediction result corresponding to the source domain image is obtained based on the second source domain feature; Based on the prediction results corresponding to the source domain image, the polyp label, the second source domain features, and the second target domain features, the target loss of the polyp detection model is determined, and the polyp detection model is trained based on the target loss.

2. The method according to claim 1, characterized in that, The step of determining the correlation parameter between each source domain foreground node and each target domain foreground node based on the source domain foreground node and the target domain foreground node includes: The number is determined by the following formula. i The source domain foreground node and the first j Correlation parameters between foreground nodes in the target domain : in, Used to represent source domain image s The first in i The first source domain feature corresponding to each source domain foreground node; Used to represent the target domain image t The first in j The first target domain feature corresponding to each target domain foreground node; Used to represent the adjustment of hyperparameters.

3. The method according to claim 1, characterized in that, The first source domain features and the first target domain features are updated according to the correlation parameters to obtain second source domain features and second target domain features, including: Based on the correlation parameters, multi-layer convolutional feature extraction is performed on the first source domain features to obtain the second source domain features; Based on the correlation parameters, multi-layer convolutional feature extraction is performed on the first target domain features to obtain the second target domain features, wherein the number of convolutional feature extraction layers corresponding to the first source domain features and the first target domain features is the same.

4. The method according to claim 3, characterized in that, The second source domain features are obtained by performing multi-layer convolutional feature extraction on the first source domain features based on the correlation parameters using the following formula: , , in, For source domain images s Source domain foreground nodes and target domain images t A matrix of correlation parameters between foreground nodes in the target domain; I Used to represent the identity matrix; Used to represent The degree matrix, where, ; Used to indicate the first l The convolutional features corresponding to each layer, wherein the convolutional features corresponding to the 0th layer are the first source domain features; Used to indicate the first l+1 The convolutional features corresponding to the layer; Used to indicate the first l The weight parameters corresponding to the layer; Used to represent nonlinear activation functions.

5. The method according to claim 1, characterized in that, The polyp detection model is used to extract foreground and background features from source domain images in the source domain dataset and target domain images in the target domain dataset to obtain first source domain features and first target domain features, including: For the target image, feature extraction is performed on the target image based on the backbone network in the polyp detection model to obtain image features, wherein the target image includes the source domain image and the target domain image; The region of interest (ROI) features are extracted from the image features to obtain the ROI features; The image features and the region of interest features are fused to obtain first domain features, wherein the first domain features include first source domain features corresponding to the source domain image and first target domain features corresponding to the target domain image.

6. The method according to claim 1, characterized in that, The polyp label includes a location label and a classification label; The step of determining the target loss of the polyp detection model based on the prediction result corresponding to the source domain image, the polyp label, the second source domain features, and the second target domain features includes: The regression loss is determined based on the predicted location information and the location label in the prediction results; The classification loss is determined based on the predicted classification information and the classification label in the prediction results; The feature loss is determined based on the second source domain features and the second target domain features; The target loss is determined based on the regression loss, the classification loss, and the feature loss.

7. The method according to claim 6, characterized in that, The feature loss is determined using the following formula based on the features of the second source domain and the features of the second target domain: in, Used to represent the feature loss; Used to represent the number of foreground nodes in the source domain; Used to represent the number of foreground nodes in the target domain; Used to represent the second source domain feature of the first i Features corresponding to each source domain foreground node; Used to represent the first feature in the second target domain j Features corresponding to each foreground node in the target domain.

8. A method for detecting polyps, characterized in that, The method includes: Received the target image for detection; The target image is input into the trained polyp detection model to obtain the polyp detection result corresponding to the target image, wherein the polyp detection model is trained based on the training method of the polyp detection model according to any one of claims 1-7.

9. A training device for a polyp detection model, characterized in that, The device includes: The feature extraction module is used to extract foreground and background features from source domain images in the source domain dataset and target domain images in the target domain dataset based on the polyp detection model, to obtain first source domain features and first target domain features. The images in the source domain dataset are labeled with polyp tags, while the images in the target domain dataset are not labeled. The data distributions of the source domain dataset and the target domain dataset are different. The first determining module is configured to: determine a set of candidate foreground nodes corresponding to the first source domain features based on the polyp label; for each candidate foreground node in the set of candidate foreground nodes, determine a target domain matching foreground node in the first target domain features corresponding to the candidate foreground node, and determine the source domain matching foreground node in the first source domain features of the target domain matching foreground node; if the source domain matching foreground node belongs to the set of candidate foreground nodes, determine the candidate foreground node as the source domain foreground node in the source domain image, and determine the target domain matching foreground node as the target domain foreground node in the target domain image; The second determining module is used to determine the correlation parameter between each source domain foreground node and each target domain foreground node based on the source domain foreground node and the target domain foreground node; The update module is used to update the first source domain features and the first target domain features according to the correlation parameters respectively, so as to obtain the second source domain features and the second target domain features. The prediction module is used to obtain the prediction result corresponding to the source domain image based on the second source domain features; The training module is used to determine the target loss of the polyp detection model based on the prediction results corresponding to the source domain image, the polyp label, the second source domain features, and the second target domain features, and to train the polyp detection model based on the target loss.

10. A polyp detection device, characterized in that, The device includes: The receiving module is used to receive the detected target image; The processing module is used to input the target image into the trained polyp detection model to obtain the polyp detection result corresponding to the target image, wherein the polyp detection model is trained based on the training method of the polyp detection model according to any one of claims 1-7.

11. A computer-readable medium having a computer program stored thereon, characterized in that, When the program is executed by the processing device, it implements the steps of the method described in any one of claims 1-8.

12. An electronic device, characterized in that, include: A storage device on which computer programs are stored; A processing device for executing the computer program in the storage device to implement the steps of the method according to any one of claims 1-8.

Citation Information

Patent Citations

  • Image segmentation method and device, equipment and storage medium

    CN113706551A

  • Training method based on image-instance alignment network and cross-domain target detection method

    CN114693983A