Fourier transform-based medical image segmentation method and related apparatus
By employing a Fourier transform-based medical image segmentation method, which utilizes encoding/decoding and frequency domain processing to extract semantic information of organs and generate a dynamic segmentation head, the problem of unutilized semantic relationships between different organs is solved, thus improving the accuracy of medical image segmentation.
Patent Information
- Application Number
- CN202411449308.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-10-17
- Publication Date
- 2025-11-11
- Estimated Expiration
- 2044-10-17
AI Technical Summary
Existing medical image segmentation methods fail to fully utilize the semantic relationships between different organs, resulting in low segmentation accuracy.
A medical image segmentation method based on Fourier transform is adopted. By encoding and decoding the medical image to be segmented, semantic information of organs is extracted. Fourier transform and inverse transform are used to capture edge details and semantic relationships between organs, and a dynamic segmentation head is generated to improve segmentation accuracy.
It improves the accuracy of medical image segmentation, especially in capturing organ edges and texture features, and enhances the model's ability to understand complex scenes.
Smart Images

Figure CN119559193B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of image processing, and more particularly to a medical image segmentation method and related apparatus based on Fourier transform. Background Technology
[0002] Current medical image segmentation methods only include prior information about a single organ to be segmented, and the positional and semantic relationships between different organs are not fully utilized, resulting in low model segmentation accuracy.
[0003] For example, using one-hot labels as task encoding provides prior information, thereby guiding the model to handle specific tasks and focus on specific regions, but ignores the semantic relationships between different organs. Given one-hot labels for the liver [1,0,0], pancreas [0,1,0], and spleen [0,0,1], this would result in no semantic differences between the liver, pancreas, and spleen.
[0004] For example, using text embeddings learned in contrastive language-image pre-training provides anatomical prior information, enabling the model to learn structured feature embeddings, but it is difficult to provide detailed guidance on edges, textures, and shapes. Summary of the Invention
[0005] The following is an overview of the subject matter described in detail herein. This overview is not intended to limit the scope of the claims.
[0006] The purpose of this application is to at least partially solve one of the technical problems existing in the related technologies. The embodiments of this application provide a medical image segmentation method and related apparatus based on Fourier transform, which can accurately segment medical images according to the tissue structure between different organs.
[0007] An embodiment of the first aspect of this application, a medical image segmentation method based on Fourier transform, includes:
[0008] Acquire the medical image to be segmented;
[0009] The medical image to be segmented is encoded and decoded to obtain a pre-segmentation feature map;
[0010] The medical image to be segmented is subjected to Fourier transform to obtain frequency domain features, and the frequency domain features are subjected to inverse Fourier transform to obtain inverse transform image. The features obtained by convolution of the inverse transform image and the features obtained by encoding the features of the first image are concatenated to obtain concatenated features. The concatenated features are subjected to convolution downsampling and pooling to obtain transform features.
[0011] The transformation features are downsampled at different resolutions to obtain multiple downsampled features, and the multiple downsampled features are fused to obtain fused image features;
[0012] Based on the organ semantic features of the fused image features, segmentation head parameters corresponding to various organs are generated, and segmentation heads corresponding to various organs are configured according to the segmentation head parameters.
[0013] The segmentation head is used to segment the pre-segmented feature map to obtain a segmented image.
[0014] According to certain embodiments of the first aspect of this application, the step of encoding and decoding the medical image to be segmented to obtain a pre-segmentation feature map includes:
[0015] The medical image to be segmented is downsampled multiple times to achieve encoding, resulting in an encoded image;
[0016] The encoded image is upsampled multiple times to achieve decoding, resulting in a pre-segmented feature map.
[0017] According to certain embodiments of the first aspect of this application, the step of performing an inverse Fourier transform on the frequency domain features to obtain an inverse transform image includes:
[0018] The inverse Fourier transform is obtained by multiplying the absolute value of the frequency domain feature with the transformation matrix.
[0019] According to certain embodiments of the first aspect of this application, the transformation matrix is obtained based on the distance from each pixel of the medical image to be segmented to the center pixel.
[0020] According to certain embodiments of the first aspect of this application, downsampling the transformed features to obtain downsampled features includes:
[0021] Flattening the transformation features yields the flattened features;
[0022] The flattened feature is subjected to convolution, reshaping, and layer normalization to obtain the first sub-feature.
[0023] The first sub-feature is processed by linear transformation, convolution, activation function, and feature extraction to obtain the second sub-feature;
[0024] The first sub-feature is processed by linear transformation and activation function to obtain the third sub-feature;
[0025] The fusion result of the second sub-feature and the third sub-feature is subjected to linear transformation to obtain the downsampled feature.
[0026] According to certain embodiments of the first aspect of this application, the medical image segmentation method based on Fourier transform further includes: adjusting the parameters of the model corresponding to the medical image segmentation method according to a first loss function;
[0027] The first loss function is: L = l dice +l CE , In the formula, n v p is the number of voxels in the dataset of the nth medical image to be segmented. iL Let y be the probability vector of the i-th voxel with label L. iL Let TP be the one-hot encoded vector of the i-th voxel with label L. L The label of the medical image to be segmented is a true positive, FP L The label indicating a false positive for the medical image to be segmented is FN. L The label of the medical image to be segmented is a false negative, ε is a preset parameter, L is the first loss function, and l dice Let l be the Dice loss function. CE This is the crossover loss function.
[0028] According to certain embodiments of the first aspect of this application, the medical image segmentation method based on Fourier transform further includes: adjusting the parameters of the model corresponding to the medical image segmentation method according to a second loss function;
[0029] The second loss function is: target=label☉softmax(mask), In the formula, Loss is the second loss function. Let D be the number of categories in the dataset of medical images to be segmented, τ be the number of categories in the expert annotations of the dataset of medical images to be segmented, and D be the number of categories. n Let m be the total number of organ categories in the nth medical image to be segmented, and λ be the total number of organ categories in the medical image to be segmented. n To adjust the parameters, `label` is the ground truth label, `target` is the pseudo-label of the unannotated voxels in the medical image to be segmented after removing the background, `mask` is the unannotated organ segmentation result from the dataset of the medical image to be segmented, and `output` is... L The result represents the segmentation of organ type L, where Φm represents the category annotated in the background.
[0030] A second aspect of this application provides a medical image segmentation apparatus based on Fourier transform, comprising:
[0031] Input unit, used to acquire the medical image to be segmented;
[0032] The encoding and decoding unit is used to encode and decode the medical image to be segmented to obtain a pre-segmentation feature map.
[0033] The Fourier transform unit is used to perform Fourier transform on the medical image to be segmented to obtain frequency domain features, perform inverse Fourier transform on the frequency domain features to obtain an inverse transform image, concatenate the features obtained by convolution of the inverse transform image and the features obtained by encoding the features of the first image to obtain concatenated features, and perform convolution downsampling and pooling processing on the concatenated features to obtain transform features.
[0034] The feature fusion unit is used to downsample the transformed features according to different resolutions to obtain multiple downsampled features, and to fuse the multiple downsampled features to obtain fused image features;
[0035] The segmentation head parameter generation unit is used to generate segmentation head parameters corresponding to various organs based on the organ semantic features of the fused image features, and to configure the segmentation head corresponding to various organs based on the segmentation head parameters.
[0036] A segmentation head unit is used to segment the pre-segmented feature map using the segmentation head to obtain a segmented image.
[0037] According to a third aspect of this application, an electronic device includes a memory and a processor, the memory storing a computer program, and the processor executing the computer program to implement the Fourier transform-based medical image segmentation method described in the first aspect of this application.
[0038] According to a fourth aspect of this application, a computer-readable storage medium stores a computer program that, when executed by a processor, implements the Fourier transform-based medical image segmentation method described in the first aspect of this application.
[0039] This application has the following beneficial effects: by encoding and decoding the medical image to be segmented, key image features representing the semantic information of organs are extracted; by performing Fourier transform, inverse Fourier transform, and feature stitching on the medical image to be segmented, edge details and semantic relationships between organs are captured and enhanced as prior knowledge to guide the subsequent segmentation process; and by fusing prior knowledge with deep features extracted by the encoder to generate a dynamic segmentation head, the accuracy of medical image segmentation is improved. Attached Figure Description
[0040] The accompanying drawings are used to provide a further understanding of the technical solutions of this application and constitute a part of the specification. They are used together with the embodiments of this application to explain the technical solutions of this application and do not constitute a limitation on the technical solutions of this application.
[0041] Figure 1 This is a flowchart illustrating the steps of a medical image segmentation method based on Fourier transform provided in an embodiment of this application.
[0042] Figure 2This is a diagram of the sub-steps of step S200 provided in the embodiments of this application;
[0043] Figure 3 This is a sub-step diagram of step S400 provided in an embodiment of this application;
[0044] Figure 4 This is a data processing diagram of step S300 provided in an embodiment of this application;
[0045] Figure 5 This is a data processing diagram of step S400 provided in an embodiment of this application. Detailed Implementation
[0046] To make the objectives, technical solutions, and advantages of this application clearer, the following detailed description is provided in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative and not intended to limit the scope of this application.
[0047] It should be noted that although functional modules are divided in the device schematic diagram and a logical order is shown in the flowchart, in some cases, the steps shown or described may be performed in a different order than the module division in the device or the order in the flowchart. The terms "first," "second," etc., in the specification, claims, or the aforementioned drawings are used to distinguish similar objects and are not necessarily used to describe a specific order or sequence.
[0048] The embodiments of this application will be further described below with reference to the accompanying drawings.
[0049] The embodiments of this application provide a medical image segmentation method based on Fourier transform.
[0050] Reference Figure 1 A medical image segmentation method based on Fourier transform includes the following steps:
[0051] Step S100: Obtain the medical image to be segmented;
[0052] Step S200: Encode and decode the medical image to be segmented to obtain a pre-segmentation feature map;
[0053] Step S300: Perform Fourier transform on the medical image to be segmented to obtain frequency domain features, perform inverse Fourier transform on the frequency domain features to obtain inverse transform image, convolve the features obtained by convolution of the inverse transform image and encode the features obtained by encoding the features of the first image to obtain concatenated features, and perform convolution downsampling and pooling processing on the concatenated features to obtain transform features.
[0054] Step S400: The transformation features are downsampled according to different resolutions to obtain multiple downsampled features, and the multiple downsampled features are fused to obtain fused image features;
[0055] Step S500: Generate segmentation head parameters corresponding to various organs based on organ semantic features of fused image features, and configure segmentation heads corresponding to various organs based on segmentation head parameters.
[0056] Step S600: The pre-segmented feature map is segmented using the segmentation head to obtain a segmented image.
[0057] In step S100, a CT scan is performed using a scanner to acquire CT images. For example, the CT images include the pheochromocytoma and surrounding multiple organs. By segmenting the CT images containing the pheochromocytoma and surrounding multiple organs, the adjacent relationship between the tumor and surrounding tissues, as well as the distribution of the tumor's blood supply arteries, can be more clearly displayed, providing important reference information for preoperative surgical planning.
[0058] Preprocessing of CT images: The CT images were aligned to the RAI direction, resampled to 1mm×1mm×1mm, and background removal was performed using thresholding. The images were cropped to 64mm×192mm×192mm and intensity normalized. The images were cropped to the range [500, 500]. Then, z-score normalization was performed based on the mean and standard deviation of the intensity values, followed by data augmentation.
[0059] CT images are input into the image segmentation model as medical images to be segmented.
[0060] Reference Figure 2 For step S200, the medical image to be segmented is encoded and decoded to obtain a pre-segmentation feature map, including the following steps:
[0061] Step S210: Perform multiple downsampling processes on the medical image to be segmented to achieve encoding processing, and obtain an encoded image;
[0062] Step S220: Perform multiple upsampling processes on the encoded image to achieve decoding and obtain a pre-segmented feature map.
[0063] For example, the medical image to be segmented is encoded and decoded using a U-shaped encoder-decoder based on nnU-Net.
[0064] The encoder performs 5 downsampling operations. During each downsampling operation, the resolution of the input feature map is halved using a convolution with a stride of 2. The encoder's first layer has 32 channels, which doubles after each downsampling operation, with the final layer having 320 channels. Given an input image X... ijThe image features output by the encoder are: Where, θ e These are encoder parameters.
[0065] Accordingly, the decoder fuses the corresponding feature maps from the encoder through five upsampling operations to obtain a high-resolution feature representation. With each upsampling operation, the number of decoder output channels is reduced by half, and the decoder output features are: Where, θ de Indicates encoder parameters, It is a pre-segmented feature map, with the number of channels C set to 32.
[0066] The encoder-decoder is designed to generate pre-segmentation feature maps with rich image semantic information, including key visual features of multiple abdominal organs and pheochromocytoma, independent of the specific segmentation task.
[0067] Reference Figure 4 For step S300, the frequency domain features are obtained by performing a Fast Fourier Transform on the medical image to be segmented, which is expressed by the following formula: X F =FFT(X) ij ), where X F It is a frequency domain feature.
[0068] The inverse transformed image is obtained by performing an inverse fast Fourier transform on the result of multiplying the absolute value of the frequency domain features with the transformation matrix. This can be expressed as: X ij =IFFT(|FFT(X) ij )|T M ).
[0069] The transformation matrix is based on the distance L from each pixel in the medical image to be segmented to the center pixel. d The distance from each pixel to the center pixel is obtained by the following formula: The transformation matrix is expressed by the following formula: Where d and n are hyperparameters used to adjust the degree of noise removal, and are empirically set to 10 and 5, respectively. M represents the center point. These are the pixels of the medical image to be segmented.
[0070] The main purpose of the transformation matrix is to filter out noise. After filtering, features are obtained after removing various types of noise.
[0071] Fourier transform frequency domain processing is used to filter out noise and help capture structural information and texture features in the original image. Since the original image features contain a large amount of spatial information, fusing the two to extract a more effective feature representation is crucial. Considering the inherent redundancy in the extracted original image features and structural / texture features, the transformed image is compressed. Features obtained by convolution after concatenating the inverse transform image are then processed. Features obtained by encoding the features of the first image The spliced features are obtained. This enhances the spatial receptive field, reduces the number of features, and supplements the spatial information missing from the Fourier transform.
[0072] The concatenated features are processed by convolutional downsampling to obtain the feature map. Pooling is used to obtain the transformed features. This can be expressed by the following formula:
[0073] Organ edge contour features are extracted using frequency domain processing as prior information. Frequency domain processing is mainly used for noise reduction and filtering, to better capture structural information and texture features in the image, improve the ability to perceive semantic boundaries and subtle boundaries, guide the model to understand complex scenes, and thus improve segmentation accuracy.
[0074] Reference Figure 3 For step S400, the transformed features are downsampled to obtain downsampled features, including the following steps:
[0075] Step S410: Flatten the features to obtain the flattened features;
[0076] Step S420: Perform convolution, reshaping, and layer normalization on the flattened features to obtain the first sub-feature;
[0077] Step S430: Perform linear transformation, convolution, activation function processing, and feature extraction on the first sub-feature to obtain the second sub-feature;
[0078] Step S440: Perform linear transformation and activation function processing on the first sub-feature to obtain the third sub-feature;
[0079] Step S450: Perform a linear transformation on the fusion result of the second sub-feature and the third sub-feature to obtain the downsampled feature.
[0080] For example, the transformed features are instance normalized (IN) to ensure consistency across feature channels, and the ReLU activation function is applied to enhance the nonlinear expression of the features.
[0081] Reference Figure 5The transformed features are then shaped into (B, C, D, H, W), and flattened into (B, C, L), where L = D × H × W. Multi-resolution downsampling is performed using one-dimensional convolution operations, for example, using three different resolutions: 1, 2, and 4. Processing the inputs at three different resolutions enhances the model's perception and understanding of local details and global semantics. Finally, these fused features are mapped to a one-dimensional sequence, and the features at different levels are fused and optimized to obtain downsampled features with different organ semantic relationships.
[0082] Specifically, the first sub-feature is processed by linear transformation, ID convolution, SiLU activation function, and SSM framework feature extraction to obtain the second sub-feature. The first sub-feature is then processed by linear transformation and SiLU activation function to obtain the third sub-feature.
[0083] For step S500, segmentation head parameters corresponding to various organs are generated based on the organ semantic features of the fused image features, and segmentation heads corresponding to various organs are configured according to the segmentation head parameters. For example, the segmentation head parameters are obtained by reducing the dimensionality of the features containing semantic relationships between different organs to 153 using a multilayer perceptron (MLP).
[0084] For step S600, the pre-segmented feature map is segmented using a segmentation head to obtain a segmented image. For example, a segmentation head consisting of three consecutive convolutional layers with 1×1×1 kernels is used. Each segmentation head has 8 channels in the first two layers and 1 channel in the last layer, with a total of 153 parameters. The model is configured with 14 independent segmentation heads, each used to identify and locate a specific organ. The prediction result of the segmented image is expressed by the following formula: Where * denotes convolution, θ k ={θ k1 θ k2 θ k3} represents the convolution segmentation header parameters.
[0085] In the annotated data from different parts, only the anatomical structures of interest are annotated, while the rest are treated as background (default value is 0). Since frequency domain information cannot guide the model to process specific tasks, for a given annotated voxel, its label is definite, providing a clear and accurate supervision signal, while the remaining parts as background are ambiguous, causing uncertainty in model segmentation. To address this issue, this paper improves the loss function, enabling it to annotate voxels on a partial annotated dataset, consider label ambiguity, remove voxels predicted not to belong to the background from the background, and dynamically adjust the loss calculation, effectively mitigating the ambiguity of the background region and further optimizing segmentation accuracy.
[0086] Specifically, the annotation voxels are calculated using supervised loss, employing Dice and cross-entropy loss functions, dynamically adjusted based on a portion of the annotation dataset. The parameters of the model corresponding to the medical image segmentation method are adjusted according to the first loss function: L = l dice +l CE , In the formula, n v p is the number of voxels in the dataset of the nth medical image to be segmented. iL Let y be the probability vector of the i-th voxel with label L. iL Let TP be the one-hot encoded vector of the i-th voxel with label L. L The label of the medical image to be segmented is a true positive, FP L The label indicating a false positive for the medical image to be segmented is FN. L The label of the medical image to be segmented is a false negative, ε is a preset parameter set to 1, and L is the first loss function. dice Let l be the Dice loss function. CE This is the crossover loss function.
[0087] Unannotated voxels are labeled as either the real background or one of m organs. The predictions of unannotated voxels are removed from the background and used as pseudo-labels for loss calculation. The inconsistent number of annotated organs across different datasets causes large fluctuations in the loss function. To make the training process smoother, a dataset weight coefficient is added. The parameters of the model corresponding to the medical image segmentation method are adjusted according to the second loss function; the second loss function is: target=label☉softmax(mask), In the formula, Loss is the second loss function. Let D be the number of categories in the dataset of medical images to be segmented, τ be the number of categories in the expert annotations of the dataset of medical images to be segmented, and D be the number of categories. n Let m be the total number of organ categories in the nth medical image to be segmented, and λ be the total number of organ categories in the medical image to be segmented. n To adjust the parameters, `label` is the ground truth label, `target` is the pseudo-label of the unannotated voxels in the medical image to be segmented after removing the background, `mask` is the unannotated organ segmentation result from the dataset of the medical image to be segmented, and `output` is... L The result represents the segmentation of organ type L, where Φm represents the category annotated in the background.
[0088] The dynamic loss function excludes voxels that are predicted as non-background but annotated as background, and dynamically adjusts the loss calculation for annotated voxels, effectively alleviating the ambiguity of background regions. It plays a key guiding role in the training process and further improves the segmentation quality of tumors and surrounding organs in medical images.
[0089] Embodiments of this application provide a medical image segmentation apparatus based on Fourier transform.
[0090] The medical image segmentation device based on Fourier transform includes: an input unit, an encoding / decoding unit, a Fourier transform unit, a feature fusion unit, a segmentation head parameter generation unit, and a segmentation head unit.
[0091] The system comprises the following components: an input unit for acquiring a medical image to be segmented; an encoding / decoding unit for encoding and decoding the medical image to obtain a pre-segmentation feature map; a Fourier transform unit for performing a Fourier transform on the medical image to obtain frequency domain features, performing an inverse Fourier transform on the frequency domain features to obtain an inverse transform image, concatenating the features obtained by convolution of the inverse transform image with the features obtained by encoding the first image features to obtain concatenated features, and performing convolution downsampling and pooling processing on the concatenated features to obtain transformed features; a feature fusion unit for downsampling the transformed features at different resolutions to obtain multiple downsampled features, and fusing the multiple downsampled features to obtain fused image features; a segmentation head parameter generation unit for generating segmentation head parameters corresponding to various organs based on the organ semantic features of the fused image features, configuring segmentation heads corresponding to various organs based on the segmentation head parameters; and a segmentation head unit for segmenting the pre-segmentation feature map using the segmentation head to obtain a segmented image.
[0092] It is understood that each unit of the medical image segmentation apparatus provided in the embodiments of this application corresponds one-to-one with each step of the medical image segmentation method. The medical image segmentation apparatus and the medical image segmentation method have the same technical solution, solve the same technical problem, and bring about the same technical effect, which will not be described in detail here.
[0093] An embodiment of this application provides an electronic device. The electronic device includes: a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the computer program, it implements the medical image segmentation method based on Fourier transform as described above.
[0094] This electronic device can be any smart terminal, including computers.
[0095] In general, for the hardware structure of electronic devices, the processor can be implemented using a general-purpose CPU (Central Processing Unit), microprocessor, application-specific integrated circuit (ASIC), or one or more integrated circuits, to execute relevant programs and implement the technical solutions provided in the embodiments of this application.
[0096] The memory can be implemented in the form of read-only memory (ROM), static storage device, dynamic storage device, or random access memory (RAM). The memory can store the operating system and other applications. When the technical solutions provided in the embodiments of this specification are implemented through software or firmware, the relevant program code is stored in the memory and is called and executed by the processor.
[0097] Input / output interfaces are used to implement information input and output.
[0098] The communication interface is used to enable communication and interaction between this device and other devices. Communication can be achieved through wired means (such as USB, Ethernet cable, etc.) or wireless means (such as mobile network, WIFI, Bluetooth, etc.).
[0099] The bus transmits information between various components of a device, such as the processor, memory, input / output interfaces, and communication interfaces. The processor, memory, input / output interfaces, and communication interfaces communicate with each other within the device via the bus.
[0100] An embodiment of this application provides a computer storage medium. The computer storage medium stores computer-executable instructions for performing the Fourier transform-based medical image segmentation method described above.
[0101] It will be understood by those skilled in the art that all or some of the steps and systems in the methods disclosed above can be implemented as software, firmware, hardware, and suitable combinations thereof. Some or all of the physical components can be implemented as software executed by a processor, such as a central processing unit, digital signal processor, or microprocessor, or as hardware, or as an integrated circuit, such as an application-specific integrated circuit. Such software can be distributed on a computer-readable medium, which can include computer storage media (or non-transitory media) and communication media (or transient media). As is known to those skilled in the art, the term computer storage media includes volatile and non-volatile, removable and non-removable media implemented in any method or technology for storing information (such as computer-readable instructions, data structures, program modules, or other data). Computer storage media includes, but is not limited to, RAM, ROM, EEPROM, flash memory or other memory technologies, CD-ROM, digital versatile disc (DVD) or other optical disc storage, magnetic cartridges, magnetic tape, disk storage or other magnetic storage devices, or any other medium that can be used to store desired information and is accessible to a computer. Furthermore, it is well known to those skilled in the art that communication media typically contain computer-readable instructions, data structures, program modules, or other data in modulated data signals such as carrier waves or other transmission mechanisms, and may include any information delivery medium. In the foregoing description of this specification, references to terms such as "one embodiment," "another embodiment," or "some embodiments," etc., indicate that a specific feature, structure, material, or characteristic described in connection with an embodiment or example is included in at least one embodiment or example of this application. In this specification, illustrative expressions of the above terms do not necessarily refer to the same embodiment or example. Moreover, the specific features, structures, materials, or characteristics described may be combined in any suitable manner in one or more embodiments or examples.
[0102] Those skilled in the art will understand that all or some of the steps in the methods disclosed above, as well as the functional modules / units in the systems and devices, can be implemented as software, firmware, hardware, or suitable combinations thereof.
[0103] The units described above as separate components may or may not be physically separate. The components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the units can be selected to achieve the purpose of this embodiment according to actual needs.
[0104] Furthermore, the functional units in the various embodiments of this application can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit. The integrated unit can be implemented in hardware or as a software functional unit.
[0105] If the integrated unit is implemented as a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to the prior art, or all or part of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes multiple instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods of the various embodiments of this application. The aforementioned storage medium includes various media capable of storing programs, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.
[0106] In the several embodiments provided in this application, it should be understood that the disclosed apparatus and methods can be implemented in other ways. For example, the apparatus embodiments described above are merely illustrative; for instance, the division of the units described above is only a logical functional division, and in actual implementation, there may be other division methods. For example, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed. Furthermore, the coupling or direct coupling or communication connection shown or discussed between each other may be through some interfaces; the indirect coupling or communication connection between apparatuses or units may be electrical, mechanical, or other forms. Although embodiments of this application have been shown and described, those skilled in the art will understand that various changes, modifications, substitutions, and variations can be made to these embodiments without departing from the principles and spirit of this application, the scope of which is defined by the claims and their equivalents.
[0107] The above is a detailed description of the preferred embodiments of this application, but this application is not limited to the embodiments. Those skilled in the art can make various equivalent modifications or substitutions without departing from the spirit of this application, and these equivalent modifications or substitutions are all included within the scope defined by the claims of this application.
Claims
1. A medical image segmentation method based on Fourier transform, characterized in that, include: Acquire the medical image to be segmented; The medical image to be segmented is encoded and decoded to obtain a pre-segmentation feature map; The frequency domain features are obtained by performing a Fourier transform on the medical image to be segmented, and an inverse Fourier transform is performed on the frequency domain features to obtain an inverse transform image. The features obtained by convolution of the inverse transform image and the features obtained by encoding of the medical image to be segmented are concatenated to obtain concatenated features. The concatenated features are then processed by convolution downsampling and pooling to obtain transformed features. The transformation features are downsampled at different resolutions to obtain multiple downsampled features, and the multiple downsampled features are fused to obtain fused image features; Based on the organ semantic features of the fused image features, segmentation head parameters corresponding to various organs are generated, and segmentation heads corresponding to various organs are configured according to the segmentation head parameters. The segmentation head is used to segment the pre-segmented feature map to obtain a segmented image.
2. The medical image segmentation method based on Fourier transform according to claim 1, characterized in that, The process of encoding and decoding the medical image to be segmented to obtain a pre-segmentation feature map includes: The medical image to be segmented is downsampled multiple times to achieve encoding, resulting in an encoded image; The encoded image is upsampled multiple times to achieve decoding, resulting in a pre-segmented feature map.
3. The medical image segmentation method based on Fourier transform according to claim 1, characterized in that, The step of performing an inverse Fourier transform on the frequency domain features to obtain the inverse transform image includes: The inverse Fourier transform is obtained by multiplying the absolute value of the frequency domain feature with the transformation matrix.
4. The medical image segmentation method based on Fourier transform according to claim 3, characterized in that, The transformation matrix is obtained based on the distance from each pixel of the medical image to be segmented to the center pixel.
5. The medical image segmentation method based on Fourier transform according to claim 1, characterized in that, The transformed features are downsampled to obtain downsampled features, including: Flattening the transformation features yields the flattened features; The flattened feature is subjected to convolution, reshaping, and layer normalization to obtain the first sub-feature. The first sub-feature is processed by linear transformation, convolution, activation function, and feature extraction to obtain the second sub-feature; The first sub-feature is processed by linear transformation and activation function to obtain the third sub-feature; The fusion result of the second sub-feature and the third sub-feature is subjected to linear transformation to obtain the downsampled feature.
6. The medical image segmentation method based on Fourier transform according to claim 1, characterized in that, Also includes: The parameters of the model corresponding to the medical image segmentation method are adjusted according to the first loss function; The first loss function is: In the formula, n v p is the number of voxels in the dataset of the nth medical image to be segmented. iL Let y be the probability vector of the i-th voxel with label L. iL Let TP be the one-hot encoded vector of the i-th voxel with label L. L The label of the medical image to be segmented is a true positive, FP L The label indicating a false positive for the medical image to be segmented is FN. L The label of the medical image to be segmented is a false negative, and ε is a preset parameter. For the first loss function, l Dice Let l be the Dice loss function. CE This is the crossover loss function.
7. The medical image segmentation method based on Fourier transform according to claim 1, characterized in that, Also includes: The parameters of the model corresponding to the medical image segmentation method are adjusted according to the second loss function; The second loss function is: target=label⊙softmax(mask), In the formula, Loss is the second loss function. For the first loss function, Let D be the number of categories in the dataset of medical images to be segmented, τ be the number of categories in the expert annotations of the dataset of medical images to be segmented, and D be the number of categories. n Let m be the total number of organ categories in the nth medical image to be segmented, and λ be the total number of organ categories in the medical image to be segmented. n To adjust the parameters, `label` is the ground truth label, `target` is the pseudo-label of the unannotated voxels in the medical image to be segmented after removing the background, `mask` is the unannotated organ segmentation result from the dataset of the medical image to be segmented, and `output` is... L The result represents the segmentation of organ type L, where Φm represents the category annotated in the background.
8. A medical image segmentation device based on Fourier transform, characterized in that, include: Input unit, used to acquire the medical image to be segmented; The encoding and decoding unit is used to encode and decode the medical image to be segmented to obtain a pre-segmentation feature map. The Fourier transform unit is used to perform Fourier transform on the medical image to be segmented to obtain frequency domain features, perform inverse Fourier transform on the frequency domain features to obtain an inverse transform image, convolve the features obtained by convolution of the inverse transform image and the features obtained by encoding the medical image to be segmented to obtain concatenated features, and perform convolution downsampling and pooling processing on the concatenated features to obtain transform features. The feature fusion unit is used to downsample the transformed features according to different resolutions to obtain multiple downsampled features, and to fuse the multiple downsampled features to obtain fused image features; The segmentation head parameter generation unit is used to generate segmentation head parameters corresponding to various organs based on the organ semantic features of the fused image features, and to configure the segmentation head corresponding to various organs based on the segmentation head parameters. A segmentation head unit is used to segment the pre-segmented feature map using the segmentation head to obtain a segmented image.
9. An electronic device, characterized in that, The electronic device includes a memory and a processor. The memory stores a computer program, and when the processor executes the computer program, it implements the medical image segmentation method based on Fourier transform as described in any one of claims 1 to 7.
10. A computer-readable storage medium storing a computer program, characterized in that, When the computer program is executed by the processor, it implements the medical image segmentation method based on Fourier transform as described in any one of claims 1 to 7.