X-ray image enhancement method, system and device and medium

By performing edge-keeping filtering, morphological processing and differential on X-ray images, the enhancement weight is allocated according to the brightness distribution, and the problem of targeted enhancement in the prior art is solved, and a more efficient image enhancement effect is achieved.

CN120088173APending Publication Date: 2025-06-03IRAY TECHNOLOGY CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202510022455.1
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-01-07
Publication Date
2025-06-03

AI Technical Summary

Technical Problem

Existing X-ray image enhancement methods cannot be targeted to enhance according to the actual needs of different regions in the image, resulting in the degree of enhancement of some regions being too low or too high, and the clarity and contrast of the image cannot be effectively improved.

Method used

By performing edge-keeping filtering and morphological processing on the enhanced image, the difference is divided into high-brightness and low-brightness areas according to the brightness distribution, and the enhancement weight is assigned respectively to generate the total weight enhancement image, and image fusion is performed to enhance the image.

Benefits of technology

It realizes targeted enhancement of different regions according to the image brightness distribution, improves the clarity and contrast of X-ray images, and is especially suitable for enhancing images containing metal objects, avoiding the generation of edge artifacts.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120088173A_ABST
    Figure CN120088173A_ABST
Patent Text Reader

Abstract

The invention provides an X-ray image enhancement method, which comprises the following steps of: performing edge-preserving filtering on an image to be enhanced to obtain a filtered image; performing morphological processing on the filtered image to obtain a morphological image; carrying out difference on the to-be-enhanced image and the morphological image to obtain a difference image; dividing the difference image into a high-brightness image and a low-brightness image; respectively distributing a corresponding high-brightness enhancement weight to each pixel of the high-brightness image to obtain a high-brightness weight enhancement image; respectively distributing a corresponding low-brightness enhancement weight to each pixel of the low-brightness image to obtain a low-brightness weight enhancement image; obtaining a total weight enhanced image based on the high-brightness weight enhanced image and the low-brightness weight enhanced image; and enhancing the image by using the total weight, and enhancing the to-be-enhanced image to obtain an enhanced image. According to the X-ray image enhancement method, artifacts are avoided while the edge of the object is enhanced, and the enhancement effect on the X-ray image is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application belongs to the technical field of X-ray image processing, and particularly relates to an X-ray image enhancement method, system, device and medium. Background Art

[0002] X-ray images can display the human body tissue structure and help researchers master the human body pathological information, and are an indispensable tool in the medical diagnosis and treatment process.

[0003] Currently, during the imaging process of X-ray images, blurring or uneven gray-scale distribution will occur, and image enhancement technology is required to improve the clarity and contrast of X-ray images, making the details in the images clearer and facilitating doctors to accurately master the human body pathological information. In the prior art, unsharp masking is usually used to enhance X-ray images. It creates a mask that highlights edges and detail information by subtracting a blurred version of the original X-ray image from the original X-ray image. After multiplying the mask by a weight factor, the weighted mask is used to enhance the original X-ray image. However, since unsharp masking uses a unified weight factor to weight the mask, when enhancing the original X-ray image based on the weighted mask, the enhancement degree of each region in the original X-ray image is the same, and it is impossible to enhance the original X-ray image according to the actual required enhancement degree of different regions in the original X-ray image, which easily leads to too low enhancement degree in some regions and too high enhancement degree in some regions in the enhanced original X-ray image, and the improvement of the clarity and contrast of X-ray images is limited.

[0004] Based on this, how to enhance X-ray images according to the actual required enhancement degree of different regions in X-ray images and improve the enhancement effect of X-ray images is an important problem that needs to be solved urgently at present. Summary of the Invention

[0005] In view of the above-mentioned disadvantages of the prior art, the purpose of this application is to provide an X-ray image enhancement method, which is used to solve the problems that the existing X-ray image enhancement methods cannot enhance X-ray images according to the actual required enhancement degree of different regions in X-ray images, and the improvement of the clarity and contrast of X-ray images is limited.

[0006] To achieve the above purpose and other related purposes, the present invention provides an X-ray image enhancement method, including the following steps:

[0007] Perform edge-preserving filtering on the image to be enhanced to obtain a filtered image;

[0008] Perform morphological processing on the filtered image to obtain a morphological image; perform difference between the image to be enhanced and the morphological image to obtain a difference image;

[0009] Divide the differential image into a high-brightness image and a low-brightness image according to the brightness distribution; assign corresponding high-brightness enhancement weights to each pixel of the high-brightness image to obtain a high-brightness weighted enhanced image; and, assign corresponding low-brightness enhancement weights to each pixel of the low-brightness image to obtain a low-brightness weighted enhanced image;

[0010] Based on the high-brightness weighted enhanced image and the low-brightness weighted enhanced image, obtain a total weighted enhanced image; use the total weighted enhanced image to enhance the image to be enhanced to obtain an enhanced image.

[0011] In an embodiment of the present invention, the method for obtaining the morphological image includes:

[0012] Select a corresponding morphological processing algorithm according to the brightness relationship between the object and the background in the filtered image; use the corresponding morphological processing algorithm to perform the morphological processing on the filtered image to obtain the morphological image after the morphological processing.

[0013] In an embodiment of the present invention, the method for obtaining the high-brightness weighted enhanced image and the low-brightness weighted enhanced image includes:

[0014] Based on the pixel values of each pixel of the high-brightness image, obtain the corresponding high-brightness enhancement weights of each pixel of the high-brightness image according to a preset first pixel weight mapping formula; multiply each pixel of the high-brightness image by the corresponding high-brightness enhancement weight to obtain the high-brightness weighted enhanced image;

[0015] Based on the pixel values of each pixel of the low-brightness image, obtain the corresponding low-brightness enhancement weights of each pixel of the low-brightness image according to a preset second pixel weight mapping formula; multiply each pixel of the low-brightness image by the corresponding low-brightness enhancement weight to obtain the low-brightness weighted enhanced image.

[0016] In an embodiment of the present invention, the first pixel weight mapping formula is a non-linear function in which the first pixel weight changes with the pixel value of each pixel of the high-brightness image; the second pixel weight mapping formula is a non-linear function in which the second pixel weight changes with the pixel value of each pixel of the low-brightness image.

[0017] In an embodiment of the present invention, the method for obtaining the total weighted enhanced image includes:

[0018] Stitch the high-brightness weighted enhanced image and the low-brightness weighted enhanced image to obtain a stitched image as the total weighted enhanced image corresponding to the image to be enhanced.

[0019] In an embodiment of the present invention, enhancing the image using the total weight to enhance the image to be enhanced and obtain an enhanced image includes:

[0020] Performing image fusion on the total weight enhanced image and the image to be enhanced to obtain the enhanced image; or, performing the image fusion on the total weight enhanced image and the filtered image to obtain the enhanced image.

[0021] In an embodiment of the present invention, the implementation manner of the image fusion includes:

[0022] Adding the total weight enhanced image and the image to be enhanced pixel by pixel, or adding the total weight enhanced image and the filtered image pixel by pixel.

[0023] Correspondingly, the present invention provides an X-ray image enhancement system, which is characterized by including:

[0024] A filtering module, configured to perform edge-preserving filtering on the image to be enhanced to obtain a filtered image;

[0025] A difference module, configured to perform morphological processing on the filtered image to obtain a morphological image; taking the difference between the image to be enhanced and the morphological image to obtain a difference image;

[0026] A weight allocation module, configured to divide the difference image into a high-brightness image and a low-brightness image according to the brightness distribution; respectively allocating corresponding high-brightness enhancement weights to each pixel of the high-brightness image to obtain a high-brightness weight enhanced image; and respectively allocating corresponding low-brightness enhancement weights to each pixel of the low-brightness image to obtain a low-brightness weight enhanced image;

[0027] An enhancement module, configured to obtain a total weight enhanced image based on the high-brightness weight enhanced image and the low-brightness weight enhanced image; enhancing the image to be enhanced using the total weight enhanced image to obtain an enhanced image.

[0028] Correspondingly, the present invention provides a computer device, including:

[0029] A memory, configured to store a computer program;

[0030] A processor, configured to execute the computer program stored in the memory, so that the device executes the X-ray image enhancement method as described above.

[0031] Correspondingly, the present invention provides a computer-readable storage medium, where the computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the X-ray image enhancement method as described above is implemented.

[0032] As described above, an X-ray image enhancement method, system, device and medium provided by the present application have at least the following

[0033] Advantages:

[0034] By performing edge-preserving filtering on the image to be enhanced, a filtered image with noise information removed and object edge information retained is obtained; performing morphological processing on the filtered image to obtain a morphological image with patch noise removed and object morphological information retained; differentiating the image to be enhanced containing the original image information from the morphological image to obtain a differential image containing differential information other than the object morphological information; assigning corresponding enhancement weights to the bright and dark regions of the differential image to obtain a total weight enhanced image; using the total weight enhanced image to enhance the image to be enhanced to obtain an enhanced image. The method can perform targeted enhancement on the bright and dark regions in the X-ray image according to the brightness distribution, and is particularly suitable for enhancing X-ray images containing metal objects. While sharpening the edges of metal objects in the X-ray image, it avoids generating black and white edge artifacts at the edges of metal objects and greatly improves the enhancement effect of the X-ray image. Description of the Drawings

[0035] Figure 1 Shown is a schematic flowchart of an X-ray image enhancement method provided by the present application in an embodiment.

[0036] Figure 2 Shown is a schematic block diagram of an X-ray image enhancement system provided by the present application in an embodiment.

[0037] Figure 3 Shown is a schematic structural diagram of a computer device provided by the present application in an embodiment.

[0038] Description of the Reference Numerals

[0039] S1 to S4, steps; 200, X-ray image enhancement system; 201, filtering module; 202, differential module; 203, weight assignment module; 204, enhancement module; 300, device; 301, memory; 302, processor. Detailed Embodiments

[0040] The following uses specific specific examples to illustrate the embodiments of the present application. Those skilled in the art can easily understand other advantages and effects of the present application from the content disclosed in this specification. The present application can also be implemented or applied through other different specific embodiments, and various details in this specification can also be modified or changed based on different viewpoints and applications without departing from the spirit of the present application. It should be noted that, without conflict, the following embodiments and the features in the embodiments can be combined with each other.

[0041] It should be noted that the illustrations provided in the following embodiments only schematically illustrate the basic concept of the present application. Therefore, only the components related to the present application are shown in the drawings, rather than being drawn according to the number, shape, and size of the components in actual implementation. The types, quantities, and proportions of the components in actual implementation can be arbitrarily changed, and the component layout type may also be more complex.

[0042] For the convenience of understanding the technical solutions provided by the present application, the relevant terms in the present application are explained before specific embodiments as follows:

[0043] Unsharp masking: It is an image enhancement technology that enhances the edges and details of an image. After blurring the original image, it performs a difference operation with the original image, and then superimposes the operation result on the original image to highlight the high-frequency components of the image and enhance the edge effect.

[0044] Edge-preserving filter: When filtering an image, it can effectively retain the edge and detail information in the image, avoid edge blurring or detail loss caused by the filtering operation, and retain the edge information in the image while reducing image noise.

[0045] Opening operation: It uses a combined operation of erosion first and then dilation to remove small objects in the image and smooth the boundaries of larger objects.

[0046] Closing operation: It uses a combined operation of dilation first and then erosion to fill the small holes and cracks inside the objects in the image and smooth the boundaries of the objects at the same time.

[0047] Erosion: Dilation expands the range of brighter pixels.

[0048] Dilation: Erosion shrinks the range of brighter pixels.

[0049] The following will explain the embodiments of the present application in detail with reference to the accompanying drawings. Without conflict, the features in the following embodiments and implementation manners can be combined with each other.

[0050] The following embodiments of the present application provide an X-ray image enhancement method. By performing edge-preserving filtering on the image to be enhanced, a filtered image is obtained that removes noise information and retains object edge information; morphological processing is performed on the filtered image to obtain a morphological image that removes patch noise and retains object morphological information; the image to be enhanced containing the original image information is differentiated from the morphological image to obtain a differential image containing information other than the object morphological information; corresponding enhancement weights are assigned to the bright and dark regions of the differential image to obtain a total weight enhanced image; the image to be enhanced is enhanced using the total weight enhanced image to obtain an enhanced image. This method can perform targeted enhancement on the bright and dark regions in the X-ray image according to the brightness distribution, and is particularly suitable for enhancing X-ray images containing metal objects. While sharpening the edges of metal objects in the X-ray image, it avoids the generation of black and white edge artifacts at the edges of metal objects and greatly improves the enhancement effect of the X-ray image.

[0051] Please refer to Figure 1 , which shows a schematic flowchart of an X-ray image enhancement method provided by the present invention in an embodiment.

[0052] As Figure 1 shown, in this embodiment, the X-ray image enhancement method provided by the present invention includes the following steps:

[0053] Step S1: Perform edge-preserving filtering on the image to be enhanced to obtain the filtered image after the edge-preserving filtering;

[0054] Specifically, an edge-preserving filter is used to perform the edge-preserving filtering on the image to be enhanced to reduce the noise in the image to be enhanced and retain the edges and detail information of the image to be enhanced, thereby obtaining the filtered image after the edge-preserving filtering.

[0055] Optionally, the edge-preserving filter includes: a guided filter, a bilateral filter, a non-local means filter, a fast guided filter, a fast bilateral filter, and / or an edge-preserving mean filter, etc.; when the edge-preserving filter is a fast guided filter, a fast bilateral filter, or an edge-preserving mean filter, the speed of performing the edge-preserving filtering on the image to be enhanced can be increased, and the edge-preserving filtering can be quickly realized.

[0056] Step S2: Perform morphological processing on the filtered image to obtain the morphological image after the morphological processing; differentiate the image to be enhanced from the morphological image to obtain the differentiated differential image;

[0057] Specifically, according to the brightness relationship between the object and the background in the filtered image, a corresponding morphological processing algorithm is selected; using the corresponding morphological processing algorithm, the morphological processing is performed on the filtered image to retain the detailed shape of the object in the filtered image, and a morphological image after the morphological processing is obtained; the to-be-enhanced image is differentiated from the morphological image to obtain a differentiated image after differentiation, which is the image obtained by subtracting the morphological image from the to-be-enhanced image pixel by pixel.

[0058] Among them, the brightness relationship includes: the brightness of the object is greater than the brightness of the background, and the brightness of the object is less than the brightness of the background.

[0059] Optionally, the morphological processing algorithm includes: opening operation or closing operation.

[0060] Optionally, the selecting the corresponding morphological processing algorithm according to the brightness relationship between the object and the background in the filtered image includes: when the brightness of the object in the filtered image is greater than the brightness of the background, the opening operation is selected as the corresponding morphological algorithm; when the brightness of the object in the filtered image is less than the brightness of the background, the closing operation is selected as the corresponding morphological algorithm.

[0061] Exemplarily, when the brightness of the object in the filtered image is greater than the brightness of the background, the performing the morphological processing on the filtered image includes: performing an opening operation on the filtered image to retain the details of the object with higher brightness in the filtered image.

[0062] Exemplarily, when the brightness of the object in the filtered image is less than the brightness of the background, the performing the morphological processing on the filtered image includes: performing a closing operation on the filtered image to retain the details of the object with lower brightness in the filtered image.

[0063] Exemplarily, the implementation manner of the opening operation is as follows:

[0064] I m (x) = I denoise (x) o B open

[0065] In the above formula, I m (x) represents the pixel value of the morphological image at position x; I denoise (x) represents the pixel value of the filtered image at position x; B represents the structural element of the opening operation;

[0066] Exemplarily, the implementation manner of the closing operation is as follows:

[0067] I m (x) = I denoise (x) · B close

[0068] In the above formula, I m (x) represents the pixel value of the morphological image at position x; I denoise (x) represents the pixel value of the filtered image at position x; B close represents the structural element of the closing operation.

[0069] Exemplarily, the implementation manner of the difference is as follows:

[0070] I d (x) = I(x) - I m (x)

[0071] In the above formula, I d (x) represents the pixel value of the difference image at position x; I(x) represents the pixel value of the image to be enhanced at position x; I m (x) represents the pixel value of the morphological image at position x.

[0072] Step S3: Divide the difference image into a high-brightness image and a low-brightness image according to the brightness distribution; respectively assign corresponding high-brightness enhancement weights to each pixel of the high-brightness image to obtain a high-brightness weight-enhanced image; respectively assign corresponding low-brightness enhancement weights to each pixel of the low-brightness image to obtain a low-brightness weight-enhanced image.

[0073] Specifically, divide the difference image into a high-brightness image and a low-brightness image according to the brightness distribution; based on the pixel values of each pixel in the high-brightness image, according to a preset first pixel weight mapping formula, respectively assign corresponding high-brightness enhancement weights to each pixel of the high-brightness image to obtain the high-brightness weight-enhanced image; based on the pixel values of each pixel in the low-brightness image, according to a preset second pixel weight mapping formula, respectively assign corresponding low-brightness enhancement weights to each pixel of the low-brightness image to obtain the low-brightness weight-enhanced image.

[0074] Optionally, the obtaining methods of the high-brightness weight-enhanced image and the low-brightness weight-enhanced image include:

[0075] Based on the pixel values of each pixel of the high-brightness image, obtain the corresponding high-brightness enhancement weights of each pixel of the high-brightness image according to the first pixel weight mapping formula; respectively multiply each pixel of the high-brightness image by the corresponding high-brightness enhancement weight to obtain the high-brightness weight-enhanced image;

[0076] Based on the pixel values of the pixels in the low-luminance image, according to the second pixel weight mapping formula, obtain the low-luminance enhancement weights corresponding to the pixels in the low-luminance image; multiply each pixel in the low-luminance image by the corresponding low-luminance enhancement weight to obtain the low-luminance weight-enhanced image.

[0077] Optionally, the first pixel weight mapping formula is a non-linear function constructed in advance, which enables the first pixel weight to vary with the pixel values of the pixels in the high-luminance image; wherein, the larger the pixel value of the pixel in the high-luminance image, the smaller the value of the first pixel weight mapping formula.

[0078] Optionally, the value range of the first pixel weight mapping formula is between 0 and 1.

[0079] Optionally, the non-linear function includes: an exponential function.

[0080] Optionally, the second pixel weight mapping formula is a non-linear function constructed in advance, which enables the second pixel weight to vary with the pixel values of the pixels in the low-luminance image; wherein, the larger the pixel value of the pixel in the low-luminance image, the smaller the value of the second pixel weight mapping formula.

[0081] Optionally, the value range of the second pixel weight mapping formula is between 0 and 1.

[0082] Exemplarily, the first pixel weight mapping formula is as follows:

[0083]

[0084] In the above formula, ω 1,i represents the i-th high-luminance enhancement weight; represents the first parameter input quantity, which is used to control the overall enhancement degree corresponding to the high-luminance enhancement weight; a 1 represents the first adjustment parameter, which is used to control the steepness of the exponential function in the first pixel weight mapping formula; I d (x 1 , i ) represents the pixel value of the i-th pixel in the high-luminance image; b 1 represents the first offset term, which is used to adjust the center position of the exponential function in the first pixel weight mapping formula; K 1 represents the first scaling factor, which is a constant and is used to scale the high-luminance enhancement weight.

[0085] Exemplarily, the second pixel weight mapping formula is as follows:

[0086]

[0087] In the above formula, ω 2,i represents the i-th low-brightness enhancement weight; represents the second parameter input quantity, which is used to control the overall enhancement degree corresponding to the low-brightness enhancement weight; a 2 represents the second adjustment parameter, which is used to control the steepness of the exponential function in the second pixel weight mapping formula; I d (x 2,i ) represents the pixel value of the i-th pixel in the low-brightness image; b 2 represents the second bias term, which is used to adjust the central position of the exponential function in the second pixel weight mapping formula; K 2 represents the second scaling factor, which is a constant and is used to scale the low-brightness enhancement weight.

[0088] It should be noted that using the S-shaped function to calculate the enhancement weight of each pixel enables different degrees of enhancement in the bright area and the dark area. This method can be used for local contrast enhancement of the image, making the details of the image more prominent.

[0089] Step S4: Based on the high-brightness weight-enhanced image and the low-brightness weight-enhanced image, obtain the total weight-enhanced image corresponding to the image to be enhanced; use the total weight-enhanced image to enhance the image to be enhanced to obtain the enhanced image.

[0090] Specifically, splice the high-brightness weight-enhanced image and the low-brightness weight-enhanced image to obtain the spliced image as the total weight-enhanced image corresponding to the image to be enhanced; use the total weight-enhanced image to enhance the image to be enhanced to obtain the enhanced image.

[0091] Optionally, the using the total weight-enhanced image to enhance the image to be enhanced includes:

[0092] Performing image fusion on the total weight-enhanced image and the image to be enhanced to obtain the enhanced image; or,

[0093] Performing the image fusion on the total weight-enhanced image and the filtered image to obtain the enhanced image.

[0094] Optionally, the implementation manner of the image fusion includes: adding the total weight-enhanced image and the image to be enhanced pixel by pixel, or adding the total weight-enhanced image and the filtered image pixel by pixel.

[0095] An X-ray image enhancement method provided in the above embodiments includes performing edge-preserving filtering on an image to be enhanced to obtain a filtered image that removes noise information and retains object edge information; performing morphological processing on the filtered image to obtain a morphological image that removes patch noise and retains object morphological information; differentiating the image to be enhanced containing the original image information from the morphological image to obtain a differential image containing information other than the object morphological information; assigning corresponding enhancement weights to the bright and dark regions of the differential image to obtain a total weight enhanced image; and using the total weight enhanced image to enhance the image to be enhanced to obtain an enhanced image. The method can perform targeted enhancement on the bright and dark regions in the X-ray image according to the brightness distribution, is particularly suitable for enhancing X-ray images containing metal objects, and can avoid generating black and white edge artifacts at the edges of metal objects and the like while sharpening the edges of metal objects in the X-ray image, greatly improving the enhancement effect of the X-ray image.

[0096] As Figure 2 shown, in this embodiment, the present invention provides an X-ray image enhancement system, including:

[0097] A filtering module 201 for performing edge-preserving filtering on an image to be enhanced to obtain a filtered image;

[0098] A differential module 202 for performing morphological processing on the filtered image to obtain a morphological image; differentiating the image to be enhanced from the morphological image to obtain a differential image;

[0099] A weight assignment module 203 for dividing the differential image into a high-brightness image and a low-brightness image according to the brightness distribution; assigning corresponding high-brightness enhancement weights to each pixel of the high-brightness image to obtain a high-brightness weight enhanced image; assigning corresponding low-brightness enhancement weights to each pixel of the low-brightness image to obtain a low-brightness weight enhanced image;

[0100] An enhancement module 204 for obtaining a total weight enhanced image based on the high-brightness weight enhanced image and the low-brightness weight enhanced image; using the total weight enhanced image to enhance the image to be enhanced to obtain an enhanced image.

[0101] Please refer to Figure 3 , which shows a schematic structural diagram of a computer device provided by the present invention in an embodiment;

[0102] As Figure 3As shown, in this embodiment, the device 300 provided by the present invention includes a memory 301 and a processor 302. The memory 301 is used to store computer programs; the processor 302 is used to execute the computer programs stored in the memory 301, so that the device 300 executes the X-ray image enhancement method of any of the above embodiments of the present application. Since the specific implementation process of the steps of the X-ray image enhancement method has been described in detail in the above embodiments, it will not be repeated here.

[0103] The memory 301 includes various media that can store program codes, such as ROM (Read Only Memory image), RAM (Random Access Memory), magnetic disks, USB flash drives, memory cards, or optical discs.

[0104] The processor 302 is connected to the memory 301 and is used to execute the computer programs stored in the memory 301, so that the device 300 executes the above X-ray image enhancement method.

[0105] The embodiment of the present application also provides a computer-readable storage medium. Those of ordinary skill in the art can understand that all or part of the steps in the method of the above embodiments can be completed by instructing a processor through a program. The program can be stored in a computer-readable storage medium. The storage medium is a non-transitory medium, such as random access memory, read-only memory, flash memory, hard disk, solid-state drive, magnetic tape, floppy disk, optical disc, and any combination thereof. The above storage medium can be any available medium that can be accessed by a computer or a data storage device such as a server or a data center that integrates one or more available media. The available medium can be a magnetic medium (such as a floppy disk, a hard disk, or a magnetic tape), an optical medium (such as a digital video disc (DVD)), or a semiconductor medium (such as a solid-state disk (SSD)).

[0106] An embodiment of the present application may further provide a computer program product, which includes one or more computer instructions. When the computer instructions are loaded and executed on a computing device, the processes or functions according to the embodiments of the present application are generated in whole or in part. The computer instructions may be stored in a computer-readable storage medium or transmitted from one computer-readable storage medium to another computer-readable storage medium. For example, the computer instructions may be transmitted from a website, a computer, or a data center to another website, a computer, or a data center by wire (such as coaxial cable, optical fiber, digital subscriber line (DSL)) or wirelessly (such as infrared, wireless, microwave, etc.).

[0107] When the computer program product is executed by a computer, the computer executes the method described in the foregoing method embodiment. The computer program product may be a software installation package. In the case where the foregoing method is required, the computer program product may be downloaded and executed on the computer.

[0108] The descriptions of the processes or structures corresponding to the above respective drawings have their own focuses. For parts not detailed in a certain process or structure, reference may be made to the relevant descriptions of other processes or structures.

[0109] The above embodiments are only illustrative of the principles and effects of the present application, and are not used to limit the present application. Any person familiar with this technology can modify or change the above embodiments without departing from the spirit and scope of the present application. Therefore, all equivalent modifications or changes made by those with ordinary knowledge in the technical field without departing from the spirit and technical ideas disclosed in the present application should still be covered by the claims of the present application.

Claims

1. An X-ray image enhancement method, characterized in that, it includes: Performing edge-preserving filtering on the image to be enhanced to obtain a filtered image; Performing morphological processing on the filtered image to obtain a morphological image; Differencing the image to be enhanced and the morphological image to obtain a difference image; Dividing the difference image into a high-brightness image and a low-brightness image according to the brightness distribution; Assigning corresponding high-brightness enhancement weights to each pixel of the high-brightness image to obtain a high-brightness weight-enhanced image; And, assigning corresponding low-brightness enhancement weights to each pixel of the low-brightness image to obtain a low-brightness weight-enhanced image; Based on the high-brightness weight-enhanced image and the low-brightness weight-enhanced image, obtaining a total weight-enhanced image; Using the total weight-enhanced image to enhance the image to be enhanced to obtain an enhanced image.

2. The method according to claim 1, characterized in that, The way to obtain the morphological image includes: Selecting a corresponding morphological processing algorithm according to the brightness relationship between the object and the background in the filtered image; using the corresponding morphological processing algorithm to perform the morphological processing on the filtered image to obtain the morphological image after the morphological processing.

3. The method according to claim 1, characterized in that, The way to obtain the high-brightness weight-enhanced image and the low-brightness weight-enhanced image includes: Based on the pixel values of each pixel of the high-brightness image, obtaining the corresponding high-brightness enhancement weights of each pixel of the high-brightness image according to a preset first pixel weight mapping formula; multiplying each pixel of the high-brightness image by the corresponding high-brightness enhancement weight to obtain the high-brightness weight-enhanced image; Based on the pixel values of each pixel of the low-brightness image, obtaining the corresponding low-brightness enhancement weights of each pixel of the low-brightness image according to a preset second pixel weight mapping formula; multiplying each pixel of the low-brightness image by the corresponding low-brightness enhancement weight to obtain the low-brightness weight-enhanced image.

4. The method according to claim 3, characterized in that, The first pixel weight mapping formula is a non-linear function in which the first pixel weight changes with the pixel values of each pixel of the high-brightness image; the second pixel weight mapping formula is a non-linear function in which the second pixel weight changes with the pixel values of each pixel of the low-brightness image.

5. The method according to claim 1, characterized in that, The way to obtain the total weight-enhanced image includes: Stitching the high-brightness weight-enhanced image and the low-brightness weight-enhanced image to obtain a stitched image as the total weight-enhanced image corresponding to the image to be enhanced.

6. The method according to claim 1, characterized in that, The step of using the total weight-enhanced image to enhance the image to be enhanced to obtain an enhanced image includes: Performing image fusion on the total weight-enhanced image and the image to be enhanced to obtain the enhanced image; or, performing the image fusion on the total weight-enhanced image and the filtered image to obtain the enhanced image.

7. The method according to claim 6, It is characterized in that the implementation manner of the image fusion includes: performing pixel-by-pixel addition of the total weight enhanced image and the image to be enhanced, or performing pixel-by-pixel addition of the total weight enhanced image and the filtered image.

8. An X-ray image enhancement system It is characterized in that it includes: a filtering module, configured to perform edge-preserving filtering on the image to be enhanced to obtain a filtered image; a difference module, configured to perform morphological processing on the filtered image to obtain a morphological image; performing difference between the image to be enhanced and the morphological image to obtain a difference image; a weight allocation module, configured to divide the difference image into a high-brightness image and a low-brightness image according to the brightness distribution; allocating corresponding high-brightness enhancement weights to each pixel of the high-brightness image to obtain a high-brightness weight enhanced image; and allocating corresponding low-brightness enhancement weights to each pixel of the low-brightness image to obtain a low-brightness weight enhanced image; an enhancement module, configured to obtain a total weight enhanced image based on the high-brightness weight enhanced image and the low-brightness weight enhanced image; using the total weight enhanced image to enhance the image to be enhanced to obtain an enhanced image.

9. A computer device It is characterized in that the device includes: a memory, configured to store a computer program; a processor, configured to execute the computer program stored in the memory, so that the device executes the X-ray image enhancement method according to any one of claims 1 to 7.

10. A computer-readable storage medium, on which a computer program is stored It is characterized in that when the program is executed, it implements the X-ray image enhancement method according to any one of claims 1 to 7.