Skin cancer image segmentation method and device based on polar coordinate conversion enhanced attention module of U-Net

By introducing polar coordinate transformation and enhanced attention modules into the U-Net network, the problem of insufficient feature extraction accuracy in skin cancer image segmentation of traditional U-Net is solved, and more efficient skin cancer image segmentation results are achieved.

CN115830317BActive Publication Date: 2025-12-23HENAN UNIVERSITY
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202211481279.0
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-11-24
Publication Date
2025-12-23
Estimated Expiration
2042-11-24

AI Technical Summary

Technical Problem

Traditional U-Net networks suffer from decreased feature extraction accuracy in skin cancer image segmentation, resulting in poor segmentation performance, especially in complex images.

Method used

We employ a U-Net enhanced attention module based on polar coordinate transformation. By adding an enhanced attention module to the U-Net network and transforming the image from Cartesian coordinates to polar coordinates for training, we combine it with a stacked hourglass network to predict the center point coordinates for data augmentation and feature fusion.

Benefits of technology

It improves the accuracy and robustness of skin cancer image segmentation, reduces the computational complexity and memory requirements of the model, and enhances feature representation and detection efficiency.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115830317B_ABST
    Figure CN115830317B_ABST
Patent Text Reader

Abstract

The application provides a skin cancer image segmentation method and device based on a polar coordinate conversion U-Net enhanced attention module. The method comprises the following steps: collecting skin cancer images to construct a data set, dividing the data set into a training set, a validation set and a test set, and performing polar coordinate conversion on the data set; step 2: constructing a segmentation network; the segmentation network takes U-Net as a basic framework, and increases an enhanced attention module at a skip connection position before a decoder; step 3: designing a loss function, training the segmentation network by using the training set after polar coordinate conversion, and testing the performance of the trained segmentation network by using the validation set after polar coordinate conversion; step 4: inputting a to-be-tested image in the test set after polar coordinate conversion into the trained segmentation network to obtain a segmentation result in a polar coordinate system, and converting the segmentation result in the polar coordinate system to a Cartesian coordinate system, thereby obtaining a final segmentation result.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the technical field of medical image segmentation, in particular to a skin cancer image segmentation method and device based on polar coordinate conversion and U-Net enhanced attention module. BACKGROUND

[0002] Skin cancer (melanoma) is a malignant tumor of melanocytes in the basal layer of the epidermis, accounting for about 3% of skin malignant tumors. Early diagnosis of skin melanoma is crucial for its successful treatment.

[0003] For doctors, checking the lesion information in the skin cancer medical image by artificial means is a complex work. The traditional doctor reading method often needs to consume a lot of time and energy, and the accuracy of diagnosis mainly depends on the level and work experience of doctors. Due to visual fatigue, environmental interference and other reasons, misdiagnosis and missed diagnosis may occur.

[0004] With the rapid development and popularization of medical imaging equipment, imaging technologies including magnetic resonance imaging (MRI), computed tomography (CT), ultrasound, positron emission tomography (PET), etc. have become indispensable equipment for medical institutions to carry out disease diagnosis. Today, a large amount of medical imaging information is generated every day around the world. Medical image processing is the first step in analyzing medical images, which helps to make the image more intuitive and clear, and improves the diagnosis efficiency. Image segmentation is an important part of image processing, but also a difficulty, which is a bottleneck problem restricting the application of three-dimensional reconstruction and other technologies. In recent years, due to the rapid development of deep learning methods, image segmentation algorithms based on deep learning have made remarkable achievements in the field of medical image segmentation. For example, using traditional U-Net for image segmentation, first extracting features from the image through downsampling, and then restoring the image to the original size through upsampling to achieve the purpose of segmentation. However, in complex images (such as skin cancer images), the accuracy of the network decreases when extracting features, and the segmentation effect is also affected. SUMMARY

[0005] In order to improve the segmentation effect of the image segmentation method suitable for skin cancer images, the present application provides a skin cancer image segmentation method and device based on polar coordinate conversion and U-Net enhanced attention module.

[0006] In one aspect, the present application provides a skin cancer image segmentation method based on polar coordinate conversion and U-Net enhanced attention module, comprising:

[0007] Step 1: collect skin cancer images to construct a data set, divide the data set into a training set, a validation set and a test set; and perform polar coordinate conversion on the data set;

[0008] Step 2: constructing a segmentation network; the segmentation network takes U-Net as a basic framework, and adds an enhanced attention module at the position of the jump connection before the decoder;

[0009] Step 3: designing a loss function, training the segmentation network using the training set after polar coordinate conversion, and testing the performance of the trained segmentation network using the validation set after polar coordinate conversion until the training stops when the performance requirement is met;

[0010] Step 4: inputting the test image in the test set after polar coordinate conversion into the trained segmentation network to obtain the segmentation result in the polar coordinate system, and converting the segmentation result in the polar coordinate system to the Cartesian coordinate system, which is the final segmentation result.

[0011] Further, in step 1, before the polar coordinate conversion, it also includes: checking the data set to filter out the skin cancer images that do not meet the requirements; and performing data augmentation on the training set.

[0012] Further, the data augmentation specifically includes: converting the original image into a tensor image, setting the mean vector and variance vector, and then normalizing the tensor image; randomly rotating, randomly affine transforming and center cropping the normalized tensor image.

[0013] Further, the polar coordinate conversion specifically includes:

[0014] A center predictor is trained using a stacked hourglass network, and the center point coordinates of the input skin cancer image are predicted using the center predictor, denoted as (c x ,c y );

[0015] The input skin cancer image is converted from the Cartesian coordinate system to the polar coordinate system according to the center point coordinates (c x ,c y ).

[0016] Further, the stacked hourglass network includes a plurality of serially connected hourglass blocks; each hourglass block adopts an encoding-decoding structure; the processing process of the stacked hourglass network includes: the feature map C output by the current hourglass block is divided into a first branch and a second branch after passing through a 1x1 convolution, and then the output of the first branch and the output of the second branch are concatenated and used as the input of the next hourglass block; wherein, the processing process of the first branch is: output after passing through a 1x1 convolution; the processing process of the second branch is to generate a heat map, and the heat map is output after passing through a 1x1 convolution; the peak value of the feature heat map output by the last hourglass block is the center point coordinates.

[0017] Further, the loss function for training the stacked hourglass network is designed as follows:

[0018]

[0019]

[0020]

[0021] wherein, W represents the total loss of the stacked hourglass network, H i represents the loss of the gap between the i-th heat map predicted center point and the real center point, DL i represents the loss in the i-th hourglass block, y i represents the real center point, represents the predicted center point; N represents the number of hourglass blocks.

[0022] Further, the input skin cancer image is converted from Cartesian coordinates to polar coordinates according to the center point coordinates (c x ,c y ), specifically including:

[0023] angle(x,y) and the edge size magnitude(x,y) of the pixel points (x,y) of the original skin cancer image are calculated;

[0024] The polar coordinates of the pixel points (x,y) in the polar coordinate system are calculated according to formula (1)

[0025]

[0026] wherein, W and H represent the width and height of the input skin cancer image, and p is the radial coordinate, is the angular coordinate.

[0027] Further, in step 2, the processing process of the enhanced attention module specifically includes:

[0028] The low-level feature map input into the enhanced attention module is denoted as C1, and the high-level feature map input into the enhanced attention module is denoted as C2; the low-level feature map C1 is divided into two branches, a first branch and a second branch; the high-level feature map C2 is divided into two branches, a third branch and a fourth branch; the output of the first branch is added to the output of the third branch, and then after 1×1 convolution, the attention vector A c is obtained; the attention vector A c is multiplied by the output of the second branch to obtain the required feature mapping; the feature mapping is added to the fourth branch to obtain the output of the enhanced attention module;

[0029] Wherein, the first branch firstly obtains a new vector G1 through global average pooling, and then the vector G1 is output after 1*1 convolution; the second branch is output after 1*1 convolution; the third branch firstly obtains a new vector G2 through global average pooling, and then the vector G2 is output after 1*1 convolution; the high-level feature map C2 is directly taken as the output of the fourth branch.

[0030] Further, in step 3, the loss function L is shown as formula (2):

[0031]

[0032] Wherein, BCELoss represents binary cross entropy loss, DL represents Dice loss, theta is weight, y is real value, is a prediction value, is the number of samples corresponding to the intersection between the prediction value and the real value, |y| is the number of samples corresponding to the real value, is the number of samples corresponding to the prediction value.

[0033] On the other hand, the application provides a skin cancer image segmentation device based on polar coordinate conversion and U-Net enhanced attention module, comprising:

[0034] A data set module is used to collect skin cancer images to construct a data set, divide the data set into a training set, a validation set and a test set, and perform polar coordinate conversion on the data set.

[0035] A segmentation network construction module is used to construct a segmentation network; the segmentation network takes U-Net as a basic framework, and increases an enhanced attention module at a skip connection position before a decoder;

[0036] A model training module is used to train the segmentation network based on a designed loss function, using a training set after polar coordinate conversion, and to perform performance testing on the trained segmentation network using a validation set after polar coordinate conversion until the training is stopped when the set performance requirement is met.

[0037] A test module is used to input an image to be tested in a test set after polar coordinate conversion into the trained segmentation network to obtain a segmentation result in a polar coordinate system, and convert the segmentation result in the polar coordinate system to a Cartesian coordinate system, which is the final segmentation result.

[0038] The beneficial effects of the application are:

[0039] (1) In this invention, the image is transformed from Cartesian coordinates to polar coordinates, and then a segmentation network model is trained in polar coordinates. Since polar coordinate transformation can reduce dimensionality, the segmentation network in polar coordinates has a shorter convergence time than the segmentation network in Cartesian coordinates, and it also has good performance even in models with fewer parameters. The segmentation network in polar coordinates is also more robust to low dataset sample sizes. Experiments show that the segmentation network trained in this invention can successfully predict the boundary of lesion skin and exhibits good scale invariance.

[0040] (2) A network with a stacked hourglass structure is used to find the center point of polar coordinates, thereby supporting the subsequent polar coordinate transformation process;

[0041] (3) Using the enhanced attention module, the attention mechanism is applied to feature fusion, which emphasizes the target region and improves feature representation, fuses multi-level features and captures global information, improves segmentation accuracy and adds only a few parameters, which helps to save memory, suppress irrelevant noise and thus improve detection efficiency. Attached Figure Description

[0042] Figure 1 A schematic flowchart of a skin cancer image segmentation method based on polar coordinate transformation using a U-Net enhanced attention module provided in an embodiment of the present invention;

[0043] Figure 2 This is a schematic diagram of the stacked hourglass network provided in an embodiment of the present invention;

[0044] Figure 3 This is a schematic diagram of the segmentation network provided in an embodiment of the present invention;

[0045] Figure 4 A schematic diagram illustrating the processing procedure of the enhanced attention module provided in an embodiment of the present invention; Detailed Implementation

[0046] To make the objectives, technical solutions, and advantages of this invention clearer, the technical solutions of the embodiments of this invention will be clearly described below with reference to the accompanying drawings. Obviously, the described embodiments are only some, not all, of the embodiments of this invention. All other embodiments obtained by those skilled in the art based on the embodiments of this invention without creative effort are within the scope of protection of this invention.

[0047] Example 1

[0048] like Figure 1 As shown, this embodiment of the invention provides a skin cancer image segmentation method based on a U-Net enhanced attention module using polar coordinate transformation, characterized by comprising:

[0049] S101: collect skin cancer images to construct a dataset, divide the dataset into a training set, a validation set and a test set; and perform polar coordinate conversion on the dataset;

[0050] Specifically, before performing the polar coordinate conversion, further comprising: checking the dataset to exclude skin cancer images that do not meet the requirements, such as manually cleaning missing values and noise data; and performing data augmentation on the training set to further enhance image features and expand the dataset; specifically comprising: converting the original image into a tensor image, setting the mean vector and variance vector, and then normalizing the tensor image; performing random rotation, random affine transformation and center cropping on the normalized tensor image.

[0051] For example, set the mean vector std to [0.485, 0.456, 0.406], and the variance vector mean to [0.229, 0.224, 0.225], and the normalized output is: output=(input-mean) / std;wherein, input represents the original tensor image. For example, the random rotation is degrees for ±30°; for example, the scaling ratio of the random affine transformation is scale=(0.7, 0.7). For example, set the original size of each original tensor image to 700×900, and use center cropping to uniformly cut all tensor images from the center to an image of 256×256 size.

[0052] As an implementable manner, the polar coordinate conversion specifically comprises:

[0053] Specifically, first, a center predictor is trained using a stacked hourglass network, the center predictor is used to predict the center point coordinates of the input skin cancer image, denoted as (c x ,c y );

[0054] In the embodiment of the present application, as shown in Figure 2 , the stacked hourglass network comprises 4 hourglass blocks connected in series (also referred to as hourglass network structure); each hourglass block adopts an encoding-decoding structure; the processing process of the stacked hourglass network comprises: the feature map C output by the current hourglass block is divided into a first branch and a second branch after 1×1 convolution, then the output of the first branch and the output of the second branch are concatenated to serve as the input of the next hourglass block; wherein, the processing process of the first branch is: output after 1×1 convolution; the processing process of the second branch is to generate a heat map, and the heat map is output after 1×1 convolution; the peak value of the feature heat map output by the last hourglass block is the center point coordinates.

[0055] The stacked hourglass network uses multiple up-sampling and down-sampling, constantly fuses spatial information, and coherently fuses the information of each key point together, and finally outputs a pixel-based prediction to obtain the center point. The heat map of the first hourglass block makes a probability prediction for each pixel, and the heat map shows the density and height of the density. Through the heat map, the probability of the pixel being a key point can be calculated, so as to determine the relationship between the key points. The current hourglass block further abstracts and induces the relationship of all key points based on the heat map output by the previous hourglass block, and the four hourglass blocks continuously refine the key point prediction, so that the prediction accuracy of the center point is improved.

[0056] It should be noted that the loss function for training the stacked hourglass network is designed as follows:

[0057]

[0058] Wherein, W represents the total loss of the stacked hourglass network, H i represents the loss of the difference between the i-th heat map predicted center point and the real center point, DL i represents the loss in the i-th hourglass block, y i represents the real center point, represents the predicted center point; N represents the number of hourglass blocks, and in the embodiment, N = 4.

[0059] Then, the input skin cancer image is converted from the Cartesian coordinate system to the polar coordinate system according to the center point coordinates (c x ,c y ).

[0060] Specifically, first, the angle angle(x,y) and the edge size magnitude(x,y) of the pixel point (x,y) of the original skin cancer image are calculated; specifically:

[0061] Then, the polar coordinates of the pixel point (x,y) in the polar coordinate system are calculated according to formula (1)

[0062]

[0063] Wherein, W and H represent the width and height of the input skin cancer image. In the polar coordinate system, p is the radial coordinate, is the angular coordinate.

[0064] S102: Construct a segmentation network; as shown in Figure 3 The segmentation network takes U-Net as the basic framework, and increases the enhanced attention module at the position of the skip connection before the decoder;

[0065] Specifically, asFigure 4 As shown, the processing procedure of the enhanced attention module specifically includes:

[0066] Let C1 (C1×H×W) denote the low-level feature map in the input enhancement attention module, and C2 (C2×H×W) denote the high-level feature map in the input enhancement attention module; divide the low-level feature map C1 into two branches, the first branch and the second branch; divide the high-level feature map C2 into two branches, the third branch and the fourth branch; add and concatenate the outputs of the first branch and the third branch (let the resulting vector be denoted as G). a The vector of interest, A, is obtained by performing a 1×1 convolution on (x, y) (which may also include normalization using the softmax function). c Focus on vector A c The desired feature map is obtained by multiplying it with the output of the second branch; the feature map is then added to and concatenated with the fourth branch to obtain the output of the enhanced attention module.

[0067] The first branch first undergoes global average pooling to obtain a new vector G1, and then vector G1 is output after a 1×1 convolution; the second branch is output after a 1×1 convolution; the third branch first undergoes global average pooling to obtain a new vector G2, and then vector G2 is output after a 1×1 convolution; the high-level feature map C2 is directly used as the output of the fourth branch.

[0068] Specifically, G a (x,y) can be represented as: W α W β b is the parameter of a 1×1 convolution. α b β Here, f is the bias, f is the global average pooling, and φ1 represents the ReLU function, specifically... Focus on vector A c It can be represented as: A c =φ2[W γ G a (x,y)+b γ ], W γ b is the parameter of a 1×1 convolution. γ For bias, φ2 represents the softmax function, specifically... The mapping interval is [0,1].

[0069] The role of the global average pooling is to extract global context and semantic information, compress the global information into a vector, and encode the semantic dependency information between channels. The role of the 1x1 convolution in the first branch and the second branch is to upgrade the low-level features. The role of the entire enhanced attention module is to compress the global information into an attention vector, encode the semantic dependency relationship, emphasize the key features, and filter the useless background information.

[0070] S103: design a loss function, train the segmentation network using the training set after polar coordinate conversion, and test the performance of the trained segmentation network using the validation set after polar coordinate conversion to determine whether the segmentation network after stopping training meets the given performance requirements, thereby determining whether further training is needed.

[0071] Specifically, the designed loss function L is shown in formula (2):

[0072]

[0073] wherein, BCELoss represents the binary cross-entropy loss, DL represents the Dice loss, theta is the weight, y is the true value, is the predicted value, is the number of samples corresponding to the intersection between the predicted value and the true value, |y| is the number of samples corresponding to the true value, is the number of samples corresponding to the predicted value.

[0074] In addition, it also includes setting the initial learning rate of the network, the learning rate decay method, and the number of network iterations. The initial learning rate used here is 0.0001, the learning rate decay method is exponential decay, and the number of network iterations is 50 times.

[0075] S104: input the test image in the test set after polar coordinate conversion into the trained segmentation network to obtain the segmentation result in the polar coordinate system, and convert the segmentation result in the polar coordinate system to the Cartesian coordinate system, which is the final segmentation result.

[0076] The application converts the original data set to polar coordinates, and converts the image in the Cartesian coordinate system to the image in the polar coordinate system. The polar coordinate system modeling contour simplifies the problem and reduces the amount of calculation. The fixed angle prior information can be used to further simplify the problem. The enhanced attention module combines the semantic information in the captured high-level feature map and the global context in the captured low-level feature map to encode the semantic dependency. The high-level feature map contains rich semantic information and can be used to guide the low-level feature map to select important position information. The global context of the low-level feature map encodes the semantic relationship between different channels, thereby helping to filter out interference information. Therefore, by using these information, the enhanced attention module can emphasize the target area and improve the feature representation.

[0077] Embodiment 2

[0078] Corresponding to the above method, the embodiment of the application provides a skin cancer image segmentation device based on polar coordinate conversion U-Net enhanced attention module, comprising: a data set module, a segmentation network construction module, a model training module and a test module.

[0079] The data set module is used to collect skin cancer images to construct a data set, divide the data set into a training set, a validation set and a test set, and perform polar coordinate conversion on the data set. The segmentation network construction module is used to construct a segmentation network. The segmentation network takes U-Net as a basic framework, and adds an enhanced attention module at the position of the skip connection before the decoder. The model training module is used to train the segmentation network based on the designed loss function, and uses the training set after polar coordinate conversion to test the performance of the trained segmentation network. The test module is used to input the test image in the test set after polar coordinate conversion into the trained segmentation network to obtain the segmentation result in the polar coordinate system. The segmentation result in the polar coordinate system is converted to the Cartesian coordinate system, which is the final segmentation result.

[0080] It should be noted that the device provided by the embodiment of the application is used to realize the above-mentioned method embodiments, and its functions can be referred to the above-mentioned method embodiments, which will not be repeated here.

[0081] Finally, it should be noted that: the above embodiments are only used to illustrate the technical solutions of the application, and not to limit them; although the application has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that: it can still modify the technical solutions recorded in the foregoing embodiments, or make equivalent replacement for part of the technical features; and these modifications or replacements do not make the essence of the corresponding technical solutions deviate from the spirit and scope of the technical solutions of the embodiments of the application.

Claims

1. A skin cancer image segmentation method based on polar coordinate conversion enhanced attention module of U-Net, characterized in that, The application relates to a skin cancer segmentation method based on polar coordinate conversion and a stacked hourglass network. Step 1: collecting skin cancer images to construct a data set, dividing the data set into a training set, a verification set and a test set, and performing polar coordinate conversion on the data set; Step 2: constructing a segmentation network; the segmentation network takes U-Net as a basic framework and adds an enhanced attention module at a position of a skip connection located before a decoder; The processing process of the enhanced attention module specifically comprises: The first branch is firstly subjected to global average pooling to obtain a new vector G1, and then the vector G1 is output after 1*1 convolution; the second branch is output after 1*1 convolution; the third branch is firstly subjected to global average pooling to obtain a new vector G2, and then the vector G2 is output after 1*1 convolution; and a high-level feature map C2 is directly taken as the output of the fourth branch; The low-level feature map in the input enhancement attention module is denoted as C1, and the high-level feature map in the input enhancement attention module is denoted as C2; the low-level feature map C1 is divided into a first branch and a second branch; the high-level feature map C2 is divided into a third branch and a fourth branch; the output of the first branch is added to the output of the third branch, and then a 1x1 convolution is performed to obtain an attention vector ; the attention vector is multiplied by the output of the second branch to obtain a required feature map; the feature map is added to the fourth branch to obtain the output of the enhancement attention module; Step 3: designing a loss function, training the segmentation network by using the training set subjected to polar coordinate conversion, and testing the performance of the trained segmentation network by using the verification set subjected to polar coordinate conversion; Step 4: inputting a to-be-tested image in the test set subjected to polar coordinate conversion into the trained segmentation network to obtain a segmentation result in a polar coordinate system, and converting the segmentation result in the polar coordinate system into a Cartesian coordinate system, so that the final segmentation result is obtained. In step 1, before the polar coordinate conversion is performed, the data set is further checked to screen out skin cancer images that do not meet the requirements, and data enhancement is performed on the training set.

2. The polar coordinate conversion-based skin cancer image segmentation method of claim 1, wherein, The data enhancement specifically comprises:

3. The polar coordinate conversion based skin cancer image segmentation method of claim 2, wherein, The original image is converted into a tensor image, a mean vector and a variance vector are set, and then the tensor image is standardized; the standardized tensor image is subjected to random rotation, random affine transformation and center cropping. The polar coordinate conversion specifically comprises:

4. The polar coordinate conversion based skin cancer image segmentation method of claim 1, wherein, The stacked hourglass network comprises a plurality of serially-connected hourglass blocks; each hourglass block adopts an encoding-decoding structure; and the processing process of the stacked hourglass network comprises: the feature map C output by a current hourglass block is divided into a first branch and a second branch after being subjected to 1*1 convolution, then the output of the first branch and the output of the second branch are subjected to concat operation and taken as the input of a next hourglass block; wherein the processing process of the first branch is: output after 1*1 convolution; the processing process of the second branch is: generating a heat map, and the heat map is output after being subjected to 1*1 convolution; and the peak value of the feature heat map output by the last hourglass block is the center point coordinate. A center predictor is trained using a stacked hourglass network, which is used to predict the center point coordinates of an input skin cancer image, denoted as ; According to the center point coordinates The input skin cancer image is converted from Cartesian coordinates to polar coordinates.

5. The polar coordinate conversion-based skin cancer image segmentation method of claim 4, wherein, The loss function for training the stacked hourglass network is designed as follows:

6. The polar coordinate conversion-based skin cancer image segmentation method of claim 4, wherein, In step 3, the loss function L is shown in formula (2): ; wherein, represents the total loss of the stacked hourglass network, represents the loss of the gap between the i-th heat map predicted center point and the real center point, represents the loss in the i-th hourglass block, represents the real center point, represents the predicted center point; N represents the number of hourglass blocks.

7. The polar coordinate conversion based skin cancer image segmentation method of claim 4, wherein, According to the center point coordinates Converting the input skin cancer image from a Cartesian coordinate system to a polar coordinate system, specifically comprising: Calculate the pixels of the original skin cancer image Angle and side size ; The pixel point is calculated according to formula (1) Polar coordinates in the polar coordinate system ; (1) wherein and denote the width and height of the input skin cancer image, p is the radial coordinate, and f is the angular coordinate.

8. The polar coordinate conversion based skin cancer image segmentation method of claim 1, wherein, The application relates to a skin cancer segmentation method based on polar coordinate conversion and a stacked hourglass network. (2) where BCELoss represents a binary cross-entropy loss, DL represents a Dice loss, is a weight, is a true value, is a predicted value, is a sample number corresponding to an intersection between the predicted value and the true value, is a sample number corresponding to the true value, is a sample number corresponding to the predicted value.

9. The skin cancer image segmentation device based on polar coordinate conversion enhanced attention module of claim 1, wherein, A data set module is used for collecting skin cancer images to construct a data set, dividing the data set into a training set, a verification set and a test set, and performing polar coordinate conversion on the data set; A segmentation network construction module is used for constructing a segmentation network; the segmentation network takes U-Net as a basic framework and adds an enhanced attention module at a position of a skip connection located before a decoder; The processing process of the enhanced attention module specifically comprises: ​ ​ The low-level feature map in the input enhancement attention module is denoted as C1, and the high-level feature map in the input enhancement attention module is denoted as C2; the low-level feature map C1 is divided into a first branch and a second branch; the high-level feature map C2 is divided into a third branch and a fourth branch; the output of the first branch is added to the output of the third branch, and then a 1x1 convolution is performed to obtain an attention vector ; the attention vector is multiplied by the output of the second branch to obtain a required feature map; the feature map is added to the fourth branch to obtain the output of the enhancement attention module. Among them, the first branch firstly passes through global average pooling to obtain a new vector G1, and then the vector G1 is output after passing through 1*1 convolution; the second branch is output after passing through 1*1 convolution; the third branch firstly passes through global average pooling to obtain a new vector G2, and then the vector G2 is output after passing through 1*1 convolution; the high-level feature map C2 is directly taken as the output of the fourth branch; The model training module is configured to train the segmentation network based on the designed loss function and the training set after polar coordinate conversion, and to perform performance testing on the trained segmentation network based on the validation set after polar coordinate conversion. The test module is configured to input the to-be-tested image in the test set after polar coordinate conversion into the trained segmentation network to obtain a segmentation result in the polar coordinate system, convert the segmentation result in the polar coordinate system to the Cartesian coordinate system, and obtain the final segmentation result.

Citation Information

Patent Citations

  • Medical image segmentation method based on double-type U-Net model

    CN113538346A

  • Medical image segmentation method based on u-net

    US20220309674A1