Cerebral hemorrhage image analysis method and device and electronic equipment
By using the image recognition model to encode and decode brain CT images in cerebral hemorrhage detection, and using the multiplexed target detection structure to identify the cerebral hemorrhage area, the accuracy and efficiency problems of cerebral hemorrhage detection in the existing technology are solved. , achieving rapid and accurate cerebral hemorrhage detection.
Patent Information
- Application Number
- CN202411452029.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-10-17
- Publication Date
- 2025-01-24
AI Technical Summary
The prior art is difficult to identify the cerebral hemorrhage areas in brain CT images in timely and accurately in the detection of cerebral hemorrhage, resulting in insufficient diagnostic efficiency and accuracy.
A cerebral hemorrhage image analysis method is adopted, and the target brain image is encoded through the image recognition model to generate hidden layers of characteristic diagrams, and the coding structure of the decoding structure and target detection structure is used to identify the cerebral hemorrhage area.
It improves the accuracy and efficiency of identifying cerebral hemorrhage areas, simplifies the construction of image recognition models, and reduces repeated coding steps in the target detection process, thereby achieving fast and accurate cerebral hemorrhage detection.
Smart Images

Figure CN119359998A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of image processing, and in particular to a method, device and electronic equipment for analyzing cerebral hemorrhage images. Background Art
[0002] Intracerebral hemorrhage (ICH) is a primary non-traumatic intracerebral hemorrhage, usually caused by non-traumatic vascular rupture. Currently, the diagnosis of ICH is mostly performed by CT (Computed Tomography) examination of the patient's head. Doctors can use brain CT images to analyze and judge. However, in emergency situations, doctors cannot promptly and accurately determine whether the patient has symptoms of ICH through CT images. Therefore, it is of great significance to be able to automatically identify the location of ICH in brain CT images.
[0003] With the development of deep learning technology, people have begun to use deep learning technology to detect relevant lesion areas in medical images, which has improved the accuracy and speed of lesion area detection. However, due to the complexity of the cerebral hemorrhage detection process, the recognition and analysis speed of cerebral hemorrhage areas still needs to be improved. Summary of the invention
[0004] To solve the above problems, an object of the embodiments of the present invention is to provide a method, device and electronic device for analyzing cerebral hemorrhage images.
[0005] In a first aspect, an embodiment of the present invention provides a method for analyzing an image of cerebral hemorrhage, comprising: Acquire a target brain image to be detected; Inputting the target brain image into a preset image recognition model; the image recognition model includes an encoding structure, a decoding structure and a target detection structure, and the decoding structure and the target detection structure reuse the encoding structure; Performing encoding processing on the target brain image according to the encoding structure to generate a hidden layer feature map; Decoding the hidden layer feature map according to the decoding structure to identify a valid area in the target brain image; Generate a mask feature map corresponding to the effective area, and perform a dot multiplication operation on the hidden layer feature map according to the mask feature map to generate an effective feature map; The effective feature map is subjected to target detection processing according to the target detection structure to identify the cerebral hemorrhage area in the target brain image.
[0006] In some optional implementations, the coding structure includes: n coding units arranged in sequence; the coding units include convolutional coding layers, and the first n-1 coding units also include downsampling layers; The convolutional coding layer is used to perform convolution processing on the input data to generate convolution processing results corresponding to a greater number of channels; the input data of the convolutional coding layer of the first coding unit is the input data of the coding structure; The downsampling layer is used to perform downsampling processing on the convolution processing result generated by the convolution coding layer to generate output data of the encoding unit; the output data of the encoding unit is the input data of the convolution coding layer of the next encoding unit.
[0007] In some optional implementations, the convolutional coding layer includes: a first convolutional sublayer, a second convolutional sublayer, and a first fusion layer arranged in sequence; the number of the second convolutional sublayer is multiple; The first convolution sublayer is used to perform convolution processing on the input data of the convolution coding layer according to a 1×1 convolution kernel to generate a first convolution processing result with a channel number of c1; c1>c0, c0 is the channel number of the input data of the convolution coding layer; the first convolution processing result is the input data of the first second convolution sublayer; The second convolution sublayer is used to perform convolution processing on the input data of the second convolution sublayer according to the convolution kernel of a×a, and generate a second convolution processing result whose number of channels is also c1; a>1; the second convolution processing result generated by the second convolution sublayer is the input data of the next second convolution sublayer; The first fusion layer is used to fuse the first convolution processing result and multiple second convolution processing results to generate the convolution processing result of the convolution coding layer.
[0008] In some optional implementations, performing a dot multiplication operation on the hidden layer feature map according to the mask feature map to generate a valid feature map includes: Performing a point multiplication operation on the convolution processing results of each of the convolution coding layers according to the mask feature graph to generate a corresponding valid feature subgraph; The target detection structure comprises: n target detection units arranged in sequence; the target detection units comprise convolution detection layers, and the first n-1 target detection units further comprise amplification layers; The convolution detection layer of the i-th target detection unit is used to perform addition processing on the output data of the i-1-th target detection unit and the effective feature subgraph generated based on the convolution processing result of the convolution coding layer of the n-i+1-th coding unit, and perform convolution processing on the addition processing result to generate a convolution processing result corresponding to a smaller number of channels; the input data of the convolution coding layer of the first coding unit is the input data of the coding structure; The amplification layer of the i-th target detection unit is used to perform upsampling on the convolution processing result generated by the convolution detection layer of the i-th target detection unit to generate the output data of the i-th target detection unit; the output data of the i-th target detection unit is used to be input into the convolution detection layer of the (i + 1)-th target detection unit.
[0009] In some alternative embodiments, the convolution detection layer includes: an addition layer, a third convolution sub-layer, a fourth convolution sub-layer, a fifth convolution sub-layer, and a second fusion layer; The addition layer is used to perform an addition operation on the output data of the previous target detection unit and the corresponding valid feature sub-map to generate an addition processing result; The third convolution sub-layer is used to perform convolution processing on the addition processing result of the addition layer according to a b×b convolution kernel to generate a third convolution processing result; b > 1; The fourth convolution sub-layer is used to perform convolution processing on the third convolution processing result according to a 1×b convolution kernel to generate a fourth convolution processing result with the number of channels being c2; c2 < c3, where c3 is the number of channels of the input data of the convolution detection layer; The fifth convolution sub-layer is used to perform convolution processing on the third convolution processing result according to a b×1 convolution kernel to generate a fifth convolution processing result with the number of channels being c2; The second fusion layer is used to perform a fusion operation on the fourth convolution processing result and the fifth convolution processing result to generate the convolution processing result of the convolution detection layer.
[0010] In some alternative embodiments, the performing a dot product operation on the convolution processing results of each of the convolution encoding layers according to the mask feature map to generate corresponding valid feature sub-maps includes: Performing a dot product operation on the convolution processing result of the convolution encoding layer of the first encoding unit and the mask feature map to generate a first valid feature sub-map; Performing j - 1 downsampling operations on the mask feature map in sequence; j ≥ 2; Performing a dot product operation on the convolution processing result of the convolution encoding layer of the j-th encoding unit and the mask feature map after j - 1 downsampling operations to generate a j-th valid feature sub-map.
[0011] In some alternative embodiments, the decoding structure includes: n - 1 decoding units arranged in sequence; the decoding unit includes an upsampling layer and a convolution decoding layer; The upsampling layer of the i-th decoding unit is used to perform upsampling on the input data of the i-th decoding unit to generate an upsampling result; the input data of the first decoding unit is the output data of the n-th encoding unit; The convolution decoding layer of the i-th decoding unit is used to add the upsampling result generated by the upsampling layer of the i-th decoding unit and the convolution processing result generated by the convolution coding layer of the ni-th encoding unit, and convolve the addition result to generate a convolution processing result corresponding to a smaller number of channels, and use the convolution processing result of the convolution decoding layer as the output data of the i-th decoding unit; the output data of the i-th decoding unit is used to input into the upsampling layer of the i+1-th decoding unit.
[0012] In some optional embodiments, the step of acquiring a target brain image to be detected includes: Acquire the collected original brain images; converting the original brain image into a target brain image; and: ;in, Indicates the first x Line y The pixel value of the pixel point in the column, Indicates the first x Line y The pixel value of the pixel point in the column, r is a preset exponential coefficient, and r>1.
[0013] In a second aspect, an embodiment of the present invention further provides a device for analyzing an image of cerebral hemorrhage, comprising: An image acquisition module, used for acquiring a target brain image to be detected; An input module, used to input the target brain image into a preset image recognition model; the image recognition model includes a coding structure, a decoding structure and a target detection structure, and the decoding structure and the target detection structure reuse the coding structure; An image segmentation module, configured to encode the target brain image according to the encoding structure to generate a hidden layer feature map; and decode the hidden layer feature map according to the decoding structure to identify a valid area in the target brain image; The target detection module is used to generate a mask feature map corresponding to the effective area, and perform a dot multiplication operation on the hidden layer feature map according to the mask feature map to generate an effective feature map; perform target detection processing on the effective feature map according to the target detection structure to identify the cerebral hemorrhage area in the target brain image.
[0014] In a third aspect, an embodiment of the present invention further provides an electronic device, including: at least one processor; and, a memory communicatively connected to the at least one processor; wherein, The memory stores instructions that can be executed by the at least one processor, and the instructions are executed by the at least one processor so that the at least one processor can execute any one of the above-mentioned cerebral hemorrhage image analysis methods.
[0015] In the solution provided in the first aspect of the embodiment of the present invention, an image recognition model is used to extract the effective area in the target brain area that is most likely to have cerebral hemorrhage, that is, the area where cerebral hemorrhage will not occur is excluded, thereby improving the accuracy of subsequent target detection; and, the decoding structure and the target detection structure reuse the encoding structure, that is, only one set of encoding structure needs to be trained and constructed, which not only simplifies the image recognition model, but also does not require repeated encoding when performing target detection, which can improve the efficiency of target detection, thereby being able to identify cerebral hemorrhage areas more quickly.
[0016] In order to make the above-mentioned objects, features and advantages of the present invention more obvious and easy to understand, preferred embodiments are given below and described in detail with reference to the accompanying drawings. BRIEF DESCRIPTION OF THE DRAWINGS
[0017] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.
[0018] Figure 1 A flow chart of a method for analyzing cerebral hemorrhage images provided by an embodiment of the present invention is shown; Figure 2 A schematic diagram of the structure of an image recognition model provided by an embodiment of the present invention is shown; Figure 3 A graphical schematic diagram of processing a target brain image provided by an embodiment of the present invention is shown; Figure 4 A schematic diagram showing the working principle of the image recognition model provided by an embodiment of the present invention is shown; Figure 5 A schematic diagram of the structure of a convolutional coding layer provided by an embodiment of the present invention is shown; Figure 6 A schematic diagram of the structure of a convolution detection layer provided by an embodiment of the present invention is shown; Figure 7 A schematic structural diagram of a cerebral hemorrhage image analysis device provided by an embodiment of the present invention is shown; Figure 8 A schematic structural diagram of an electronic device for executing a method for analyzing cerebral hemorrhage images provided by an embodiment of the present invention is shown. DETAILED DESCRIPTION
[0019] In the description of the present invention, it should be understood that the terms "center", "longitudinal", "lateral", "length", "width", "thickness", "up", "down", "front", "back", "left", "right", "vertical", "horizontal", "top", "bottom", "inside", "outside", "clockwise", "counterclockwise" and the like indicate orientations or positional relationships based on the orientations or positional relationships shown in the accompanying drawings, and are only for the convenience of describing the present invention and simplifying the description, rather than indicating or implying that the referred device or element must have a specific orientation, be constructed and operated in a specific orientation, and therefore should not be understood as limiting the present invention.
[0020] In addition, the terms "first" and "second" are used for descriptive purposes only and should not be understood as indicating or implying relative importance or implicitly indicating the number of the indicated technical features. Therefore, the features defined as "first" and "second" may explicitly or implicitly include one or more of the features. In the description of the present invention, the meaning of "plurality" is two or more, unless otherwise clearly and specifically defined.
[0021] In the present invention, unless otherwise clearly specified and limited, the terms "installed", "connected", "connected", "fixed" and the like should be understood in a broad sense, for example, it can be a fixed connection, a detachable connection, or an integral connection; it can be a mechanical connection or an electrical connection; it can be a direct connection, or it can be an indirect connection through an intermediate medium, or it can be the internal communication of two components. For ordinary technicians in this field, the specific meanings of the above terms in the present invention can be understood according to specific circumstances.
[0022] Quantitative analysis of patients with suspected cerebral hemorrhage using brain CT images has always been the preferred method for diagnosing cerebral hemorrhage. With the development of computer technology and the improvement of CT imaging level, the resolution of CT images has been continuously improved, which has improved the detection rate and diagnosis rate of cerebral hemorrhage. However, each patient's CT image has dozens or even hundreds of slices, and each slice contains information about different tissues of the brain. Doctors need to analyze each slice to separate the cerebral hemorrhage lesion area from the normal tissue area. This manual segmentation and diagnosis of cerebral hemorrhage is undoubtedly a severe challenge for doctors, especially in emergency situations such as emergency. It is difficult to promptly and accurately determine whether the patient has symptoms of cerebral hemorrhage. Therefore, it is of great significance to use computers to assist in the identification of cerebral hemorrhage areas.
[0023] In the fields of clinical medicine and image detection, a lot of research has been done on automated detection and recognition methods for cerebral hemorrhage. At present, when analyzing cerebral hemorrhage images based on deep learning models, the brain CT images are generally segmented first to extract useful regional images and reduce the impact of useless areas on detection accuracy. Then the cerebral hemorrhage area, namely ROI (Region Of Interest), is found, and the outline of the cerebral hemorrhage area is marked. Although this method of image segmentation first and target detection later improves recognition accuracy, the processing process is complicated and the processing speed needs to be improved.
[0024] The embodiment of the present invention provides a method for analyzing cerebral hemorrhage images, which improves the processing efficiency of brain images by reusing the encoding features of the image during image segmentation and target detection. Figure 1 As shown, the method includes: Step 101: Acquire a target brain image to be detected.
[0025] In this embodiment, a CT image of the patient's brain may be acquired based on a CT device, and the CT image may be directly used as a brain image to be detected, that is, a target brain image.
[0026] Optionally, the above step 101 of “obtaining a target brain image to be detected” may specifically include steps A1 to A2.
[0027] Step A1: Acquire the collected original brain image.
[0028] Step A2: Convert the original brain image into the target brain image.
[0029] and: ;in, Indicates the first x Line y The pixel value of the pixel point in the column, Indicates the first x Line y The pixel value of the pixel point in the column, r is a preset exponential coefficient, and r>1.
[0030] In this embodiment, the CT image acquired based on the CT device can be used as the initial image, that is, the original brain image. Afterwards, the original brain image is processed to obtain a target brain image that is conducive to subsequent analysis.
[0031] Among them, for the pixel point in the xth row and yth column in the original brain image, represents its pixel value (for example, grayscale value), then based on the above formula , calculate the converted pixel value corresponding to each pixel , the pixel value It can be used as the pixel value of the pixel point in the xth row and yth column in the target brain image, thereby generating the target brain image.
[0032] In this embodiment, the preset exponential coefficient r>1 makes the pixel value If it is smaller, the converted pixel value (i.e. ) is not much different; but in pixel values When it is too large, the converted pixel value (i.e. ) has a greater tendency to change with the change of pixel values, thereby highlighting the areas with larger pixel values (i.e., brighter areas) in the original brain image, which is beneficial for the subsequent identification of cerebral hemorrhage areas.
[0033] Step 102: Input the target brain image into a preset image recognition model; the image recognition model includes an encoding structure, a decoding structure and a target detection structure, and the decoding structure and the target detection structure reuse the encoding structure.
[0034] The image recognition model used in this embodiment includes a coding structure, a decoding structure and a target detection structure, and the decoding structure and the target detection structure reuse the coding structure.
[0035] Figure 2 A structural diagram of the image recognition model is shown. Figure 2 As shown, the decoding structure and the target detection structure reuse the encoding structure, that is, they jointly use the hidden layer feature map output by the encoding structure. The working principle of the image recognition model will be explained later.
[0036] Step 103: Encode the target brain image according to the encoding structure to generate a hidden layer feature map.
[0037] In this embodiment, the encoding structure of the image recognition model is a structure for encoding input data (for example, a target brain image) to extract features of the input data. The encoding structure is constructed based on a convolutional layer, and the features generated based on the encoding structure are specifically feature maps. Figure 2 As shown, the encoding structure encodes the target brain image, and the extracted feature map is called the hidden layer feature map.
[0038] Step 104: Decode the hidden layer feature map according to the decoding structure to identify the effective area in the target brain image.
[0039] In this embodiment, the encoding structure and decoding structure of the image recognition model are mainly used to implement image segmentation. Figure 2As shown, for the hidden layer feature map generated by the encoding structure, the decoding structure decodes it and can identify the area in the target brain image for detecting whether there is cerebral hemorrhage, that is, the effective area, which can specifically be the brain parenchyma area.
[0040] Among them, the image recognition model can be implemented based on U-Net (U-type network), and the encoding structure of the image recognition model can be the encoding part of U-Net. Similarly, the decoding structure of the image recognition model can be the decoding part of U-Net.
[0041] Step 105: Generate a mask feature map corresponding to the effective area, and perform a dot multiplication operation on the hidden layer feature map according to the mask feature map to generate an effective feature map.
[0042] In this embodiment, after the valid area in the target brain image is segmented based on the encoding structure and the decoding structure, a mask feature map corresponding to the valid area can be generated; wherein the mask feature map is specifically a binary image, and the pixel points corresponding to the non-valid area in the mask feature map have a pixel value of 0, and the pixel points corresponding to the valid area have a pixel value of 1 (or 255).
[0043] Moreover, by performing a dot multiplication operation on the corresponding hidden layer feature map through the mask feature map, the features in the hidden layer feature map that are irrelevant to the effective area can be removed, and the features in the generated effective feature map can be used for subsequent target detection.
[0044] Figure 3 FIG. 4 shows a graphical schematic diagram of processing a target brain image. Figure 3 As shown in FIG. 1 , after segmenting a target brain image, in the generated mask feature map, the pixel value of the valid area corresponding to the brain substance is 255 (white), while the pixel value of the pixel point in the non-valid area is 0 (black).
[0045] Moreover, the hidden layer feature map is a feature map generated by encoding the target brain image; to facilitate the description of the process of generating a valid feature map, Figure 3 Taking the point multiplication operation of the target brain image according to the mask feature map as an example, the effective feature map is schematically shown. Figure 3 The effective feature map schematically shown in is not a valid feature map generated based on the hidden layer feature map.
[0046] Step 106: Perform target detection processing on the effective feature map according to the target detection structure to identify the cerebral hemorrhage area in the target brain image.
[0047] In this embodiment, the decoding structure and the target detection structure reuse the encoding structure. Figure 2As shown, the effective feature map generated based on the hidden layer feature map and only related to the effective area is input into the target detection structure, and the target detection structure can perform target detection processing based on the effective feature map, thereby identifying the area of concern in the effective area, that is, the cerebral hemorrhage area, and marking the cerebral hemorrhage area.
[0048] like Figure 3 As shown in the figure, after the target detection structure identifies the brain hemorrhage area, it can be based on the square box ( Figure 3 The dotted box of the target detection result in the image is used to identify the cerebral hemorrhage area, so that doctors can perform subsequent treatment on the patient based on the target detection result.
[0049] Optionally, when training the image recognition model, the encoding structure, decoding structure and target detection structure can be trained at the same time, so that the trained encoding structure is not only suitable for image segmentation tasks (that is, it can be applied to the decoding structure), but also for target detection tasks (that is, it can be applied to the target detection structure); and, during the training process, the image segmentation task and the target detection task can influence each other, thereby improving the accuracy of image segmentation and target detection.
[0050] In the training process, a loss function including image segmentation and target detection is constructed. Specifically, the loss function Loss of the image recognition model can be: .
[0051] in, Represents the loss of image segmentation results, Represents the loss of target detection results, , are the weight coefficients for image segmentation and target detection respectively.
[0052] The cerebral hemorrhage image analysis method provided in this embodiment uses an image recognition model to extract the effective area in the target brain area that is most likely to have cerebral hemorrhage, that is, it excludes the area where cerebral hemorrhage will not occur, thereby improving the accuracy of subsequent target detection; and the decoding structure and the target detection structure reuse the encoding structure, that is, only one set of encoding structure needs to be trained and constructed, which not only simplifies the image recognition model, but also does not require repeated encoding when performing target detection, which can improve the efficiency of target detection, thereby being able to quickly identify the cerebral hemorrhage area.
[0053] In some optional embodiments, the coding structure includes: n coding units arranged in sequence; the coding unit includes a convolutional coding layer, and the first n-1 coding units also include a downsampling layer, that is, the nth coding unit may not be provided with a sampling layer.
[0054] Among them, the convolutional coding layer is used to perform convolution processing on the input data to generate convolution processing results corresponding to a larger number of channels; the input data of the convolutional coding layer of the first coding unit is the input data of the coding structure.
[0055] The downsampling layer is used to downsample the convolution processing result generated by the convolution coding layer to generate output data of the coding unit; the output data of the coding unit is the input data of the convolution coding layer of the next coding unit.
[0056] Figure 4 Figure 2 shows a schematic diagram of the working principle of the image recognition model. Figure 4 As shown, the coding structure includes a plurality of convolutional coding layers and downsampling layers arranged in sequence, thereby forming n coding parts. Figure 4 An example is shown in which three encoding units are included, that is, n = 3. Accordingly, the first two encoding units each include a convolutional encoding layer and a downsampling layer, and the third encoding unit only includes a convolutional encoding layer.
[0057] The input data of the coding structure is a brain image. For example, when training an image recognition model, the input data of the coding structure is a training sample image with an cerebral hemorrhage area marked. When the cerebral hemorrhage area needs to be identified, the input data of the coding structure is a target brain image. Furthermore, the input data of the convolutional coding layer of the first coding unit is the input data of the coding structure, that is, the corresponding brain image.
[0058] After the convolutional coding layer of the first encoding unit performs convolution processing on the input data, a corresponding convolution processing result can be generated, and the convolution processing result has more channels than the input data so that more features can be extracted.
[0059] The downsampling layer of the first encoding unit can downsample the convolution processing result generated by the convolution coding layer of the first encoding unit. The downsampling processing can be, for example, a maximum pooling processing, etc., so as to generate the output data of the first encoding unit. The output data of the first encoding unit can be used as the input data of the next encoding unit, that is, the input data of the second encoding unit.
[0060] In the coding structure, the working principle of the middle coding unit is similar to that of the first coding unit, and will not be described here. Figure 4 The third coding unit in the example has only a convolutional coding layer, so the convolution processing result generated by its convolutional coding can be used as the output data of the last coding unit.
[0061] Among them, the convolution processing results generated by each convolutional coding layer are all feature maps, so they can all be used as hidden layer feature maps that need to be processed subsequently.
[0062] Optionally, the decoding structure includes: n-1 decoding units arranged in sequence; the decoding unit includes an upsampling layer and a convolutional decoding layer.
[0063] Among them, the upsampling layer of the i-th decoding unit is used to upsample the input data of the i-th decoding unit to generate an upsampling result; the input data of the first decoding unit is the output data of the n-th encoding unit.
[0064] The convolution decoding layer of the i-th decoding unit is used to add the upsampling result generated by the upsampling layer of the i-th decoding unit and the convolution processing result generated by the convolution coding layer of the ni-th encoding unit, and convolve the addition result to generate a convolution processing result corresponding to a smaller number of channels, and use the convolution processing result of the convolution decoding layer as the output data of the i-th decoding unit; the output data of the i-th decoding unit is used to input into the upsampling layer of the i+1-th decoding unit.
[0065] like Figure 4 As shown, the decoding structure can be divided into two decoding parts arranged in sequence. Among them, the input data of the first decoding part is the output data of the nth encoding part, that is, the convolution processing result generated by the convolutional coding layer of the last encoding part.
[0066] Furthermore, when i=1, the upsampling layer of the first decoding unit is used to perform upsampling processing on the output data of the nth encoding unit, and the upsampling processing may be, for example, a magnification processing, etc. After the upsampling processing, a corresponding upsampling result may be generated.
[0067] The input data of the convolution decoding layer of the first decoding unit includes two parts, namely: the upsampling result generated by the upsampling layer of the first decoding unit, and the convolution processing result generated by the convolution coding layer of the second (where n=3, i=1) encoding unit; the convolution decoding layer performs addition processing to generate a corresponding addition processing result, and then performs convolution processing on the addition processing result to generate a corresponding convolution processing result, and the convolution processing result has fewer channels than the input data, so that the convolution processing result can be correctly processed by the next decoding layer.
[0068] The convolution processing result of the convolution decoding layer can be used as the output data of the corresponding decoding unit. In addition, the convolution processing result generated by the convolution decoding layer of the i-th decoding unit has the same number of channels as the convolution processing result generated by the convolution encoding layer of the ni-th encoding unit.
[0069] The working principle of the subsequent decoding units is similar to that of the first decoding unit, and will not be described in detail here. In addition, the output data of the last decoding unit can be used as the output data of the decoding structure, based on which the effective area in the brain image can be identified.
[0070] In this embodiment, the encoding structure and the decoding structure as a whole adopt the U-Net model structure, which is convenient for image segmentation, so that the effective area can be identified quickly and accurately.
[0071] Optionally, since the encoding structure is reused by the decoding structure and the target detection structure, in order to ensure the effect of subsequent target detection, it is necessary to use a deeper structure to extract image features. However, as the depth of the network structure increases, problems such as gradient explosion are prone to occur, and the residual structure can better solve this problem. In this embodiment, multiple layers of convolution based on residual implementation are set for the convolutional coding layer of the encoding unit; Figure 5 As shown, the convolutional coding layer includes: a first convolutional sublayer, a second convolutional sublayer and a first fusion layer arranged in sequence; the number of the second convolutional sublayer is multiple, Figure 5 An example in which three second convolutional sub-layers are provided is shown.
[0072] The first convolution sublayer is used to perform convolution processing on the input data of the convolution coding layer according to a 1×1 convolution kernel to generate a first convolution processing result with a channel number of c1; c1>c0, c0 is the number of channels of the input data of the convolution coding layer; the first convolution processing result is the input data of the first second convolution sublayer.
[0073] The second convolution sublayer is used to perform convolution processing on the input data of the second convolution sublayer according to the convolution kernel of a×a, and generate a second convolution processing result with the number of channels also being c1; a>1; the second convolution processing result generated by the second convolution sublayer is the input data of the next second convolution sublayer.
[0074] The first fusion layer is used to fuse the first convolution processing result and the multiple second convolution processing results to generate the convolution processing result of the convolution coding layer.
[0075] In this embodiment, the convolutional coding layer can output a feature map with a greater number of channels. Assuming that the number of channels of the input data of the convolutional coding layer is c0, after being processed by the convolutional coding layer, it can output a convolution processing result with a number of channels of c1, where c1>c0.
[0076] Specifically, the first convolution sublayer is essentially a convolution layer, which can perform convolution processing on the input data, thereby converting the input data with the number of channels c0 into the data with the number of channels c1, that is, the first convolution processing result. And, Figure 5 As shown, the first convolution processing result generated by the first convolution sublayer will be input to the first second convolution sublayer for further processing.
[0077] For each second convolution sublayer, it also performs convolution processing on the input data, but it does not change the number of channels of the data, that is, the number of channels of the input data and output data of the second convolution sublayer is c1.
[0078] The first convolution sublayer uses a 1×1 convolution kernel, which is mainly used to make the number of channels of the output data meet the requirements of the convolution coding layer, that is, to be able to output the convolution processing result with a channel number of c1. The main function of each second convolution sublayer is to extract the features of the input data, and it uses an a×a convolution kernel, where a>1, for example, a=3.
[0079] In this embodiment, the first convolution sublayer can output the first convolution processing result with the number of channels c1, and each second convolution sublayer can output the second convolution processing result with the number of channels c1, that is, the first convolution processing result has the same number of channels as each second convolution processing result, so the first fusion layer can be used to fuse these convolution processing results (one first convolution processing result and multiple second convolution processing results). For details, see Figure 5 As shown. The first fusion layer can specifically add multiple convolution processing results to finally generate the convolution processing result output by the convolution coding layer.
[0080] In this embodiment, each convolutional coding layer in the coding structure can adopt Figure 5 The similar structure shown makes the entire encoding structure have a large depth, which is conducive to extracting deep information in brain images. In addition, the first fusion layer fuses the results of each convolution processing in the form of residual mapping, which can effectively avoid problems such as gradient explosion and ensure the accuracy and reliability of the model.
[0081] In some optional embodiments, The above step 105 "performing a dot multiplication operation on the hidden layer feature map according to the mask feature map to generate a valid feature map" includes step B1.
[0082] Step B1, performing a point multiplication operation on the convolution processing results of each convolution coding layer according to the mask feature map to generate a corresponding effective feature sub-map.
[0083] As described above, the convolution processing results generated by each convolution coding layer in the coding structure can be used as hidden layer feature maps, and the convolution processing results generated by each convolution coding layer can be processed separately using the binary mask feature map to generate feature maps that can be used by the target detection structure, which are referred to here as effective feature sub-maps; it can be understood that the effective feature maps include these effective feature sub-maps.
[0084] Optionally, the above step B1 "performing a point multiplication operation on the convolution processing results of each convolution coding layer according to the mask feature map to generate a corresponding valid feature sub-map" includes steps B11 to B13.
[0085] Step B11, performing a dot multiplication operation on the convolution processing result of the convolutional coding layer of the first coding unit and the mask feature map to generate the first effective feature sub-map.
[0086] Step B12, downsampling the mask feature map j-1 times in sequence; j≥2.
[0087] Step B13, performing a dot multiplication operation on the convolution processing result of the convolution coding layer of the j-th coding unit and the mask feature map after j-1 times of downsampling processing to generate the j-th effective feature sub-map.
[0088] In this embodiment, for the convolution coding layer of the first encoding unit, since the convolution processing process will not change the data size specifications (data width and height), that is, the convolution processing result has the same data specification as the mask feature map (or the target brain image), the mask feature map can be directly used to perform a dot multiplication operation on the convolution processing result of the convolution coding layer of the first encoding unit, thereby generating the first effective feature sub-map.
[0089] For the convolutional coding layers of the remaining coding parts, in order to ensure the consistency of size specifications, the mask feature map is downsampled once or multiple times. Specifically, the mask feature map can be downsampled once or multiple times in sequence using the downsampling layer in the coding structure. It can be understood that the mask feature map that has been downsampled once is downsampled again to obtain the mask feature map that has been downsampled twice, and so on.
[0090] Specifically, for the convolutional coding layer of the j-th coding unit, the mask feature map that has undergone j-1 downsampling processes can be used. That is, the convolution processing result of the convolutional coding layer of the j-th coding unit is point multiplied with the mask feature map after j-1 downsampling processes to generate a valid feature sub-map corresponding to the j-th coding unit, that is, the j-th valid feature sub-map.
[0091] For each valid feature sub-graph, the target detection structure can be processed separately. Figure 4 As shown, the target detection structure includes: n target detection units arranged in sequence; the target detection unit includes a convolution detection layer, and the first n-1 target detection units also include an amplification layer, that is, the last target detection unit may not include an amplification layer.
[0092] The convolution detection layer of the i-th target detection unit is used to perform addition processing on the output data of the i-1-th target detection unit and the effective feature subgraph generated based on the convolution processing result of the convolution coding layer of the n-i+1-th coding unit, and perform convolution processing on the addition processing result to generate a convolution processing result corresponding to a smaller number of channels; the input data of the convolution coding layer of the first coding unit is the input data of the coding structure; The amplification layer of the i-th target detection unit is used to upsample the convolution processing result generated by the convolution detection layer of the i-th target detection unit to generate the output data of the i-th target detection unit; the output data of the i-th target detection unit is used to input into the convolution detection layer of the i+1-th target detection unit.
[0093] In this embodiment, for the convolution detection layer of the i-th target detection unit, its input data includes two parts: the output data of the previous target detection unit (i.e., the i-1-th target detection unit), and the effective feature subgraph corresponding to the corresponding encoding unit, that is, the effective feature subgraph generated by the convolution processing result of the convolution coding layer of the n-i+1-th encoding unit, that is, the n-i+1-th effective feature subgraph.
[0094] Furthermore, the convolution detection layer of the first target detection unit has only one input data, or in other words, the output data of the previous target detection unit is empty.
[0095] like Figure 4 As shown in the figure, in order from top to bottom, for the convolution detection layer (i=1) of the first target detection unit, its input data is the third (n=3) valid feature subgraph; since the output data of the previous target detection unit is empty, the result of the addition processing is also the third valid feature subgraph. The convolution detection layer of the first target detection unit performs convolution processing on the third valid feature subgraph to generate a convolution processing result with a smaller number of channels, so as to ensure that the output data of the target detection unit has the same number of channels as the input data of the next target detection unit, that is, the convolution processing result output by the convolution detection layer of the i-th target detection unit has the same number of channels as the convolution processing result of the convolution coding layer of the ni-th coding unit, and also has the same number of channels as the ni-th valid feature graph.
[0096] The amplification layer of the first target detection unit can also be an upsampling layer in essence, which performs upsampling processing on the convolution processing result generated by the convolution detection layer of the first target detection unit, thereby generating corresponding output data, i.e., the output data of the first target detection unit. It can be understood that the output data of the first target detection unit is also part of the input data of the next target detection unit (i.e., the second target detection unit).
[0097] For the subsequent target detection unit, its input data includes two parts. By adding these two parts of data, the addition result can be convolved to generate the corresponding convolution result. The working principles of its convolution detection layer and amplification layer are not elaborated here.
[0098] For the last target detection unit, it does not include an amplification layer, that is, only convolution processing is required, and its convolution detection layer can output the corresponding convolution processing result.
[0099] In this embodiment, the convolution processing result output by the convolution detection layer can be used for object detection to identify the intracerebral hemorrhage region therein. For example, object detection processing can be performed only based on the convolution processing result output by the last convolution detection layer to identify the intracerebral hemorrhage region.
[0100] Alternatively, for example, based on the principle of object detection implemented by the Feature Pyramid Network (FPN), the convolution processing results output by each convolution detection layer can be used to comprehensively determine the intracerebral hemorrhage region. This embodiment does not make any limitation thereto.
[0101] In this embodiment, the convolution processing results of each convolution encoding layer can be processed by using the mask feature map, so as to form multiple effective feature submaps; the object detection structure uses multiple sequentially arranged convolution detection layers to perform processing on the basis of the corresponding effective feature submaps, realizing the reuse of the encoding structure, and can effectively utilize features at different levels to ensure the accuracy of subsequent object detection. In addition, by using the mask feature map that has undergone one or more downsampling processes, each effective feature submap can be simply and conveniently determined, and the implementation method is simple.
[0102] Optionally, as Figure 6 shown, the convolution detection layer may specifically include: an addition layer, a third convolution sublayer, a fourth convolution sublayer, a fifth convolution sublayer, and a second fusion layer.
[0103] Among them, the addition layer is used to add the output data of the previous object detection part and the corresponding effective feature submap to generate an addition processing result. It can be understood that for the first convolution detection layer, since it has only one input data, the addition processing may not be performed, or rather, the addition layer adds 0 to the corresponding effective feature submap, and the obtained addition processing result is still the effective feature submap itself.
[0104] The third convolution sublayer is used to perform convolution processing on the addition processing result of the addition layer according to a b×b convolution kernel to generate a third convolution processing result; b>1.
[0105] The fourth convolution sublayer is used to perform convolution processing on the third convolution processing result according to a 1×b convolution kernel to generate a fourth convolution processing result with the number of channels being c2; c2<c3, and c3 is the number of channels of the input data of the convolution detection layer.
[0106] The fifth convolution sublayer is used to perform convolution processing on the third convolution processing result according to a b×1 convolution kernel to generate a fifth convolution processing result with the number of channels being c2.
[0107] The second fusion layer is used to fuse the fourth convolution processing result and the fifth convolution processing result to generate the convolution processing result of the convolution detection layer.
[0108] In this embodiment, as described above, for the convolutional detection layer of the i-th target detection unit, its input data includes the output data of the previous target detection unit (i.e., the (i - 1)-th target detection unit) and the (n - i + 1)-th effective feature subgraph. After the addition layer adds the output data of the previous target detection unit and the (n - i + 1)-th effective feature subgraph, the corresponding addition processing result can be obtained. Then, the third convolutional sub-layer performs convolutional processing on this addition processing result to generate a third convolutional processing result; then, the fourth convolutional sub-layer and the fifth convolutional sub-layer respectively perform convolutional processing on this third convolutional processing result to generate corresponding fourth and fifth convolutional processing results.
[0109] Among them, the third convolutional sub-layer uses a convolutional kernel of b×b, and b>1; for example, b = 3. For the fourth convolutional sub-layer and the fifth convolutional sub-layer, they respectively perform convolutional processing using convolutional kernels of 1×b and b×1; finally, the second fusion layer performs fusion processing on the fourth and fifth convolutional processing results to finally achieve feature extraction based on convolutional processing.
[0110] Among them, the fourth convolutional sub-layer and the fifth convolutional sub-layer are also both used to reduce the number of data channels. Wherein, if the number of channels of the input data of the convolutional detection layer is c3, and the number of channels of the fourth and fifth convolutional processing results generated by the fourth convolutional sub-layer and the fifth convolutional sub-layer is c2, and c2 < c3. This number of channels c2 is the number of channels of the output data of the convolutional detection layer.
[0111] In this embodiment, the fourth convolutional sub-layer and the fifth convolutional sub-layer adopt simple convolutional kernels, which can reduce parameters and the amount of data processing; moreover, the fourth convolutional sub-layer and the fifth convolutional sub-layer can be processed in parallel, thereby improving the processing efficiency.
[0112] The above has introduced in detail the process of the cerebral hemorrhage image analysis method. This method can also be implemented by a corresponding device. The following details the structure and functions of the device.
[0113] Based on the same inventive concept, an embodiment of the present invention also provides a cerebral hemorrhage image analysis device. As shown in Figure 7 shown, the device includes: An image acquisition module 701, configured to acquire a target brain image to be detected; An input module 702, configured to input the target brain image into a preset image recognition model; the image recognition model includes an encoding structure, a decoding structure, and a target detection structure, and the decoding structure and the target detection structure reuse the encoding structure; The image segmentation module 703 is used to encode the target brain image according to the encoding structure to generate a hidden layer feature map; decode the hidden layer feature map according to the decoding structure to identify the effective area in the target brain image; The target detection module 704 is used to generate a mask feature map corresponding to the effective area, and perform a dot multiplication operation on the hidden layer feature map according to the mask feature map to generate an effective feature map; perform target detection processing on the effective feature map according to the target detection structure to identify the cerebral hemorrhage area in the target brain image.
[0114] In some optional implementations, the coding structure includes: n coding units arranged in sequence; the coding units include convolutional coding layers, and the first n-1 coding units also include downsampling layers; The convolutional coding layer is used to perform convolution processing on the input data to generate convolution processing results corresponding to a greater number of channels; the input data of the convolutional coding layer of the first coding unit is the input data of the coding structure; The downsampling layer is used to perform downsampling processing on the convolution processing result generated by the convolution coding layer to generate output data of the encoding unit; the output data of the encoding unit is the input data of the convolution coding layer of the next encoding unit.
[0115] In some optional implementations, the convolutional coding layer includes: a first convolutional sublayer, a second convolutional sublayer, and a first fusion layer arranged in sequence; the number of the second convolutional sublayer is multiple; The first convolution sublayer is used to perform convolution processing on the input data of the convolution coding layer according to a 1×1 convolution kernel to generate a first convolution processing result with a channel number of c1; c1>c0, c0 is the channel number of the input data of the convolution coding layer; the first convolution processing result is the input data of the first second convolution sublayer; The second convolution sublayer is used to perform convolution processing on the input data of the second convolution sublayer according to the convolution kernel of a×a, and generate a second convolution processing result whose number of channels is also c1; a>1; the second convolution processing result generated by the second convolution sublayer is the input data of the next second convolution sublayer; The first fusion layer is used to fuse the first convolution processing result and multiple second convolution processing results to generate the convolution processing result of the convolution coding layer.
[0116] In some optional implementations, the target detection module 704 performs a dot multiplication operation on the hidden layer feature map according to the mask feature map to generate a valid feature map, including: Performing a point multiplication operation on the convolution processing results of each of the convolution coding layers according to the mask feature graph to generate a corresponding valid feature subgraph; The target detection structure includes: n target detection parts arranged in sequence; each target detection part includes a convolutional detection layer, and the first n-1 target detection parts further include an amplification layer; The convolutional detection layer of the i-th target detection part is used to add the output data of the (i-1)-th target detection part and the effective feature sub-map generated based on the convolutional processing result of the convolutional coding layer of the (n-i+1)-th coding part, and perform convolutional processing on the added result to generate a convolutional processing result corresponding to fewer channels; the input data of the convolutional coding layer of the first coding part is the input data of the coding structure; The amplification layer of the i-th target detection part is used to perform upsampling on the convolutional processing result generated by the convolutional detection layer of the i-th target detection part to generate the output data of the i-th target detection part; the output data of the i-th target detection part is used to be input into the convolutional detection layer of the (i+1)-th target detection part.
[0117] In some optional embodiments, the convolutional detection layer includes: an addition layer, a third convolutional sub-layer, a fourth convolutional sub-layer, a fifth convolutional sub-layer, and a second fusion layer; The addition layer is used to add the output data of the previous target detection part and the corresponding effective feature sub-map to generate an added result; The third convolutional sub-layer is used to perform convolutional processing on the added result of the addition layer according to a b×b convolutional kernel to generate a third convolutional processing result; b>1; The fourth convolutional sub-layer is used to perform convolutional processing on the third convolutional processing result according to a 1×b convolutional kernel to generate a fourth convolutional processing result with the number of channels c2; c2<c3, where c3 is the number of channels of the input data of the convolutional detection layer; The fifth convolutional sub-layer is used to perform convolutional processing on the third convolutional processing result according to a b×1 convolutional kernel to generate a fifth convolutional processing result with the number of channels c2; The second fusion layer is used to fuse the fourth convolutional processing result and the fifth convolutional processing result to generate the convolutional processing result of the convolutional detection layer.
[0118] In some optional embodiments, the target detection module 704 performs a dot product operation on the convolutional processing results of each convolutional coding layer according to the mask feature map to generate corresponding effective feature sub-maps, including: Performing a dot product operation on the convolutional processing result of the convolutional coding layer of the first coding part and the mask feature map to generate a first effective feature sub-map; Performing j-1 downsampling operations on the mask feature map in sequence; j≥2; The convolution processing result of the convolutional coding layer of the j-th coding unit is multiplied by the mask feature map after j-1 times of downsampling to generate the j-th effective feature sub-map.
[0119] In some optional implementations, the decoding structure includes: n-1 decoding units arranged in sequence; the decoding unit includes an upsampling layer and a convolutional decoding layer; The upsampling layer of the i-th decoding unit is used to perform upsampling processing on the input data of the i-th decoding unit to generate an upsampling result; the input data of the first decoding unit is the output data of the n-th encoding unit; The convolution decoding layer of the i-th decoding unit is used to add the upsampling result generated by the upsampling layer of the i-th decoding unit and the convolution processing result generated by the convolution coding layer of the ni-th encoding unit, and convolve the addition result to generate a convolution processing result corresponding to a smaller number of channels, and use the convolution processing result of the convolution decoding layer as the output data of the i-th decoding unit; the output data of the i-th decoding unit is used to input into the upsampling layer of the i+1-th decoding unit.
[0120] In some optional implementations, the image acquisition module 701 acquires the target brain image to be detected, including: Acquire the collected original brain images; converting the original brain image into a target brain image; and: ;in, Indicates the first x Line y The pixel value of the pixel point in the column, Indicates the first x Line y The pixel value of the pixel point in the column, r is a preset exponential coefficient, and r>1.
[0121] An embodiment of the present invention further provides a computer storage medium storing computer executable instructions, which includes a program for executing the above-mentioned cerebral hemorrhage image analysis method. The computer executable instructions can execute the method in any of the above-mentioned method embodiments.
[0122] Among them, the computer storage medium can be any available medium or data storage device that can be accessed by the computer, including but not limited to magnetic storage (such as floppy disks, hard disks, magnetic tapes, magneto-optical disks (MO), etc.), optical storage (such as CD, DVD, BD, HVD, etc.), and semiconductor storage (such as ROM, EPROM, EEPROM, non-volatile memory (NANDFLASH), solid-state drive (SSD)), etc.
[0123] Figure 8 The block diagram of the structure of an electronic device of another embodiment of the present invention is shown. The electronic device 1100 may be a host server with computing capability, a personal computer PC, or a portable computer or terminal, etc. The specific embodiment of the present invention does not limit the specific implementation of the electronic device.
[0124] The electronic device 1100 includes at least one processor 1110, a communications interface 1120, a memory array 1130, and a bus 1140. The processor 1110, the communications interface 1120, and the memory array 1130 communicate with each other via the bus 1140.
[0125] The communication interface 1120 is used to communicate with network elements, where the network elements include, for example, a virtual machine management center, shared storage, etc.
[0126] The processor 1110 is used to execute programs. The processor 1110 may be a central processing unit (CPU), or an application specific integrated circuit (ASIC), or one or more integrated circuits configured to implement the embodiments of the present invention.
[0127] The memory 1130 is used for executable instructions. The memory 1130 may include a high-speed RAM memory, and may also include a non-volatile memory, such as at least one disk memory. The memory 1130 may also be a memory array. The memory 1130 may also be divided into blocks, and the blocks may be combined into virtual volumes according to certain rules. The instructions stored in the memory 1130 can be executed by the processor 1110, so that the processor 1110 can execute the cerebral hemorrhage image analysis method in any of the above method embodiments.
[0128] The above is only a specific embodiment of the present invention, but the protection scope of the present invention is not limited thereto. Any person skilled in the art can easily think of changes or substitutions within the technical scope disclosed by the present invention, which should be included in the protection scope of the present invention. Therefore, the protection scope of the present invention should be based on the protection scope of the claims.
Claims
1. A method for analyzing cerebral hemorrhage images, characterized in that: include: Acquire a target brain image to be detected; Inputting the target brain image into a preset image recognition model; The image recognition model includes a coding structure, a decoding structure and a target detection structure, and the decoding structure and the target detection structure reuse the coding structure; Performing encoding processing on the target brain image according to the encoding structure to generate a hidden layer feature map; Decoding the hidden layer feature map according to the decoding structure to identify a valid area in the target brain image; Generate a mask feature map corresponding to the effective area, and perform a dot multiplication operation on the hidden layer feature map according to the mask feature map to generate an effective feature map; The effective feature map is subjected to target detection processing according to the target detection structure to identify the cerebral hemorrhage area in the target brain image.
2. The method according to claim 1, characterized in that The coding structure comprises: n coding units arranged in sequence; the coding units comprise convolutional coding layers, and the first n-1 coding units further comprise downsampling layers; The convolutional coding layer is used to perform convolution processing on the input data to generate convolution processing results corresponding to a greater number of channels; the input data of the convolutional coding layer of the first coding unit is the input data of the coding structure; The downsampling layer is used to perform downsampling processing on the convolution processing result generated by the convolution coding layer to generate output data of the encoding unit; the output data of the encoding unit is the input data of the convolution coding layer of the next encoding unit.
3. The method according to claim 2, characterized in that The convolutional coding layer includes: a first convolutional sublayer, a second convolutional sublayer and a first fusion layer arranged in sequence; the number of the second convolutional sublayer is multiple; The first convolution sublayer is used to perform convolution processing on the input data of the convolution coding layer according to a 1×1 convolution kernel to generate a first convolution processing result with a channel number of c1; c1>c0, c0 is the channel number of the input data of the convolution coding layer; the first convolution processing result is the input data of the first second convolution sublayer; The second convolution sublayer is used to perform convolution processing on the input data of the second convolution sublayer according to the convolution kernel of a×a, and generate a second convolution processing result whose number of channels is also c1; a>1; the second convolution processing result generated by the second convolution sublayer is the input data of the next second convolution sublayer; The first fusion layer is used to fuse the first convolution processing result and multiple second convolution processing results to generate the convolution processing result of the convolution coding layer.
4. The method according to claim 2 or 3, characterized in that: The step of performing a dot multiplication operation on the hidden layer feature map according to the mask feature map to generate a valid feature map comprises: Performing a point multiplication operation on the convolution processing results of each of the convolution coding layers according to the mask feature graph to generate a corresponding valid feature subgraph; The target detection structure comprises: n target detection units arranged in sequence; the target detection units comprise convolution detection layers, and the first n-1 target detection units further comprise amplification layers; The convolutional detection layer of the i-th object detection unit is used to add the output data of the (i - 1)-th object detection unit and the effective feature sub-map generated based on the convolutional processing result of the convolutional encoding layer of the (n - i + 1)-th encoding unit, and perform convolutional processing on the addition result to generate a convolutional processing result corresponding to fewer channels; the input data of the convolutional encoding layer of the first encoding unit is the input data of the encoding structure; The upsampling layer of the i-th object detection unit is used to perform upsampling processing on the convolutional processing result generated by the convolutional detection layer of the i-th object detection unit to generate the output data of the i-th object detection unit; the output data of the i-th object detection unit is used to be input into the convolutional detection layer of the (i + 1)-th object detection unit.
5. The method according to claim 4, characterized in that The convolutional detection layer includes: an addition layer, a third convolutional sub-layer, a fourth convolutional sub-layer, a fifth convolutional sub-layer, and a second fusion layer; The addition layer is used to add the output data of the previous object detection unit and the corresponding effective feature sub-map to generate an addition result; The third convolutional sub-layer is used to perform convolutional processing on the addition result of the addition layer according to a b×b convolutional kernel to generate a third convolutional processing result; b > 1; The fourth convolutional sub-layer is used to perform convolutional processing on the third convolutional processing result according to a 1×b convolutional kernel to generate a fourth convolutional processing result with the number of channels being c2; c2 < c3, where c3 is the number of channels of the input data of the convolutional detection layer; The fifth convolutional sub-layer is used to perform convolutional processing on the third convolutional processing result according to a b×1 convolutional kernel to generate a fifth convolutional processing result with the number of channels being c2; The second fusion layer is used to fuse the fourth convolutional processing result and the fifth convolutional processing result to generate the convolutional processing result of the convolutional detection layer.
6. The method according to claim 4, characterized in that The dot product operation on the convolutional processing results of each convolutional encoding layer according to the mask feature map to generate corresponding effective feature sub-maps includes: Performing a dot product operation on the convolutional processing result of the convolutional encoding layer of the first encoding unit and the mask feature map to generate the first effective feature sub-map; Performing j - 1 times of downsampling processing on the mask feature map in sequence; j ≥ 2; Performing a dot product operation on the convolutional processing result of the convolutional encoding layer of the j-th encoding unit and the mask feature map after j - 1 times of downsampling processing to generate the j-th effective feature sub-map.
7. The method according to claim 2, characterized in that The decoding structure includes: n - 1 decoding units arranged in sequence; the decoding unit includes an upsampling layer and a convolutional decoding layer; The upsampling layer of the i-th decoding unit is used to perform upsampling processing on the input data of the i-th decoding unit to generate an upsampling result; the input data of the first decoding unit is the output data of the n-th encoding unit; The convolution decoding layer of the i-th decoding unit is used to add the upsampling result generated by the upsampling layer of the i-th decoding unit and the convolution processing result generated by the convolution coding layer of the ni-th encoding unit, and convolve the addition result to generate a convolution processing result corresponding to a smaller number of channels, and use the convolution processing result of the convolution decoding layer as the output data of the i-th decoding unit; the output data of the i-th decoding unit is used to input into the upsampling layer of the i+1-th decoding unit.
8. The method according to claim 1, characterized in that The step of acquiring the target brain image to be detected comprises: Acquire the collected original brain images; converting the original brain image into a target brain image; and: ;in, Indicates the first x Line y The pixel value of the pixel point in the column, Indicates the first x Line y The pixel value of the pixel point in the column, r is a preset exponential coefficient, and r>1.
9. A device for analyzing cerebral hemorrhage images, characterized in that: include: An image acquisition module, used for acquiring a target brain image to be detected; An input module, used to input the target brain image into a preset image recognition model; the image recognition model includes a coding structure, a decoding structure and a target detection structure, and the decoding structure and the target detection structure reuse the coding structure; An image segmentation module, used for encoding the target brain image according to the encoding structure to generate a hidden layer feature map; Decoding the hidden layer feature map according to the decoding structure to identify a valid area in the target brain image; The target detection module is used to generate a mask feature map corresponding to the effective area, and perform a dot multiplication operation on the hidden layer feature map according to the mask feature map to generate an effective feature map; perform target detection processing on the effective feature map according to the target detection structure to identify the cerebral hemorrhage area in the target brain image.
10. An electronic device, characterized in that: include: at least one processor; as well as, a memory communicatively connected to the at least one processor; wherein, The memory stores instructions that can be executed by the at least one processor, and the instructions are executed by the at least one processor so that the at least one processor can execute the cerebral hemorrhage image analysis method described in any one of claims 1 to 8.