Adaptive image enhancement method and system based on magnetic resonance imaging
Through the adaptive image enhancement method based on gradient information, the problems of image detail retention and noise suppression in MRI image enhancement are solved, and image quality improvement and diagnostic support are achieved.
Patent Information
- Application Number
- CN202510404858.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-04-02
- Publication Date
- 2025-08-12
- Estimated Expiration
- 2045-04-02
AI Technical Summary
Existing MRI image enhancement methods are difficult to adaptively retain image details and suppress noise, resulting in a degradation of image quality and affecting diagnostic accuracy.
The global gradient map of the MRI image is obtained based on gradient information, the initial seed point collection is extracted, and the region is expanded through grid processing and similarity criteria, and the adjacent blocks are finally merged to output the enhanced MRI image.
Improve the contrast and clarity of MRI images, maintain image continuity and consistency, and enhance the credibility of diagnosis.
Smart Images

Figure CN119919328B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of image processing, and in particular to a magnetic resonance imaging-based adaptive image enhancement method and system thereof. Background Art
[0002] Magnetic resonance imaging (MRI), a non-invasive medical imaging technique, plays a vital role in clinical diagnosis due to its high soft tissue contrast and multi-planar imaging capabilities. However, MRI images are often affected by factors such as noise, artifacts, and inhomogeneous fields, resulting in degraded image quality and posing diagnostic challenges. To improve the visualization and diagnostic accuracy of MRI images, adaptive image enhancement technology has emerged.
[0003] Traditional MRI image enhancement methods mostly rely on fixed filtering algorithms or histogram equalization techniques. These methods often do not work well when processing complex and changeable MRI images, and it is difficult to adaptively retain image details and suppress noise.
[0004] Therefore, it is necessary to provide an adaptive image enhancement method based on magnetic resonance imaging and a system thereof to solve the above technical problems. Summary of the Invention
[0005] To solve the above technical problems, the present invention provides an adaptive image enhancement method and system based on magnetic resonance imaging, which overcomes the shortcomings of existing MRI image enhancement methods in processing complex and changeable images.
[0006] The present invention provides an adaptive image enhancement method based on magnetic resonance imaging, the method comprising the following steps:
[0007] Acquire a global gradient map of the MRI image based on the gradient information, and extract an initial seed point set from the global gradient map according to a preset condition;
[0008] Gridding the MRI image and mapping the gradient information of the global gradient map to each block formed by the gridding;
[0009] For each initial seed point in each block, calculate its comprehensive weight, and screen the seed points according to the preset weight threshold to determine the growth seed points in each block;
[0010] For all blocks, based on the set similarity criterion, the region is expanded in parallel starting from the growth seed point, and the expansion is terminated when the stopping condition is met;
[0011] When overlapping areas appear in adjacent blocks, the adjacent blocks are merged based on the regional merging rules, and the enhanced MRI image is finally output.
[0012] Preferably, the step of acquiring a global gradient map of an MRI image based on gradient information and extracting an initial seed point set from the global gradient map according to preset conditions includes:
[0013] Calculating the gradient intensity and gradient direction of each pixel in the MRI image using an edge detection algorithm;
[0014] Integrate the calculated gradient strength and gradient direction into a global gradient map;
[0015] Determining local extreme points in the global gradient map as candidate seed points;
[0016] Candidate seed points are screened according to the preset gradient intensity threshold and grayscale value range, and candidate seed points that meet the conditions are retained as the initial seed point set.
[0017] Preferably, gridding the MRI image and mapping the gradient information of the global gradient map to each block formed by the gridding includes:
[0018] Divide the MRI image into M×N uniform blocks, wherein the value of M is the quotient of the MRI image width and the preset basic grid size, which is rounded to the integer, and then dynamically adjusted by adding a preset gradient intensity variance adjustment coefficient; the value of N is the quotient of the MRI image height and the preset basic grid size, which is rounded to the integer, and then dynamically adjusted by adding a preset gradient intensity variance adjustment coefficient;
[0019] The gradient information of each pixel in the global gradient map is mapped to the corresponding block according to the spatial position.
[0020] Preferably, for each initial seed point in each block, calculating its comprehensive weight, and screening the seed points according to a preset weight threshold to determine the growth seed points in each block, includes:
[0021] For each initial seed point in each block, the comprehensive weight of the initial seed point is calculated based on its gradient intensity, grayscale value, and the gradient consistency characteristics of the neighboring pixels, where the calculation formula of the comprehensive weight is:
[0022] in, is the comprehensive weight, is the normalized value of the gradient intensity of the initial seed point, is the normalized grayscale value of the initial seed point, is the gradient consistency eigenvalue of the neighborhood pixels of the initial seed point, 、 、 are the weight coefficients of gradient intensity, gray value and gradient consistency features, and satisfy ;
[0023] The comprehensive weight is compared with a dynamic weight threshold, and initial seed points whose comprehensive weight is greater than the weight threshold are screened out as growth seed points in the block.
[0024] Preferably, for all blocks, based on a set similarity criterion, parallel expansion of regions is performed starting from the growth seed point, and the expansion is terminated when a stopping condition is satisfied, including:
[0025] For each growth seed point in each block, based on the similarity criterion, expand from the growth seed point to its neighboring pixels, and add the neighboring pixels that meet the similarity criterion to the current growth area, wherein the similarity criterion includes a gray value difference threshold and a gradient intensity difference threshold;
[0026] Dynamically adjust the parameter values of the similarity criterion during the expansion process to adapt to the local characteristics of the target area;
[0027] The extension terminates when any of the following stop conditions are met:
[0028] The number of newly added pixels in the current expansion area is lower than the preset minimum growth threshold;
[0029] None of the boundary pixels of the current expanded area meet the similarity criterion;
[0030] The area of the current expansion area has reached the preset maximum area limit.
[0031] Preferably, the dynamically adjusting the parameter value of the similarity criterion comprises the following steps:
[0032] Counting pixel features of the current growth area, wherein the pixel features include grayscale mean and gradient intensity mean;
[0033] Update the parameter values of the similarity criterion according to the pixel features of the current growth area, including:
[0034] The grayscale value difference threshold is updated to a multiple of the standard deviation of the grayscale mean of the current growth area;
[0035] The gradient intensity difference threshold is updated to a multiple of the standard deviation of the mean value of the gradient intensity in the current growth area.
[0036] Preferably, the merging of adjacent blocks based on the region merging rule includes:
[0037] Detect the overlapping area of adjacent block extension areas and extract the grayscale mean, gradient direction histogram and texture feature vector of each pixel in the overlapping area;
[0038] Calculate the grayscale distribution similarity, gradient direction histogram cosine similarity and texture feature Euclidean distance of adjacent blocks in the overlapping area;
[0039] A block merge is performed when the following merge conditions are met at the same time:
[0040] The grayscale distribution similarity is greater than the preset grayscale similarity threshold,
[0041] The cosine similarity of the gradient direction histogram is greater than the preset direction consistency threshold.
[0042] And the Euclidean distance of texture features is less than a preset texture difference threshold.
[0043] The present invention also provides an adaptive image enhancement system based on magnetic resonance imaging, for performing an adaptive image enhancement method based on magnetic resonance imaging, the system comprising:
[0044] An initial seed point determination module is used to obtain a global gradient map of the MRI image based on gradient information, and extract an initial seed point set from the global gradient map according to preset conditions;
[0045] A gridding module, configured to grid the MRI image and map the gradient information of the global gradient map to each gridded block;
[0046] A growth seed determination module is used to calculate the comprehensive weight of each initial seed point in each block, and screen the seed points according to a preset weight threshold to determine the growth seed points in each block;
[0047] A region growing module is used to perform parallel region expansion starting from the growth seed point for all blocks based on a set similarity criterion, and terminate when the expansion meets a stopping condition;
[0048] The region adjustment module is used to merge adjacent blocks based on the region merging rules when overlapping areas appear in adjacent blocks, and finally output the enhanced MRI image.
[0049] Compared with related technologies, the adaptive image enhancement method based on magnetic resonance imaging and the system thereof provided by the present invention have the following beneficial effects:
[0050] First, the global gradient map of the MRI image is obtained based on the gradient information, and the initial seed point set is extracted from the global gradient map according to preset conditions to ensure that the selection of seed points is both accurate and efficient. Then, the MRI image is gridded, and the gradient information of the global gradient map is mapped to each block for subsequent regional expansion. During the regional expansion process, the method determines the growth seed point by calculating the comprehensive weight of each initial seed point and screening the seed points according to the preset weight threshold. At the same time, based on the set similarity criterion, the region is expanded in parallel from the growth seed point, and the parameter value of the similarity criterion is dynamically adjusted during the expansion process to adapt to the local characteristics of the target area. Finally, when overlapping areas appear in adjacent blocks, the adjacent blocks are merged based on the regional merging rules to ensure that the enhanced MRI image maintains continuity and consistency globally. BRIEF DESCRIPTION OF THE DRAWINGS
[0051] Figure 1 A flowchart of an adaptive image enhancement method based on magnetic resonance imaging provided by the present invention;
[0052] Figure 2 This is a module structure diagram of an adaptive image enhancement system based on magnetic resonance imaging provided by the present invention. DETAILED DESCRIPTION
[0053] The present invention will be further described in detail below with reference to the accompanying drawings and examples. It will be understood that the specific embodiments described herein are intended only to illustrate the present invention and are not intended to limit the present invention. It should also be noted that, for ease of description, the accompanying drawings only illustrate portions relevant to the present invention, not all of the structures. Furthermore, the embodiments of the present invention and the features of the embodiments may be combined with one another unless there is a conflict.
[0054] It should also be noted that, for ease of description, only portions relevant to the present invention are shown in the accompanying drawings, rather than all of the contents. Before discussing the exemplary embodiments in more detail, it should be noted that some exemplary embodiments are described as processes or methods depicted as flowcharts. Although the flowcharts describe the various operations (or steps) as sequential processes, many of the operations can be performed in parallel, concurrently, or simultaneously. In addition, the order of the various operations can be rearranged. The process can be terminated when its operations are completed, but may also have additional steps not included in the accompanying drawings. The process can correspond to a method, function, procedure, subroutine, subprogram, etc. Example 1
[0055] The present invention provides an adaptive image enhancement method based on magnetic resonance imaging, referring to Figure 1 As shown, the method includes the following steps:
[0056] S1: Acquire a global gradient map of the MRI image based on gradient information, and extract an initial seed point set from the global gradient map according to preset conditions.
[0057] Wherein, step S1 specifically includes the following steps:
[0058] S11: Calculate the gradient intensity and gradient direction of each pixel in the MRI image using an edge detection algorithm.
[0059] In this embodiment, an edge detection algorithm (including but not limited to the Sobel operator) is used to perform pixel-by-pixel gradient analysis on MRI images. Spatial derivatives are calculated using horizontal and vertical convolution kernels, along with the gradient strength and direction. This process uses Gaussian filtering to suppress noise interference, effectively distinguishing grayscale transition regions between different tissues while preserving anatomical edge features. The technical effect is reflected in the precise quantification of edge saliency at each location in the image, providing a mathematical representation of spatial gradient features for subsequent seed point extraction.
[0060] S12: Integrate the calculated gradient strength and gradient direction into a global gradient map.
[0061] In this embodiment, a structured integration of gradient information is achieved by constructing a dual-channel data matrix. The gradient intensity of each pixel is mapped to the amplitude channel of the matrix, and the gradient direction is encoded as the angle channel, forming a global gradient map with a spatial correspondence. This process uses normalization to scale the gradient intensity to a range of 0-255 to facilitate subsequent threshold processing. The technical advantage lies in establishing a unified spatial reference framework, which enables the gradient distribution characteristics of each region to be quickly located during subsequent block processing, while reducing the resource consumption caused by repeated calculations.
[0062] S13: Determine local extreme points in the global gradient map as candidate seed points.
[0063] In this embodiment, a sliding window mechanism is used to search for local extreme values on the gradient intensity map. A 3×3 neighborhood window is set to traverse the entire image, and the pixel with the largest gradient intensity in the center of the window is retained as a candidate seed point through the non-maximum suppression algorithm. This process introduces eight-neighborhood directional interpolation technology to perform sub-pixel extreme value judgment along the gradient direction to improve edge positioning accuracy. This effectively screens out the key feature points of the true anatomical boundary, eliminates the pseudo-edge response caused by gradient diffusion, and concentrates the candidate seed points in the strong gradient area at the tissue junction.
[0064] S14: Screening candidate seed points according to a preset gradient intensity threshold and grayscale value range, and retaining candidate seed points that meet the conditions as an initial seed point set.
[0065] In this embodiment, the seed point set is optimized by dual constraints. First, an adaptive gradient threshold is applied. ( is the global gradient mean, is the standard deviation, The algorithm uses a preset adjustment coefficient (e.g., a pre-set threshold value, obtained experimentally) to initially filter the global gradient mean, removing noise points in low-contrast areas. A secondary filter is then applied based on the target tissue's a priori grayscale range to eliminate artifacts in areas of non-interest. This hierarchical screening mechanism dynamically adjusts threshold parameters to significantly reduce the false positive rate while maintaining sensitivity. This ensures that the spatial distribution density of the final seed point set matches the complexity of the target anatomical structure, providing high-quality starting points for subsequent region growth.
[0066] S2: Gridding the MRI image, and mapping the gradient information of the global gradient map to each block formed by the gridding.
[0067] Wherein, step S2 includes the following steps:
[0068] S21: Divide the MRI image into M×N uniform blocks, wherein the value of M is the quotient of the MRI image width and the preset basic grid size, which is rounded up, and then dynamically adjusted by adding a preset gradient intensity variance adjustment coefficient; the value of N is the quotient of the MRI image height and the preset basic grid size, which is rounded up, and then dynamically adjusted by adding a preset gradient intensity variance adjustment coefficient.
[0069] In this embodiment, the MRI image is divided into M×N uniform blocks, with the number of blocks directly controlled by a preset gradient strength variance adjustment coefficient. In practice, the image is initially partitioned based on a preset base grid size (e.g., 16×16 pixels). The original M value is the image width divided by the base grid size, rounded down, and the original N value is the image height divided by the same base grid size, rounded down. Subsequently, a preset gradient strength variance adjustment coefficient (e.g., 1.2 or 0.8) is multiplied by the original M and N values to determine the final number of blocks.
[0070] For example, if the original image is divided into 20×15 blocks and the adjustment coefficient is 1.2, the number of adjusted blocks will be 24×18. This coefficient is a pre-set fixed value, and its size directly reflects the required block density. If the coefficient is greater than 1, the blocks are denser to enhance local processing accuracy; if the coefficient is less than 1, the number of blocks is reduced to reduce computational complexity. After the block division is completed, the size of each block may no longer be completely uniform, but the overall grid structure is maintained.
[0071] S22: Mapping the gradient information of each pixel in the global gradient map to the corresponding block according to the spatial position.
[0072] In this embodiment, the coordinate range of each block is determined by the block division result of step S21. The system traverses each pixel in the global gradient map and fills the gradient strength and direction data into the corresponding block according to its coordinates.
[0073] For example, if the coordinates of a block's upper left corner are (x1, y1) and its lower right corner are (x2, y2), then all pixel gradient information satisfying x1 ≤ x < x2 and y1 ≤ y < y2 is assigned to that block. Each block independently stores a gradient magnitude matrix and gradient direction histogram to form a local gradient feature description. This mapping process is implemented by establishing a block index table to ensure efficient data access.
[0074] S3: For each initial seed point in each block, calculate its comprehensive weight, and screen the seed points according to the preset weight threshold to determine the growth seed points in each block.
[0075] Wherein, step S3 specifically includes the following steps:
[0076] S31: For each initial seed point in each block, calculate the comprehensive weight of the initial seed point based on its gradient intensity, grayscale value, and gradient consistency characteristics of neighboring pixels, wherein the calculation formula of the comprehensive weight is:
[0077] in, is the comprehensive weight, is the normalized value of the gradient intensity of the initial seed point, is the normalized grayscale value of the initial seed point, is the gradient consistency eigenvalue of the neighborhood pixels of the initial seed point, 、 、 are the weight coefficients of gradient intensity, gray value and gradient consistency features, and satisfy .
[0078] In this embodiment, the gradient intensity normalization value is obtained by linearly mapping the ratio of the gradient intensity of the seed point to the maximum gradient intensity within the block, ensuring that it ranges between 0 and 1. The grayscale value normalization value is obtained by mapping the seed point grayscale value to a percentage of the entire MRI image grayscale dynamic range. For example, if the image grayscale range is 0-255 and the grayscale value of a pixel is 128, the normalization result is 0.5. The gradient consistency eigenvalue is calculated by analyzing the gradient direction differences of pixels in a 3×3 neighborhood around the seed point and quantifying it using the inverse function of the direction angle standard deviation: first, the standard deviation of the gradient direction of each pixel in the neighborhood is calculated, and then converted into a consistency index using 1 / (1 + standard deviation). Finally, the three normalized eigenvalues are substituted into the weighting formula, where the weight coefficients α, β, and γ are dynamically adjusted based on the gradient intensity variance of the grid block, giving higher weight to gradient features in areas with complex texture (high variance) and increasing the weight proportion of grayscale features in uniform areas (low variance), achieving adaptive feature fusion.
[0079] S32: Compare the comprehensive weight with a dynamic weight threshold, and select initial seed points whose comprehensive weight is greater than the weight threshold as growth seed points in the block.
[0080] In this embodiment, the weight threshold includes a basic threshold, which is determined based on the median of the comprehensive weights of all initial seed points in the block, and a compensation term for the mean gradient intensity of the block is superimposed: for blocks whose mean gradient intensity is 20% higher than the mean of the overall image, the threshold is automatically reduced by 5% to retain more edge seeds; otherwise, the threshold is increased by 3% to suppress noise interference.
[0081] Spatial continuity constraints are applied during screening. When a seed point of a particular type exists within the 8-neighborhood of a selected seed point, the threshold is temporarily relaxed by 10% to ensure the density of seed points in important edge areas. This screening mechanism effectively filters out isolated noise points (such as pseudo-gradient points generated by random noise) while retaining true tissue boundary seed points with spatial continuity, providing high-quality starting points for subsequent region growth.
[0082] S4: For all blocks, based on the set similarity criterion, the region is expanded in parallel starting from the growth seed point, and the expansion is terminated when the stopping condition is met.
[0083] Wherein, step S4 specifically includes the following steps:
[0084] S41: For the growth seed point in each block, based on the similarity criterion, expand from the growth seed point to its neighboring pixels, and add the neighboring pixels that meet the similarity criterion to the current growth area, wherein the similarity criterion includes a grayscale value difference threshold and a gradient intensity difference threshold.
[0085] In this embodiment, for the eight neighboring pixels around the current growth seed point, the absolute difference in grayscale mean and the absolute difference in gradient intensity between the pixel and the region where the seed point is located are calculated. If the grayscale difference of a neighboring pixel is less than the grayscale value difference threshold and the gradient difference is less than the gradient intensity difference threshold, the pixel is included in the current growth region and marked as a new pixel. This process continues to expand outward in an iterative manner, gradually merging pixels that meet the similarity conditions into the same region. This can effectively capture the continuity characteristics of the target region, reduce the misjudgment of noise pixels, and ensure the smoothness and consistency of the region boundary.
[0086] S42: dynamically adjusting the parameter value of the similarity criterion during the expansion process to adapt to the local characteristics of the target area;
[0087] The extension terminates when any of the following stop conditions are met:
[0088] The number of newly added pixels in the current expansion area is lower than the preset minimum growth threshold;
[0089] None of the boundary pixels of the current expanded area meet the similarity criterion;
[0090] The area of the current expansion area has reached the preset maximum area limit.
[0091] The dynamic adjustment of the parameter value of the similarity criterion includes the following steps:
[0092] Counting pixel features of the current growth area, wherein the pixel features include grayscale mean and gradient intensity mean.
[0093] Update the parameter values of the similarity criterion according to the pixel features of the current growth area, including:
[0094] The grayscale value difference threshold is updated to a multiple of the standard deviation of the grayscale mean of the current growth area;
[0095] The gradient intensity difference threshold is updated to a multiple of the standard deviation of the mean value of the gradient intensity in the current growth area.
[0096] During the expansion process, the parameters of the similarity criterion are dynamically adjusted according to the local characteristics of the current growing area. Specifically, after each expansion, the grayscale mean and gradient intensity mean of the pixels in the area are counted, and their standard deviation is calculated. Subsequently, the grayscale value difference threshold is updated to 1.5 times the standard deviation of the grayscale mean of the current area, and the gradient intensity difference threshold is updated to 1.2 times the standard deviation of the gradient intensity mean. This dynamic adjustment strategy enables the algorithm to adapt to the heterogeneity of different tissues or lesion areas. For example, in the tumor edge area with large grayscale changes, the threshold is automatically relaxed to accommodate larger local differences; while in the cerebrospinal fluid area with uniform grayscale, the threshold is tightened to avoid over-segmentation. By providing real-time feedback of local statistical features, the adaptability of the algorithm to complex MRI images is enhanced.
[0097] The termination condition of region expansion is achieved through triple judgment. First, if the number of newly added pixels in a single expansion is lower than the preset minimum growth threshold (such as 5 pixels), the region growth is judged to be saturated and the expansion is terminated to avoid invalid calculations. Secondly, if all the boundary pixels of the current expansion area do not meet the similarity criterion, it indicates that the area has been completely surrounded and cannot be extended further, and the process stops immediately. Finally, when the area of the region exceeds the preset maximum limit (such as 60% of the block area), forced termination is performed to prevent excessive expansion across blocks from affecting the subsequent merging logic. These three conditions work together to ensure the complete capture of key areas, effectively control the computational complexity, avoid global structural distortion caused by local overgrowth, and thus achieve a balance between efficiency and accuracy.
[0098] S5: When overlapping areas appear in adjacent blocks, the adjacent blocks are merged based on the regional merging rule, and the enhanced MRI image is finally output.
[0099] Wherein, step S5 includes the following steps:
[0100] S51: Detecting the overlapping area of adjacent block extension areas, and extracting the grayscale mean, gradient direction histogram and texture feature vector of each pixel in the overlapping area.
[0101] S52: Calculate the grayscale distribution similarity, gradient direction histogram cosine similarity and texture feature Euclidean distance of adjacent blocks in the overlapping area.
[0102] S53: merging blocks when the following merging conditions are met simultaneously:
[0103] The grayscale distribution similarity is greater than the preset grayscale similarity threshold,
[0104] The cosine similarity of the gradient direction histogram is greater than the preset direction consistency threshold.
[0105] And the Euclidean distance of texture features is less than a preset texture difference threshold.
[0106] In this embodiment, the set of overlapping pixels at the boundaries of adjacent blocks is first determined by comparing coordinate ranges. For each overlapping pixel, its grayscale value, gradient direction angle (based on the directional channel data of the global gradient map), and texture feature vector (calculated using the local binary pattern (LBP) algorithm) are extracted. The grayscale mean is obtained by calculating the arithmetic mean of the grayscale values of all pixels in the overlapping area; the gradient direction histogram is obtained by dividing the direction angle into 36 bins with 10-degree intervals and performing frequency statistics to form a 36-dimensional histogram vector; the texture feature is generated by generating an 8-bit binary code using the LBP operator with a 3×3 window, and the LBP pattern distribution histogram of all pixels in the statistical area is used as a 128-dimensional feature vector. This process provides a quantitative basis for structure, direction, and texture for subsequent similarity measurement through multi-dimensional representation of spatial features, effectively avoiding the limitations of single feature criteria.
[0107] During the similarity calculation phase, the Bhattacharyya distance is used to measure the grayscale distribution similarity between the overlapping regions of two blocks. Smaller values indicate closer distributions. The cosine similarity of the gradient direction histograms is calculated by normalizing two 36-dimensional histogram vectors and then calculating the dot product, reflecting the spatial consistency of the gradient direction distribution. The Euclidean distance of the texture feature directly calculates the L2 norm distance between two 128-dimensional LBP feature vectors. In specific implementation, the grayscale similarity threshold is set to 0.8 (Bhattacharyya distance ≤ 0.2 corresponds to similarity ≥ 0.8), the direction consistency threshold is set to 0.75, and the texture difference threshold is set to 120. These parameters are optimized through training with a large number of medical image samples to ensure robustness in scenarios such as brain tissue segmentation and tumor edge enhancement. This multi-feature fusion metric significantly improves the reliability of region merging decisions, particularly in areas with blurred tissue boundaries or noise interference, accurately identifying true anatomical continuity.
[0108] When the merging conditions are met, the block region fusion operation is performed. First, the pixels in the overlapping area are marked as common areas and uniformly assigned to the dominant block with the larger area in the adjacent blocks. Subsequently, the bilinear interpolation method is used to smooth the grayscale transition at the merge boundary, and the gradient consistency weight of the boundary pixels is recalculated based on the gradient direction histogram of the merged area. This process synchronously updates the block index table to ensure data consistency in subsequent processing stages. Through this merging mechanism based on multi-dimensional feature similarity, the pseudo-boundaries introduced by artificial blocking can be effectively eliminated, the integrity of the continuous anatomical structure can be restored, and the clear boundary between the lesion area and the normal tissue can be retained. The final output enhanced image achieves global structural coherence while maintaining the sharpness of local details, providing highly reliable imaging support for clinical diagnosis. Example 2
[0109] The present invention also provides an adaptive image enhancement system based on magnetic resonance imaging, which is used to perform an adaptive image enhancement method based on magnetic resonance imaging, referring to Figure 2 As shown, the system includes:
[0110] The initial seed point determination module 100 is configured to obtain a global gradient map of the MRI image based on gradient information, and extract an initial seed point set from the global gradient map according to preset conditions.
[0111] The gridding module 200 is configured to grid the MRI image and map the gradient information of the global gradient map to each block formed by the gridding.
[0112] The growth seed determination module 300 is used to calculate the comprehensive weight of each initial seed point in each block, and screen the seed points according to a preset weight threshold to determine the growth seed points in each block.
[0113] The region growing module 400 is configured to perform parallel region expansion starting from the growth seed point for all blocks based on a set similarity criterion, and terminate the expansion when the expansion satisfies a stopping condition.
[0114] The region adjustment module 500 is used to merge adjacent blocks based on region merging rules when overlapping regions appear between adjacent blocks, and finally output an enhanced MRI image.
[0115] The present application is described with reference to the flowcharts and / or block diagrams of the methods, devices (systems) and computer program products according to the embodiments of the present application. It should be understood that each process and / or box in the flowchart and / or block diagram, as well as the combination of processes and / or boxes in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor or other programmable data processing device to produce a machine, so that the instructions executed by the processor of the computer or other programmable data processing device generate instructions for implementing the processes in the flowchart and / or block diagram. Figure 1 a process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in a block or multiple blocks.
[0116] Those skilled in the art will appreciate that all or part of the steps in the various methods of the above embodiments can be completed by instructing related hardware through a program. The program can be stored in a computer-readable storage medium, including a read-only memory (ROM), a random access memory (RAM), a programmable read-only memory (PROM), an erasable programmable read-only memory (EPROM), a one-time programmable read-only memory (OTPROM), an electronically erasable programmable read-only memory (EEPROM), a compact disc read-only memory (CD-ROM), or other optical disc storage, magnetic disk storage, or magnetic tape storage, or any other computer-readable medium capable of carrying or storing data.
[0117] It should also be noted that the terms "comprises," "includes," or any other variations thereof are intended to encompass non-exclusive inclusion, such that a process, method, commodity, or apparatus that includes a series of elements includes not only those elements but also other elements not explicitly listed, or includes elements inherent to such process, method, commodity, or apparatus. In the absence of further limitations, an element defined by the phrase "comprises a..." does not exclude the presence of other identical elements in the process, method, commodity, or apparatus that includes the element.
Claims
1. An adaptive image enhancement method based on magnetic resonance imaging, characterized in that: The method comprises the following steps: Acquire a global gradient map of the MRI image based on the gradient information, and extract an initial seed point set from the global gradient map according to a preset condition; The MRI image is gridded, and the gradient information of the global gradient map is mapped to each block formed by the gridding, wherein the mapping specifically comprises the following steps: Divide the MRI image into M×N uniform blocks, wherein the value of M is the quotient of the MRI image width and the preset basic grid size, which is rounded to the integer, and then dynamically adjusted by adding a preset gradient intensity variance adjustment coefficient; the value of N is the quotient of the MRI image height and the preset basic grid size, which is rounded to the integer, and then dynamically adjusted by adding a preset gradient intensity variance adjustment coefficient; Mapping the gradient information of each pixel in the global gradient map to the corresponding block according to the spatial position; For each initial seed point in each block, calculate its comprehensive weight, and screen the seed points according to the preset weight threshold to determine the growth seed points in each block; For all blocks, based on the set similarity criterion, the region is expanded in parallel starting from the growth seed point, and the expansion is terminated when the stopping condition is met; When overlapping areas appear in adjacent blocks, the adjacent blocks are merged based on the regional merging rules, and the enhanced MRI image is finally output.
2. The adaptive image enhancement method based on magnetic resonance imaging according to claim 1, characterized in that: The step of acquiring a global gradient map of the MRI image based on the gradient information and extracting an initial seed point set from the global gradient map according to a preset condition includes: Calculating the gradient intensity and gradient direction of each pixel in the MRI image using an edge detection algorithm; Integrate the calculated gradient strength and gradient direction into a global gradient map; Determining local extreme points in the global gradient map as candidate seed points; Candidate seed points are screened according to the preset gradient intensity threshold and grayscale value range, and candidate seed points that meet the conditions are retained as the initial seed point set.
3. The adaptive image enhancement method based on magnetic resonance imaging according to claim 2, characterized in that: The method of calculating the comprehensive weight of each initial seed point in each block and screening the seed points according to a preset weight threshold to determine the growth seed points in each block includes: For each initial seed point in each block, the comprehensive weight of the initial seed point is calculated based on its gradient intensity, grayscale value, and the gradient consistency characteristics of the neighboring pixels, where the calculation formula of the comprehensive weight is: ; in, is the comprehensive weight, is the normalized value of the gradient intensity of the initial seed point, is the normalized grayscale value of the initial seed point, is the gradient consistency eigenvalue of the neighborhood pixels of the initial seed point, 、 、 are the weight coefficients of gradient intensity, gray value and gradient consistency features, and satisfy ; The comprehensive weight is compared with a dynamic weight threshold, and initial seed points whose comprehensive weight is greater than the weight threshold are screened out as growth seed points in the block.
4. The adaptive image enhancement method based on magnetic resonance imaging according to claim 3, characterized in that: For all blocks, based on the set similarity criterion, the region is expanded in parallel starting from the growth seed point, and the expansion is terminated when the stopping condition is met, including: For each growth seed point in each block, based on the similarity criterion, expand from the growth seed point to its neighboring pixels, and add the neighboring pixels that meet the similarity criterion to the current growth area, wherein the similarity criterion includes a gray value difference threshold and a gradient intensity difference threshold; Dynamically adjust the parameter values of the similarity criterion during the expansion process to adapt to the local characteristics of the target area; The extension terminates when any of the following stop conditions are met: The number of newly added pixels in the current expansion area is lower than the preset minimum growth threshold; None of the boundary pixels of the current expanded area meet the similarity criterion; The area of the current expansion area has reached the preset maximum area limit.
5. The adaptive image enhancement method based on magnetic resonance imaging according to claim 4, characterized in that: The dynamic adjustment of the parameter value of the similarity criterion includes the following steps: Counting pixel features of the current growth area, wherein the pixel features include grayscale mean and gradient intensity mean; Update the parameter values of the similarity criterion according to the pixel features of the current growth area, including: The grayscale value difference threshold is updated to a multiple of the standard deviation of the grayscale mean of the current growth area; The gradient intensity difference threshold is updated to a multiple of the standard deviation of the mean value of the gradient intensity in the current growth area.
6. The adaptive image enhancement method based on magnetic resonance imaging according to claim 5, characterized in that: The merging of adjacent blocks based on the region merging rule includes: Detect the overlapping area of adjacent block extension areas and extract the grayscale mean, gradient direction histogram and texture feature vector of each pixel in the overlapping area; Calculate the grayscale distribution similarity, gradient direction histogram cosine similarity and texture feature Euclidean distance of adjacent blocks in the overlapping area; A block merge is performed when the following merge conditions are met at the same time: The grayscale distribution similarity is greater than the preset grayscale similarity threshold, The cosine similarity of the gradient direction histogram is greater than the preset direction consistency threshold. And the Euclidean distance of texture features is less than a preset texture difference threshold.
7. An adaptive image enhancement system based on magnetic resonance imaging, configured to execute the adaptive image enhancement method based on magnetic resonance imaging according to any one of claims 1 to 6, characterized in that: The system comprises: An initial seed point determination module is used to obtain a global gradient map of the MRI image based on gradient information, and extract an initial seed point set from the global gradient map according to preset conditions; A gridding module is used to grid the MRI image and map the gradient information of the global gradient map to each block formed by the gridding, wherein the mapping specifically includes the following steps: Divide the MRI image into M×N uniform blocks, wherein the value of M is the quotient of the MRI image width and the preset basic grid size, which is rounded to the integer, and then dynamically adjusted by adding a preset gradient intensity variance adjustment coefficient; the value of N is the quotient of the MRI image height and the preset basic grid size, which is rounded to the integer, and then dynamically adjusted by adding a preset gradient intensity variance adjustment coefficient; Mapping the gradient information of each pixel in the global gradient map to the corresponding block according to the spatial position; A growth seed determination module is used to calculate the comprehensive weight of each initial seed point in each block, and screen the seed points according to a preset weight threshold to determine the growth seed points in each block; A region growing module is used to perform parallel region expansion starting from the growth seed point for all blocks based on a set similarity criterion, and terminate when the expansion meets a stopping condition; The region adjustment module is used to merge adjacent blocks based on the region merging rules when overlapping areas appear in adjacent blocks, and finally output the enhanced MRI image.
Citation Information
Patent Citations
Model training method, tumor segmentation method and electronic equipment
CN119169026A
CT image segmentation method for spine surgery
CN119579623A