Crystal grain image contrast enhancement method and related product
By acquiring images of the current die and its adjacent dies in the wafer, and using gradient values to divide and generate guide maps, the problem of insufficient image quality in wafer inspection is solved, achieving a significant improvement in contrast and clear visibility of defects.
Patent Information
- Application Number
- CN202512037849.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-12-30
- Publication Date
- 2026-04-10
AI Technical Summary
In existing wafer inspection methods, image quality issues can lead to the masking or misjudgment of subtle defects, making it difficult to meet the requirements of high-fidelity and low-artifact inspection.
By acquiring images of the current grain and its neighboring grains, edge segmentation is performed using gradient values to generate a guide image. The incident image is then solved by combining the guide image and the current grain image to enhance contrast.
It effectively suppresses the low contrast problem caused by uneven lighting and material reflection, significantly improves the defect detection rate and detection robustness, and ensures that weak defects are clearly distinguishable in the enhanced image.
Smart Images

Figure CN121837098A_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present application relates to the technical field of semiconductor technology, in particular to a die image contrast enhancement method and related products. BACKGROUND
[0002] As the core basis of semiconductor manufacturing, the quality of wafers directly determines the performance, yield and long-term reliability of chips. In the manufacturing process, if there are micron or even nanometer level defects such as particle contamination, scratches, pattern loss or bridging on the surface of the wafer, it is easy to cause chip functional failure, and then affect the stability and quality of the terminal electronic product. Therefore, wafer defect detection has become an indispensable key link in large-scale production.
[0003] However, the current mainstream wafer detection method relies on automatic optical inspection (AOI) equipment to perform high-speed scanning on the wafer surface, and realizes the identification and classification of defects through image analysis. In this process, the quality of the obtained image directly determines the accuracy and robustness of subsequent defect detection. In the actual imaging process, affected by factors such as light source intensity, illumination wavelength, objective numerical aperture, and local material reflection characteristics of the wafer (such as the difference between metal layers and dielectric layers), some areas may have problems such as image blur, insufficient contrast, low signal-to-noise ratio, or local overexposure, which may cause subtle defects to be hidden or misjudged. SUMMARY
[0004] Based on the above problems, the present application provides a die image contrast enhancement method and related products, which aims to enhance the contrast of the die image.
[0005] The embodiments of the present application disclose the following technical solutions:
[0006] The first aspect of the present application provides a die image contrast enhancement method, which comprises:
[0007] obtaining an image of a current die and images of a plurality of adjacent dies in a wafer to be detected; the wafer to be detected comprises a plurality of dies; the image of the current die is an image of a preset part of the current die; the image of the adjacent die is an image of the preset part of the adjacent die; the plurality of dies comprises the current die and the plurality of adjacent dies; the plurality of adjacent dies are dies adjacent to the current die;
[0008] performing edge division on the images of the plurality of adjacent dies based on gradient values of the image of the current die to obtain a plurality of divided images of the adjacent dies;
[0009] obtaining a guide image based on the plurality of divided images of the adjacent dies;
[0010] obtaining an incident image corresponding to the image of the current die based on the guide image and the image of the current die.
[0011] Based on the incident image and the image of the current die, an image of the current die after contrast enhancement is obtained.
[0012] Optionally, the image of the current die and the images of the plurality of adjacent dies in the wafer to be detected are obtained, specifically comprising:
[0013] The image of the current die and the images of the plurality of adjacent dies in the wafer to be detected are obtained using an integral time delay camera.
[0014] Optionally, before the plurality of divided images of adjacent dies are obtained based on the gradient value of the image of the current die, the method further comprises:
[0015] The gradient value of the image of the current die is calculated by using a gradient algorithm; the gradient algorithm comprises a Canny edge detection algorithm, a Sobel edge detection algorithm or a variance method.
[0016] Optionally, the guide image is obtained based on the plurality of divided images of adjacent dies, specifically comprising:
[0017] A database is obtained based on the plurality of divided images of adjacent dies according to pixel coordinates; the database comprises a plurality of edge pixel data sets and a plurality of non-edge pixel data sets; the plurality of divided images of adjacent dies comprise the same number of edge pixels and the same number of non-edge pixels; the number of edge pixel data sets in the database is consistent with the number of edge pixels in the divided images of adjacent dies; the number of non-edge pixel data sets in the database is consistent with the number of non-edge pixels in the divided images of adjacent dies; the number of edge pixel values in the edge pixel data set and the number of non-edge pixel values in the non-edge pixel data set are consistent with the number of divided images of adjacent dies; the edge pixel data set comprises a plurality of edge pixel values and pixel coordinates of each edge pixel; the non-edge pixel data set comprises a plurality of non-edge pixel values and pixel coordinates of each non-edge pixel.
[0018] Each edge pixel value in each edge pixel data set is sorted in descending order to obtain a plurality of sorted edge pixel data sets.
[0019] Each non-edge pixel value in each non-edge pixel data set is sorted in descending order to obtain a plurality of sorted non-edge pixel data sets.
[0020] determine a pixel value corresponding to each pixel coordinate in the guide map based on the plurality of sorted edge pixel data sets and the plurality of sorted non-edge pixel data sets, to obtain a guide map; the number of pixel values in the guide map is consistent with the number of pixel values in the image of the adjacent die after the division.
[0021] Optionally, the determination of the pixel value corresponding to each pixel coordinate in the guide map based on the plurality of sorted edge pixel data sets and the plurality of sorted non-edge pixel data sets to obtain the guide map specifically includes:
[0022] determining the median of each sorted non-edge pixel data set as the pixel value of the corresponding pixel coordinate of the guide map;
[0023] determining a preset mean value of each sorted edge pixel data set as the pixel value of the corresponding pixel coordinate of the guide map, to obtain the guide map.
[0024] Optionally, the obtaining of the incident image corresponding to the image of the current die based on the guide map and the image of the current die specifically includes:
[0025] inputting the guide map and the image of the current die into a guide filter to obtain the incident image corresponding to the image of the current die output by the guide filter.
[0026] Optionally, the guide filter includes:
[0027] = ;
[0028] wherein, represents the incident image corresponding to the image of the current die; represents the weight of the weighted average of the guide map; represents the image of the current die.
[0029] Optionally, the obtaining of the contrast-enhanced image of the current die based on the incident image and the image of the current die specifically includes:
[0030] inputting the incident image and the image of the current die into an enhancement model to obtain the processed image of the current die output by the enhancement model;
[0031] quantizing the processed image of the current die to obtain the contrast-enhanced image of the current die;
[0032] The enhancement model includes:
[0033] Log[R(x, y)] = Log[I(x, y)] - Log[Q(x, y)];
[0034] Where Log[R(x,y)] represents the processed image of the current grain; Log[I(x,y)] represents the logarithmic value of the current grain image; and Log[Q(x,y)] represents the logarithmic value of the incident image.
[0035] A second aspect of this application provides a grain image contrast enhancement device comprising:
[0036] An acquisition module is used to acquire an image of the current die and images of multiple adjacent dies in a wafer to be inspected; the wafer to be inspected includes multiple dies; the image of the current die is an image of a preset location of the current die; the images of adjacent dies are images of the preset locations of the adjacent dies; the multiple dies include the current die and the multiple adjacent dies; the multiple adjacent dies are all dies adjacent to the current die;
[0037] The segmentation module is used to perform edge segmentation on the images of the multiple adjacent grains based on the gradient value of the current grain's image, thereby obtaining multiple segmented images of adjacent grains;
[0038] The guide map determination module is used to obtain a guide map based on the images of the multiple partitioned adjacent grains;
[0039] An incident image determination module is used to obtain the incident image corresponding to the image of the current grain based on the guide image and the image of the current grain;
[0040] An enhancement module is used to obtain a contrast-enhanced image of the current grain based on the incident image and the image of the current grain.
[0041] A third aspect of this application provides a computer device, including: a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the computer program to implement the grain image contrast enhancement method provided in the first aspect.
[0042] Compared with the prior art, this application has the following beneficial effects:
[0043] This application includes acquiring an image of a current die and images of multiple adjacent dies in a wafer to be inspected; the wafer to be inspected includes multiple dies; the image of the current die is an image of a preset location of the current die; the images of adjacent dies are images of the preset locations of the adjacent dies; the multiple dies include the current die and the multiple adjacent dies; the multiple adjacent dies are all dies adjacent to the current die; the images of the multiple adjacent dies are edge-divided based on the gradient value of the current die image to obtain multiple divided images of adjacent dies; a guide image is obtained based on the multiple divided images of adjacent dies; an incident image corresponding to the current die image is obtained based on the guide image and the current die image; and a contrast-enhanced image of the current die is obtained based on the incident image and the current die image.
[0044] This application acquires images of the current die and its multiple neighboring dies, fully utilizing the prior knowledge of the periodically arranged structure on the wafer. Subsequently, based on the gradient distribution of the current die image, adaptive edge segmentation is performed on the adjacent die images, effectively separating local regions with similar textures and structural features. On this basis, multiple segmented adjacent die images are fused to generate a high-quality guide map. The guide map not only preserves the global consistency of the wafer's periodic pattern but also highlights local structural boundaries, providing a reliable prior for subsequent illumination estimation. The guide map and the current die image are jointly used to solve for the incident image corresponding to the incident light component, accurately separating the reflection component in the image. Based on the estimated incident image, the original image undergoes dynamic range adjustment or reflection component enhancement, resulting in an output image with significantly improved contrast.
[0045] This application effectively suppresses the low contrast problem caused by uneven illumination, material reflection, or imaging limitations, making subtle defects (such as micro-scratches and particle contamination) more clearly distinguishable in the enhanced image. Compared with traditional single-image enhancement methods, this application avoids over-smoothing or artifact generation by guiding across grain structures, significantly improving the defect detection rate and detection robustness while maintaining image authenticity. Attached Figure Description
[0046] To more clearly illustrate the technical solutions in the embodiments of this application or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of this application. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0047] Figure 1 A flowchart illustrating a method for enhancing grain image contrast provided in this application embodiment;
[0048] Figure 2A schematic diagram illustrating a method for enhancing grain image contrast provided in an embodiment of this application;
[0049] Figure 3 This is a structural diagram of a grain image contrast enhancement device provided in an embodiment of this application. Detailed Implementation
[0050] As described earlier, current contrast enhancement methods have significant limitations in grain image processing. For example, histogram equalization tends to globally stretch the grayscale distribution, easily submerging tiny defect signals in the over-enhanced background texture; local Laplacian enhancement, while improving high-frequency details, indiscriminately amplifies noise and real defects, often leading to a decrease in the overall signal-to-noise ratio; and Retinex-type methods, when processing images of wafers with dense, high-contrast periodic patterns, are prone to producing bright or dark halos at the edges during "illumination" component estimation. These artifacts are highly similar to real defects (such as bridging, erosion, and micro-scratches) in shape, scale, and contrast, easily causing a large number of false alarms. Therefore, existing general-purpose image enhancement algorithms struggle to suppress structural interference while preserving real defects, failing to meet the stringent requirements of high-fidelity, low-artifact image enhancement in automated wafer optical inspection.
[0051] In view of the above problems, this application provides a method for generating a contrast-enhanced image of a die and related products. The method includes: acquiring an image of a current die and images of multiple adjacent dies in a wafer to be inspected; the wafer to be inspected includes multiple dies; the image of the current die is an image of a preset part of the current die; the images of the adjacent dies are images of the preset parts of the adjacent dies; the multiple dies include the current die and the multiple adjacent dies; the multiple adjacent dies are all dies adjacent to the current die; performing edge segmentation on the images of the multiple adjacent dies based on the gradient value of the image of the current die to obtain multiple segmented images of adjacent dies; obtaining a guide image based on the multiple segmented images of adjacent dies; obtaining an incident image corresponding to the image of the current die based on the guide image and the image of the current die; and obtaining a contrast-enhanced image of the current die based on the incident image and the image of the current die.
[0052] This application acquires images of the target grain and its neighboring grains, and utilizes gradient distribution to achieve adaptive edge segmentation, thereby effectively separating regions with similar textures. Multiple adjacent images are fused to construct a high-quality guide map, providing a reliable basis for illumination estimation. The guide map and the current grain image are jointly used to solve for the incident image corresponding to the incident light component, accurately separating the reflection component, and dynamically adjusting or enhancing the original image, significantly improving contrast. In particular, it excels in suppressing low contrast caused by uneven illumination, making subtle defects such as micro-scratches and particle contamination more clearly visible, thus enhancing the contrast of the grain image.
[0053] To enable those skilled in the art to better understand the present application, the technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present application, and not all embodiments. Based on the embodiments in the present application, all other embodiments obtained by those of ordinary skill in the art without creative effort are within the scope of protection of the present application.
[0054] Given that the wafer surface has a large number of repeating dies (die arrays) and that the image content within each die is consistent, this characteristic can be used to capture kernel images of the same area in multiple dies. These similar kernel images can then be combined to create a defect-free reference kernel image. However, ordinary images, lacking this repeatability and consistent structure, cannot be generated using similar methods.
[0055] Therefore, this application primarily proposes a method for enhancing the contrast of die images in the wafer manufacturing field. This method is particularly suitable for processing images on the wafer surface. Figure 1 A flowchart of a method for enhancing grain image contrast provided in this application embodiment is now combined with... Figure 1 Detailed description of the specific steps of the grain image contrast enhancement method:
[0056] S101: Acquire the image of the current grain in the wafer to be inspected, as well as images of multiple adjacent grains.
[0057] As described above, a wafer is typically composed of multiple repeating dies. These dies are independent units cut from a whole wafer. Each die, in a defect-free state, corresponds to a fully functional electronic device, with highly consistent internal circuit patterns and essentially identical image content. The multiple dies include the current die and the multiple adjacent dies. To ensure that the guide map constructed subsequently based on multi-die information has structural consistency and spatial relevance, the selected adjacent dies are all dies directly adjacent to the current die in physical location (i.e., the multiple adjacent dies are all dies adjacent to the current die), and the image of the current die is an image of a preset location of the current die; the images of adjacent dies are images of the preset locations of the adjacent dies. However, this application does not limit the preset location. For example, the preset location may be the upper left corner or the first location of the die. It can be set according to the actual situation, as long as the image of the current die and the images of the adjacent dies are images of the same location. This application does not limit the specific number of adjacent grains, and can be flexibly adjusted according to the imaging field of view, grain size and algorithm requirements. For example, images of 8 to 11 adjacent grains can be acquired, which takes into account both computational efficiency and enhancement effect while ensuring the validity of periodic prior.
[0058] S102: Based on the gradient value of the current grain image, perform edge segmentation on the images of the multiple adjacent grains to obtain multiple segmented images of adjacent grains.
[0059] Using the gradient information of the current grain image as a reference, precise edge segmentation is performed on the images of adjacent grains. The aim is to identify and separate local regions with similar texture and structural features, ensuring that each segmented image portion of the adjacent grain is as close as possible to the relevant region of the current grain in terms of geometric structure and pattern details.
[0060] Specifically, by analyzing the gradient direction and intensity of the current grain, key boundaries and texture change points within it can be located. This information is then applied to images of adjacent grains for edge detection. The main purpose is to create a composite image set composed of multiple adjacent grains that highly match the current grain. Each sub-image undergoes meticulous edge segmentation so that subsequent steps can accurately extract periodic structural features and generate high-quality guide images. This not only improves the sensitivity to subtle structural differences but also enhances the algorithm's adaptability to different imaging conditions and wafer surface characteristics.
[0061] S103: A guide map is obtained based on the images of the multiple partitioned adjacent grains.
[0062] The method of determining the guide map based on multiple partitioned adjacent grain images is not limited to a specific technique or algorithm; the most suitable approach can be selected according to the specific application scenario and requirements. For example, for each partitioned adjacent grain image, a weight can be assigned to each pixel value based on its similarity or distance to the target region (i.e., the currently processed grain). Then, the pixel value at the corresponding position in the guide map is determined by calculating the weighted average of these weighted pixel values. This method can effectively reduce the influence of noise and enhance image features.
[0063] Alternatively, advanced machine learning techniques such as deep learning can be used to train a model to automatically identify and extract key features from adjacent grain images after partitioning, and generate high-quality guide maps accordingly. This method requires a large amount of training data and certain computational resources, but it can provide very accurate results.
[0064] Alternatively, multi-scale analysis techniques can be used to process the images of adjacent grains after segmentation, capturing more detailed information at different resolutions. Combining this multi-scale information allows for the construction of more refined and accurate guide maps. In addition to using information from the grain images themselves, other types of data, such as chemical composition analysis results and physical property measurements, can be integrated as auxiliary information to jointly determine the pixel values in the guide map. This helps improve the quality and reliability of the final generated image.
[0065] In some application scenarios, users can manually adjust certain parameters or directly intervene in key steps of the guide map generation process to better meet personalized needs. For example, users can specify which areas should be given special attention or special treatment through interface tools. By combining the above methods, not only can the accuracy and quality of the guide map be improved, but the flexibility and adaptability of the entire process can also be increased, making the method applicable to more diverse practical problems and application scenarios.
[0066] S104: Based on the guide image and the image of the current grain, obtain the incident image corresponding to the image of the current grain.
[0067] This application maintains openness and flexibility in its methods for determining the incident image, without limiting any specific approach. For example, this goal can be achieved by building a model that is trained on a large training dataset to deeply understand and learn the complex mapping relationship between the guide image, the current grain image, and its corresponding incident image. Once the model is trained, it can be applied in practice to accurately predict the corresponding incident image by inputting the current grain image.
[0068] Alternatively, the guide map can be used to filter the image of the current grain, thereby purifying or transforming the original image to obtain the desired incident image. This method relies on the information provided by the guide map to adjust and optimize the current grain image, aiming to improve image quality and enhance analytical accuracy.
[0069] S105: Based on the incident image and the image of the current grain, obtain a contrast-enhanced image of the current grain.
[0070] This application does not limit the specific method for determining the contrast-enhanced current grain image. For example, a trained model can be used to generate the contrast-enhanced current grain image, which can not only improve the visibility of details of interest in the image, but also maintain the natural appearance of the image, thereby supporting more accurate analysis and interpretation.
[0071] The above describes the main technical solution of this application. Further implementations of the main technical solution are now introduced. Details are as follows:
[0072] Regarding S101, which involves acquiring an image of the current die and images of multiple adjacent dies in the wafer to be inspected, this application provides an optional embodiment:
[0073] An integral time-delay camera is used to acquire images of the current grain and multiple adjacent grains in the wafer to be inspected.
[0074] Using an integral time-delay camera to acquire images of the same location in the current die and its adjacent dies within a wafer under inspection primarily utilizes the camera's unique operating mode of time-division integration and multi-frame synthesis. This not only preserves the temporal information of dynamic scenes but also balances imaging resolution and brightness. This characteristic makes integral time-delay cameras particularly suitable for capturing high-speed moving targets, ensuring clear and detailed images. In this way, the ability to observe and analyze rapidly changing or moving objects can be effectively improved.
[0075] Regarding the method for determining the gradient value of the current grain image, this application provides an optional embodiment:
[0076] The gradient value of the current grain image is calculated using a gradient algorithm.
[0077] This application calculates the gradient value of the current grain image, primarily to distinguish edge pixels from non-edge pixels. The specific gradient calculation method is not limited here; various mature edge detection or gradient estimation algorithms can be used. For example, these include, but are not limited to, the Canny edge detection algorithm, the Sobel edge detection algorithm, and variance methods based on local gray-level variance. These methods can effectively characterize the gradient properties of pixels in an image, thereby supporting accurate subsequent segmentation of edge and non-edge regions.
[0078] Regarding the guide map obtained by S103 based on the images of the multiple partitioned adjacent grains, this application provides an optional embodiment:
[0079] A database is obtained based on the images of the multiple partitioned adjacent grains according to pixel coordinates.
[0080] This application does not limit the database, but the database includes multiple edge pixel datasets and multiple non-edge pixel datasets, which are used to store edge and non-edge pixel information extracted from adjacent grain images, respectively.
[0081] Specifically, the images of the multiple partitioned adjacent grains include the same number of edge pixels and the same number of non-edge pixels to ensure data consistency and comparability; the number of edge pixel datasets in the database is consistent with the number of edge pixels in the images of the partitioned adjacent grains; the number of non-edge pixel datasets in the database is consistent with the number of non-edge pixels in the images of the partitioned adjacent grains; the number of edge pixel values in the edge pixel dataset and the number of non-edge pixel values in the non-edge pixel dataset are both consistent with the number of images of the partitioned adjacent grains, thereby ensuring that each image has a corresponding pixel-level mapping relationship in the database; the edge pixel dataset includes multiple edge pixel values and pixel coordinates (such as (x, y) coordinates) of each edge pixel, used to accurately record the position and grayscale (or color) information of the pixel in the original image; the non-edge pixel dataset includes multiple non-edge pixel values and pixel coordinates of each non-edge pixel.
[0082] Through the above structured design, the database can not only efficiently organize and retrieve large amounts of pixel-level feature data, but also provide a solid data foundation for subsequent tasks such as statistical analysis, pattern recognition, or model training.
[0083] The edge pixel values in each edge pixel dataset are sorted in descending order to obtain multiple sorted edge pixel datasets.
[0084] Sort the non-edge pixel values in each non-edge pixel dataset in descending order to obtain multiple sorted non-edge pixel datasets.
[0085] Based on the sorted edge pixel datasets and the sorted non-edge pixel datasets, the pixel value corresponding to each pixel coordinate in the guide map is determined, and the guide map is obtained.
[0086] To ensure the effectiveness of the guide map, the number of pixel values in the guide map is consistent with the number of pixel values in the image of the adjacent grains after division.
[0087] However, this application does not limit the method for determining the guide map based on the dataset. For example, the median of each sorted non-edge pixel dataset is determined as the pixel value of the corresponding pixel coordinate of the guide map; the preset mean of each sorted edge pixel dataset (such as the mean of the first n / 2 pixel values (n represents the number of pixels in the edge pixel dataset), arithmetic mean, weighted mean or other statistical mean) is determined as the pixel value of the corresponding pixel coordinate of the guide map to obtain the guide map.
[0088] By utilizing the robust median of non-edge regions and the representative mean of edge regions respectively, structural and texture information from multiple adjacent grain images can be effectively fused to generate a high-quality guide map with local consistency.
[0089] This application also provides a specific embodiment:
[0090] Assuming the pixel value in the i-th row and j-th column of the guide image can be represented as Vg(i,j), similarly, the pixel values with the same pixel coordinates in the 1st to nth kernel images (i.e., the images of adjacent grains after partitioning) can be represented as V1(i,j), V2(i,j)...Vn(i,j), and Vg(i,j). When Vg(i,j) is a non-edge pixel, the value of Vg(i,j) is the median value after sorting V1(i,j)...Vn(i,j). When Vg(i,j) is an edge pixel, the value of Vg(i,j) is the average of the first n / 2 values after sorting V1(i,j)...Vn(i,j). This can be expressed by the following formula:
[0091] ;
[0092] Where Vg(i,j) represents the pixel value at pixel coordinates i and j in the guide graph; S(V1(i,j)...Vn(i,j)) represents sorting the values from V1(i,j) to Vn(i,j) in descending order; M(V1(i,j)...Vn(i,j)) represents taking the median of the sorted data, and if the number of data is even, taking the average of the two middle numbers; MH(V1(i,j)...Vn(i,j)) represents taking the average of the first n / 2 values of the sorted data.
[0093] Regarding S104 obtaining the incident image corresponding to the image of the current die based on the guide map and the image of the current die, this application provides an optional embodiment:
[0094] The guiding image and the image of the current die are input into the guiding filter to obtain the incident image corresponding to the image of the current die output by the guiding filter.
[0095] This application does not limit the type of guiding filter; for example, guiding filters include:
[0096] = ;
[0097] in, This represents the incident image corresponding to the image of the current grain; The weights represent the weighted average of the guide graph; Image representing the current grain; .
[0098] Considering that there is a linear relationship between the guide map and the current die image in the guide filter, the above formula can be expressed as:
[0099] ,∀i∈ ;
[0100] in, and For the linear coefficients in the window, minimize With input image The coefficient of determination for the differences in the table, and the objective function are:
[0101] E ( ;
[0102] Among them, regular terms To prevent overfitting, the least squares method can be used to calculate... and Then you can use the formula Calculate the incident image corresponding to the current grain's image.
[0103] This application not only effectively reduces noise but also preserves the detailed features of image edges, thereby improving the quality of the final incident image. Furthermore, the flexibility of this application allows it to adapt to different application scenarios; specific requirements can be met simply by adjusting the relevant parameters of the guiding filter. Therefore, the method of this application has significant effects in enhancing image quality and preserving important details.
[0104] Regarding S105, which obtains a contrast-enhanced image of the current grain based on the incident image and the image of the current grain, this application provides an optional embodiment:
[0105] The incident image and the image of the current grain are input into the enhancement model to obtain the processed image of the current grain output by the enhancement model.
[0106] This application does not limit the enhancement model, but to ensure the clarity of the technical solution, this application provides a method for constructing the enhancement model:
[0107] Considering that an image can be viewed as composed of an incident image and a reflected image, incident light shines on a reflecting object, and through reflection by the reflecting object, the reflected light enters the human eye. The final image can be represented as follows:
[0108] I(x,y) = Q(x,y) R(x,y);
[0109] Where I(x,y) represents the image signal observed or received by the camera, i.e., the current pixel; Q(x,y) represents the ambient light component, i.e., the incident image; and R(x,y) represents the reflection component of the target object carrying image detail information, i.e., the reflected image. Q(x,y) represents the incident light from the environment, determining the overall brightness distribution of the image, such as dark shadows and bright areas, which is considered "light interference." R(x,y) represents the light reflected by the object itself, determining the object's color, texture, and details; it is the "essential information" of the image. The algorithm "separates" Q(x,y) from I(x,y), and then divides I(x,y) by Q(x,y) to obtain the pure R(x,y), i.e.,
[0110] R(x,y) = I(x,y) / L(x,y);
[0111] Since the non-uniformity of the incident light is eliminated, the details of the reflected light will naturally become more prominent, thus enhancing the contrast. Taking the logarithm of both sides of the equation yields the enhanced model:
[0112] Log[R(x,y)] = Log[I(x,y)]-Log[Q(x,y)];
[0113] Where Log[R(x,y)] represents the processed image of the current grain; Log[I(x,y)] represents the logarithmic value of the current grain image; and Log[Q(x,y)] represents the logarithmic value of the incident image.
[0114] The image of the current grain after processing is quantized to obtain the image of the current grain after contrast enhancement.
[0115] This application remains open to the quantization processing method and does not impose specific limitations. For example, the pixel values of the processed current grain image can be quantized to the range of 0 to 255 to obtain a contrast-enhanced current grain image. This not only effectively improves the visual effect of the image but also ensures that the pixel values are within the standard display range, facilitating subsequent image processing and analysis. In this way, the image contrast can be flexibly adjusted according to actual needs to highlight features or details of interest.
[0116] This application also provides an application example:
[0117] Figure 2 This is a schematic diagram of a grain image contrast enhancement method provided in an embodiment of this application, as shown below. Figure 2 As shown, the process involves acquiring images (kernels) of the current die and multiple adjacent dies at the same location; calculating the kernel image gradient and dividing edge pixels into edge pixels and non-edge pixels; generating a reference kernel image (i.e., a guide image); using the reference kernel image and the kernel of the current die as inputs to the guide filter, generating a filtered image Q (i.e., the incident image corresponding to the image of the current die); substituting Q into the formula Log[R(x,y)] = Log[I(x,y)]-Log[Q(x,y)], and quantizing Log[R(x,y)] into pixel values in the range of 0-255.
[0118] This application skillfully balances detail preservation and noise suppression while significantly suppressing halo effects. By employing a single-scale Retinex combined with guide map filtering (although this technique has been applied in mobile photography, camera shooting, and medical image processing, it is the first of its kind in the field of wafer image contrast enhancement), this application can differentiate between edge and non-edge regions during image contrast enhancement. Specifically, in the guide map generation stage, this application combines information from multiple identical images and applies optimization strategies for edge and non-edge parts respectively, thereby ensuring that non-edge regions remain smooth while edge regions are protected from over-smoothing. This method not only efficiently improves image contrast but also maximizes the preservation of key edge information, providing a new solution for wafer image processing.
[0119] Figure 3 A structural diagram of a grain image contrast enhancement device provided in an embodiment of this application is shown below. Figure 3 As shown, based on the method for enhancing grain image contrast provided in the preceding embodiments, this application also provides a corresponding device for enhancing grain image contrast, comprising:
[0120] An acquisition module is used to acquire an image of the current die and images of multiple adjacent dies in a wafer to be inspected; the wafer to be inspected includes multiple dies; the image of the current die is an image of a preset location of the current die; the images of adjacent dies are images of the preset locations of the adjacent dies; the multiple dies include the current die and the multiple adjacent dies; the multiple adjacent dies are all dies adjacent to the current die.
[0121] The segmentation module is used to perform edge segmentation on the images of the multiple adjacent grains based on the gradient value of the current grain's image, thereby obtaining multiple segmented images of adjacent grains.
[0122] The guide map determination module is used to obtain a guide map based on the images of the multiple partitioned adjacent grains.
[0123] An incident image determination module is used to obtain the incident image corresponding to the image of the current grain based on the guide image and the image of the current grain.
[0124] An enhancement module is used to obtain a contrast-enhanced image of the current grain based on the incident image and the image of the current grain.
[0125] As an optional embodiment, the acquisition module is specifically used for:
[0126] An integral time-delay camera is used to acquire images of the current grain and multiple adjacent grains in the wafer to be inspected.
[0127] As an optional embodiment, the apparatus further includes:
[0128] The gradient calculation module is used to calculate the gradient value of the current grain image using a gradient algorithm; the gradient algorithm includes the Canny edge detection algorithm, the Sobel edge detection algorithm, or the variance method.
[0129] As an optional embodiment, the guide graph determination module is specifically used for:
[0130] A database determination unit is used to obtain a database based on the images of the plurality of partitioned adjacent grains according to pixel coordinates; the database includes a plurality of edge pixel datasets and a plurality of non-edge pixel datasets; the images of the plurality of partitioned adjacent grains include the same number of edge pixels and the same number of non-edge pixels; the number of edge pixel datasets in the database is consistent with the number of edge pixels in the images of the partitioned adjacent grains; the number of non-edge pixel datasets in the database is consistent with the number of non-edge pixels in the images of the partitioned adjacent grains; the number of edge pixel values in the edge pixel datasets and the number of non-edge pixel values in the non-edge pixel datasets are both consistent with the number of images of the partitioned adjacent grains; the edge pixel dataset includes a plurality of edge pixel values and the pixel coordinates of each edge pixel; the non-edge pixel dataset includes a plurality of non-edge pixel values and the pixel coordinates of each non-edge pixel.
[0131] The sorting unit is used to sort the edge pixel values in each edge pixel dataset in descending order to obtain multiple sorted edge pixel datasets.
[0132] The sorting unit is also used to sort the non-edge pixel values in each non-edge pixel dataset in descending order to obtain multiple sorted non-edge pixel datasets.
[0133] The guide map determination unit is used to determine the pixel value corresponding to each pixel coordinate in the guide map based on the plurality of sorted edge pixel datasets and the plurality of sorted non-edge pixel datasets, so as to obtain the guide map; the number of pixel values in the guide map is consistent with the number of pixel values in the image of the partitioned adjacent grains.
[0134] As an optional embodiment, the guide diagram determination unit is specifically used for:
[0135] The median of each sorted non-edge pixel dataset is determined as the pixel value of the corresponding pixel coordinate in the guide map; the preset mean of each sorted edge pixel dataset is determined as the pixel value of the corresponding pixel coordinate in the guide map, thus obtaining the guide map.
[0136] As an optional embodiment, the incident image determination module is specifically used for:
[0137] The guiding image and the image of the current die are input into the guiding filter to obtain the incident image corresponding to the image of the current die output by the guiding filter.
[0138] As an optional embodiment, the guiding filter includes:
[0139] = ;
[0140] in, This represents the incident image corresponding to the image of the current grain; The weights represent the weighted average of the guide graph; This represents the image of the current grain.
[0141] As an optional embodiment, the enhancement module is specifically used for:
[0142] The incident image and the image of the current grain are input into the enhancement model to obtain the processed image of the current grain output by the enhancement model; the processed image of the current grain is then quantized to obtain the contrast-enhanced image of the current grain.
[0143] The enhancement model includes:
[0144] Log[R(x,y)] = Log[I(x,y)]-Log[Q(x,y)];
[0145] Where Log[R(x,y)] represents the processed image of the current grain; Log[I(x,y)] represents the logarithmic value of the current grain image; and Log[Q(x,y)] represents the logarithmic value of the incident image.
[0146] This application provides a computer device, including: a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the computer program to implement a method for enhancing the contrast of a grain image.
[0147] This application provides a computer-readable storage medium storing a computer program that, when executed by a processor, implements a method for enhancing the contrast of a crystal image.
[0148] This application provides a computer program product, including a computer program that, when executed by a processor, implements a method for enhancing the contrast of a die image.
[0149] It should be noted that the various embodiments in this specification are described in a progressive manner, and the same or similar parts between the various embodiments can be referred to mutually. Each embodiment focuses on describing the differences from other embodiments. In particular, for the device and equipment embodiments, since they are basically similar to the method embodiments, the description is relatively simple, and the relevant parts can be referred to the description of the method embodiments. The device and equipment embodiments described above are merely illustrative. The units described as separate components may or may not be physically separate, and the components indicated 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 modules can be selected to achieve the purpose of the solution in this embodiment according to actual needs. Those skilled in the art can understand and implement this without creative effort.
[0150] The above description is merely one specific embodiment of this application, but the scope of protection of this application is not limited thereto. Any variations or substitutions that can be easily conceived by those skilled in the art within the technical scope disclosed in this application should be included within the scope of protection of this application. Therefore, the scope of protection of this application should be determined by the scope of the claims.
Claims
1. A method for enhancing the contrast of a grain image, characterized in that, The method includes: The process involves acquiring an image of the current die and images of multiple adjacent dies in a wafer to be inspected; the wafer to be inspected includes multiple dies; the image of the current die is an image of a preset location of the current die; the images of adjacent dies are images of the preset locations of the adjacent dies; the multiple dies include the current die and the multiple adjacent dies; the multiple adjacent dies are all dies adjacent to the current die; Based on the gradient value of the current grain's image, the images of the multiple adjacent grains are edge-divided to obtain multiple divided images of adjacent grains; A guide map is obtained based on the images of the multiple partitioned adjacent grains; Based on the guiding image and the image of the current grain, the incident image corresponding to the image of the current grain is obtained; Based on the incident image and the image of the current grain, an image of the current grain with enhanced contrast is obtained.
2. The method for enhancing grain image contrast according to claim 1, characterized in that, The acquisition of the image of the current grain and multiple adjacent grains in the wafer to be inspected specifically includes: An integral time-delay camera is used to acquire images of the current grain and multiple adjacent grains in the wafer to be inspected.
3. The method for enhancing grain image contrast according to claim 1, characterized in that, Before performing edge segmentation on the images of the plurality of adjacent grains based on the gradient value of the current grain's image to obtain the plurality of segmented images of adjacent grains, the method further includes: The gradient value of the current grain image is calculated using a gradient algorithm; the gradient algorithm includes the Canny edge detection algorithm, the Sobel edge detection algorithm, or the variance method.
4. The method for enhancing grain image contrast according to claim 1, characterized in that, The guide map obtained based on the images of the multiple partitioned adjacent grains specifically includes: A database is obtained based on the images of the multiple partitioned adjacent grains using pixel coordinates. The database includes multiple edge pixel datasets and multiple non-edge pixel datasets. The images of the multiple partitioned adjacent grains include the same number of edge pixels and the same number of non-edge pixels. The number of edge pixel datasets in the database is consistent with the number of edge pixels in the images of the partitioned adjacent grains. The number of non-edge pixel datasets in the database is consistent with the number of non-edge pixels in the images of the partitioned adjacent grains. The number of edge pixel values in the edge pixel datasets and the number of non-edge pixel values in the non-edge pixel datasets are both consistent with the number of images of the partitioned adjacent grains. The edge pixel dataset includes multiple edge pixel values and the pixel coordinates of each edge pixel. The non-edge pixel dataset includes multiple non-edge pixel values and the pixel coordinates of each non-edge pixel. The edge pixel values in each edge pixel dataset are sorted in descending order to obtain multiple sorted edge pixel datasets; Sort the non-edge pixel values in each non-edge pixel dataset in descending order to obtain multiple sorted non-edge pixel datasets; Based on the sorted edge pixel datasets and the sorted non-edge pixel datasets, the pixel value corresponding to each pixel coordinate in the guide map is determined to obtain the guide map; the number of pixel values in the guide map is consistent with the number of pixel values in the image of the adjacent grains after division.
5. The method for enhancing grain image contrast according to claim 4, characterized in that, The process of determining the pixel value corresponding to each pixel coordinate in the guide map based on the multiple sorted edge pixel datasets and the multiple sorted non-edge pixel datasets to obtain the guide map specifically includes: The median of each sorted non-edge pixel dataset is determined as the pixel value of the corresponding pixel coordinate in the guide map; The preset mean of each sorted edge pixel dataset is determined as the pixel value of the corresponding pixel coordinate in the guide map, thus obtaining the guide map.
6. The method for enhancing grain image contrast according to claim 1, characterized in that, The step of obtaining the incident image corresponding to the image of the current grain based on the guide map and the image of the current grain specifically includes: The guiding image and the image of the current die are input into the guiding filter to obtain the incident image corresponding to the image of the current die output by the guiding filter.
7. The method for enhancing grain image contrast according to claim 6, characterized in that, The guiding filter includes: = ; in, This represents the incident image corresponding to the image of the current grain; The weights represent the weighted average of the guide graph; This represents the image of the current grain.
8. The method for enhancing grain image contrast according to claim 1, characterized in that, The step of obtaining a contrast-enhanced image of the current grain based on the incident image and the image of the current grain specifically includes: The incident image and the image of the current grain are input into the enhancement model to obtain the processed image of the current grain output by the enhancement model; The processed image of the current grain is quantized to obtain the contrast-enhanced image of the current grain. The enhancement model includes: Log[R(x,y)] = Log[I(x,y)]-Log[Q(x,y)]; Where Log[R(x,y)] represents the processed image of the current grain; Log[I(x,y)] represents the logarithmic value of the current grain image; and Log[Q(x,y)] represents the logarithmic value of the incident image.
9. A grain image contrast enhancement device, characterized in that, The grain image contrast enhancement device includes: An acquisition module is used to acquire an image of the current die and images of multiple adjacent dies in a wafer to be inspected; the wafer to be inspected includes multiple dies; the image of the current die is an image of a preset location of the current die; the images of adjacent dies are images of the preset locations of the adjacent dies; the multiple dies include the current die and the multiple adjacent dies; the multiple adjacent dies are all dies adjacent to the current die; The segmentation module is used to perform edge segmentation on the images of the multiple adjacent grains based on the gradient value of the current grain's image, thereby obtaining multiple segmented images of adjacent grains; The guide map determination module is used to obtain a guide map based on the images of the multiple partitioned adjacent grains; An incident image determination module is used to obtain the incident image corresponding to the image of the current grain based on the guide image and the image of the current grain; An enhancement module is used to obtain a contrast-enhanced image of the current grain based on the incident image and the image of the current grain.
10. A computer device, comprising: A memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that the processor executes the computer program to implement the grain image contrast enhancement method according to any one of claims 1-8.