Printing paper defect detection system and method based on machine vision

By reducing noise, grayscale and contrast processing of printing paper images, the defect detection accuracy problem caused by insufficient adaptability of image contrast adjustment in the prior art is solved, and efficient and accurate printing paper defect detection is achieved.

CN118329910BActive Publication Date: 2025-04-29FO SHAN SHI LV ZHI CAI YIN SHUA YOU XIAN GONG SI
View PDF 1 Cites 0 Cited by

Patent Information

Application Number
CN202410301248.5
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-03-15
Publication Date
2025-04-29
Estimated Expiration
2044-03-15

AI Technical Summary

Technical Problem

In the prior art, due to the low adaptability of image contrast adjustment, the accuracy of printing paper defect detection is poor.

Method used

By performing image preprocessing on image information, including noise reduction processing, grayscale processing and contrast adjustment, the preprocessed image information is obtained to improve the accuracy of defect detection. The specific steps include using median filtering, Gaussian filtering or mean filtering to perform noise reduction processing, converting it into a grayscale graph, and grayscale adjustment by calculating the grayscale reference value and the target grayscale value, and finally making contrast adjustments.

Benefits of technology

It improves the accuracy and efficiency of defect detection of printing paper, reduces the possibility of false detection and missed detection, adapts to printing paper of different structures and sizes, and responds to different types of defects by adjusting algorithm parameters, and realizes automated and intelligent defect detection.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118329910B_ABST
    Figure CN118329910B_ABST
Patent Text Reader

Abstract

The present invention proposes a printing paper defect detection system and method based on machine vision. The printing paper defect detection method comprises: controlling a camera installed on a printing paper conveyor belt to collect image information of each printing paper in real time; performing image preprocessing on the image information, obtaining preprocessed image information, and using the preprocessed image information as a target image to be identified; performing area setting for the target image to obtain multiple areas to be detected; performing defect detection and judgment on each area to be detected in the target image, and obtaining a defect detection result corresponding to the target image. The system comprises modules corresponding to the steps of the method.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The invention proposes a printing paper defect detection system and method based on machine vision, belonging to the technical field of defect detection. Background Art

[0002] Printing paper defect detection based on machine vision is a method that uses computer vision technology to automatically detect various defects on printed paper. The above technical solution collects, processes and analyzes images of printed paper by simulating human visual functions, thereby identifying various defects on the paper, such as holes, dust, stains, scratches, etc.

[0003] Printing paper defect detection based on machine vision has many advantages, such as fast detection speed, high accuracy, good repeatability, etc. At the same time, since the machine vision system can automatically detect, it can greatly reduce the labor intensity and cost of manual detection and improve production efficiency.

[0004] With the continuous development and advancement of computer vision technology, printing paper defect detection based on machine vision will become more and more mature and popular, providing strong support for quality control and product improvement in the printing industry.

[0005] However, in practical applications, the defect detection in the prior art still has the problem of poor defect detection accuracy due to low adaptability of image contrast adjustment. Summary of the invention

[0006] The present invention provides a printing paper defect detection system and method based on machine vision, which is used to solve the problem of poor defect detection accuracy due to low adaptability of image contrast adjustment during defect detection in the prior art. The technical solutions adopted are as follows:

[0007] A printing paper defect detection method based on machine vision, the printing paper defect detection method comprising:

[0008] Control the camera installed on the printing paper conveyor belt to collect the image information of each printing paper in real time;

[0009] Performing image preprocessing on the image information, obtaining preprocessed image information, and using the preprocessed image information as a target image to be identified;

[0010] Performing region setting for the target image to obtain a plurality of regions to be detected;

[0011] Defect detection and judgment are performed on each to-be-detected area of ​​the target image to obtain a defect detection result corresponding to the target image.

[0012] Further, performing image preprocessing on the image information to obtain preprocessed image information includes:

[0013] Performing noise reduction processing on the image information by using median filtering, Gaussian filtering or mean filtering to obtain image information after noise reduction processing;

[0014] Performing grayscale processing on the image information after the noise reduction processing to obtain a grayscale image corresponding to the image information after the noise reduction processing;

[0015] The contrast of the grayscale image is adjusted to obtain image information after contrast adjustment, wherein the image information after contrast adjustment is the preprocessed image information.

[0016] Further, performing contrast adjustment on the grayscale image to obtain image information after contrast adjustment includes:

[0017] Retrieve the grayscale value corresponding to each pixel in the grayscale image;

[0018] Obtaining a grayscale reference value of the grayscale image using the grayscale value corresponding to each pixel in the grayscale image;

[0019] Compare the grayscale value corresponding to each pixel with the grayscale reference value to obtain the difference between the grayscale value corresponding to each pixel and the grayscale reference value;

[0020] Obtaining a target grayscale value corresponding to each pixel point by using a difference between the grayscale value corresponding to each pixel point and the grayscale reference value;

[0021] Adjusting the grayscale of each pixel according to the target grayscale value corresponding to each pixel to obtain a grayscale image after grayscale adjustment;

[0022] Contrast adjustment is performed on the grayscale image after the grayscale adjustment to obtain image information after the contrast adjustment.

[0023] Further, performing contrast adjustment on the grayscale image after the grayscale adjustment to obtain image information after the contrast adjustment includes:

[0024] Retrieving the maximum pixel grayscale value and the corresponding pixel point corresponding to the grayscale image after grayscale adjustment, and taking the pixel point corresponding to the maximum pixel grayscale value as the first marked pixel point;

[0025] Extracting the grayscale value of the first marked pixel before grayscale adjustment;

[0026] Obtaining a first contrast compensation coefficient by using the grayscale value of the first marked pixel before grayscale adjustment and the grayscale value after grayscale adjustment;

[0027] Retrieving the minimum pixel grayscale value and the corresponding pixel point corresponding to the grayscale image after grayscale adjustment, and taking the pixel point corresponding to the minimum pixel grayscale value as the second marked pixel point;

[0028] Extracting the grayscale value of the second marked pixel before grayscale adjustment;

[0029] Obtaining a second contrast compensation coefficient by using the grayscale value of the second marked pixel before grayscale adjustment and the grayscale value after grayscale adjustment;

[0030] Obtaining a target contrast value using the first contrast compensation coefficient and the second contrast compensation coefficient;

[0031] The contrast of the grayscale image after the grayscale adjustment is adjusted according to the target contrast value to obtain image information after the contrast adjustment.

[0032] Furthermore, defect detection and judgment are performed on each to-be-detected area of ​​the target image to obtain a defect detection result corresponding to the target image, including:

[0033] Extracting image blocks of each area to be detected;

[0034] Extracting image features of an image region corresponding to the image block, wherein the image features include texture information, shape information, and color information;

[0035] Inputting the image features into a convolutional neural network model for defect detection to perform defect detection and identification, and obtaining a defect detection result corresponding to each image block;

[0036] The defect detection results corresponding to the image blocks of each area to be detected are integrated to generate defect detection results corresponding to the target image.

[0037] A printing paper defect detection system based on machine vision, the printing paper defect detection system comprising:

[0038] An image acquisition module is used to control the camera installed on the printing paper conveyor belt to acquire the image information of each printing paper in real time;

[0039] A target image acquisition module is used to perform image preprocessing on the image information, acquire the preprocessed image information, and use the preprocessed image information as the target image to be identified;

[0040] A partitioning module, used for performing region setting for the target image to obtain multiple regions to be detected;

[0041] The defect detection module is used to perform defect detection and judgment on each to-be-detected area of ​​the target image, and obtain the defect detection result corresponding to the target image.

[0042] Furthermore, the target image acquisition module includes:

[0043] A noise reduction processing module, used to perform noise reduction processing on the image information by using median filtering, Gaussian filtering or mean filtering to obtain image information after noise reduction processing;

[0044] A grayscale processing module, used to perform grayscale processing on the image information after the noise reduction processing, and obtain a grayscale image corresponding to the image information after the noise reduction processing;

[0045] The contrast adjustment module is used to perform contrast adjustment on the grayscale image to obtain image information after contrast adjustment, wherein the image information after contrast adjustment is the preprocessed image information.

[0046] Furthermore, the contrast adjustment module includes:

[0047] A grayscale value retrieving module, used to retrieve the grayscale value corresponding to each pixel in the grayscale image;

[0048] A grayscale reference value acquisition module, used to acquire a grayscale reference value of the grayscale image using the grayscale value corresponding to each pixel in the grayscale image;

[0049] A difference acquisition module, used for comparing the grayscale value corresponding to each pixel with the grayscale reference value, and acquiring the difference between the grayscale value corresponding to each pixel and the grayscale reference value;

[0050] A target grayscale value acquisition module, used to acquire a target grayscale value corresponding to each pixel point by using a difference between the grayscale value corresponding to each pixel point and the grayscale reference value;

[0051] A grayscale adjustment execution module, used to adjust the grayscale of each pixel according to the target grayscale value corresponding to each pixel, and obtain a grayscale image after the grayscale adjustment;

[0052] The contrast adjustment execution module is used to perform contrast adjustment on the grayscale image after the grayscale adjustment to obtain image information after the contrast adjustment.

[0053] Furthermore, the contrast adjustment execution module includes:

[0054] A first marking pixel point determination module is used to retrieve the maximum pixel grayscale value and the corresponding pixel point corresponding to the grayscale image after grayscale adjustment, and use the pixel point corresponding to the maximum pixel grayscale value as the first marking pixel point;

[0055] A first grayscale value extraction module, used to extract the grayscale value of the first marked pixel before grayscale adjustment;

[0056] A first contrast compensation coefficient acquisition module, used to acquire a first contrast compensation coefficient by using the grayscale value of the first marked pixel before grayscale adjustment and the grayscale value after grayscale adjustment;

[0057] A second marking pixel point determination module is used to retrieve the minimum pixel grayscale value and the corresponding pixel point corresponding to the grayscale image after grayscale adjustment, and use the pixel point corresponding to the minimum pixel grayscale value as the second marking pixel point;

[0058] A second grayscale value extraction module, used to extract the grayscale value of the second marked pixel before grayscale adjustment;

[0059] A second contrast compensation coefficient acquisition module, used to acquire a second contrast compensation coefficient by using the grayscale value of the second marked pixel before grayscale adjustment and the grayscale value after grayscale adjustment;

[0060] A target contrast value acquisition module, used for acquiring a target contrast value by using the first contrast compensation coefficient and the second contrast compensation coefficient;

[0061] The adjustment module is used to perform contrast adjustment on the grayscale image after the grayscale adjustment according to the target contrast value to obtain image information after the contrast adjustment.

[0062] Furthermore, the defect detection module includes:

[0063] An image block extraction module, used to extract an image block of each area to be detected;

[0064] An image feature extraction module, used to extract image features of an image region corresponding to the image block, wherein the image features include texture information, shape information and color information;

[0065] A defect detection and recognition module, used to input the image features into a convolutional neural network model for defect detection to perform defect detection and recognition, and obtain a defect detection result corresponding to each image block;

[0066] The information integration module is used to integrate the defect detection results corresponding to the image blocks of each area to be detected to generate defect detection results corresponding to the target image.

[0067] Beneficial effects of the present invention:

[0068] The machine vision-based printing paper defect detection system and method proposed in the present invention can quickly detect defects on a large number of printing papers by collecting and processing image information in real time, greatly improving the detection efficiency. At the same time, by using image preprocessing and feature extraction technology, the system and method can accurately identify various defects on the printing paper, reducing the possibility of false detection and missed detection. The area setting method allows the method to adapt to printing papers of different structures and sizes, and can also cope with different types of defects by adjusting algorithm parameters. The above-mentioned technical solution of this embodiment realizes the automation and intelligence of printing paper defect detection, reduces the need for manual intervention, and improves the stability and reliability of the production line. By reducing manual inspection costs and improving production efficiency, the method helps to reduce production costs, improve product quality, and thus enhance the competitiveness of enterprises. BRIEF DESCRIPTION OF THE DRAWINGS

[0069] Figure 1 is a flow chart of the method of the present invention;

[0070] Figure 2 The system block diagram of the system of the present invention. DETAILED DESCRIPTION

[0071] The preferred embodiments of the present invention are described below in conjunction with the accompanying drawings. It should be understood that the preferred embodiments described herein are only used to illustrate and explain the present invention, and are not used to limit the present invention.

[0072] The embodiment of the present invention proposes a printing paper defect detection method based on machine vision, such as Figure 1 As shown, the printing paper defect detection method includes:

[0073] S1, controlling the camera installed on the printing paper conveyor belt to collect image information of each printing paper in real time;

[0074] S2, performing image preprocessing on the image information, obtaining preprocessed image information, and using the preprocessed image information as a target image to be identified;

[0075] S3, performing region setting for the target image to obtain multiple regions to be detected;

[0076] S4. Perform defect detection and judgment on each to-be-detected area of ​​the target image to obtain a defect detection result corresponding to the target image.

[0077] The working principle of the above technical solution is as follows: the camera installed on the printing paper conveyor belt captures the image information of each printing paper in real time. The image acquisition device in the machine vision system is used to ensure that the surface image of the printing paper can be obtained continuously and quickly. The collected image information is preprocessed, which usually includes operations such as filtering, enhancement and binarization to eliminate noise, enhance features and improve image quality. The preprocessed image information serves as the basis for subsequent defect detection, that is, the target image to be identified. Multiple areas to be detected are set on the target image. These areas can be set based on prior knowledge, the structure of the printing paper, or the expected location of defects. The purpose of area setting is to decompose the detection task into smaller and more specific parts so that defect detection can be performed more effectively. Detailed defect detection is performed on each area to be detected. This usually involves the application of algorithms such as feature extraction, template matching, and machine learning classification. The system will determine whether there is a defect in the area based on a preset threshold or model, and output the corresponding detection result.

[0078] The effect of the above technical solution is as follows: the above technical solution of this embodiment can quickly detect defects on a large number of printed papers by real-time acquisition and processing of image information, thereby greatly improving the detection efficiency. At the same time, by using image preprocessing and feature extraction technology, the method can accurately identify various defects on printed paper, reducing the possibility of false detection and missed detection. The area setting method enables the method to adapt to printed papers of different structures and sizes, and can also cope with different types of defects by adjusting algorithm parameters. The above technical solution of this embodiment realizes the automation and intelligence of printed paper defect detection, reduces the need for manual intervention, and improves the stability and reliability of the production line. By reducing manual inspection costs and improving production efficiency, the method helps to reduce production costs, improve product quality, and thus enhance the competitiveness of enterprises.

[0079] In summary, the printing paper defect detection method based on machine vision achieves efficient, accurate and flexible printing paper defect detection by combining technical means such as real-time image acquisition, preprocessing, area setting and defect detection, providing strong support for quality control and product improvement in the printing industry.

[0080] In one embodiment of the present invention, performing image preprocessing on the image information to obtain the preprocessed image information includes:

[0081] S201, performing noise reduction processing on the image information by using median filtering, Gaussian filtering or mean filtering to obtain image information after noise reduction processing;

[0082] S202, performing grayscale processing on the image information after the noise reduction processing to obtain a grayscale image corresponding to the image information after the noise reduction processing;

[0083] S203 , performing contrast adjustment on the grayscale image to obtain contrast-adjusted image information, wherein the contrast-adjusted image information is preprocessed image information.

[0084] The working principle of the above technical solution is: Noise reduction processing (S201):

[0085] The image may be interfered by various noises during the acquisition process, such as photoelectric conversion noise, electromagnetic interference, etc. In order to eliminate these noises and improve the image quality, median filtering, Gaussian filtering or mean filtering are used to reduce the noise of image information.

[0086] Median filtering is a nonlinear filtering method based on sorting statistics theory, which can effectively remove salt and pepper noise.

[0087] Gaussian filtering is a linear filtering method that reduces noise by performing weighted averaging on the image.

[0088] Mean filtering calculates the average value within the neighborhood of a pixel to replace the original pixel value, which also has the effect of noise reduction.

[0089] Grayscale processing (S202):

[0090] Color images contain rich color information, but in defect detection, color information may not be necessary and may increase the complexity of processing. Therefore, converting the image information after denoising into a grayscale image, that is, retaining only the brightness information of the image, is conducive to subsequent feature extraction and defect detection.

[0091] Grayscale processing usually involves weighting and summing the values ​​of the three RGB channels of a color image in a certain proportion to obtain a grayscale value to represent the brightness of the pixel.

[0092] Contrast adjustment (S203):

[0093] Contrast reflects the degree of difference between light and dark areas in an image. If the contrast is too low, the details in the image may not be clear, affecting the effect of defect detection. Therefore, the contrast of the grayscale image is adjusted to make the difference between light and dark in the image more obvious.

[0094] Contrast adjustment can be achieved by stretching the pixel intensity distribution range or applying histogram equalization.

[0095] The effects of the above technical solution are as follows: through noise reduction processing, the noise interference in the image is effectively reduced, the signal-to-noise ratio of the image is improved, and clearer image data is provided for subsequent feature extraction and defect detection. Grayscale processing converts color images into grayscale images, simplifies the complexity of image data, and reduces the difficulty and amount of processing. Contrast adjustment makes the difference between light and dark in the image more significant, which is conducive to highlighting defect features and improving the accuracy and sensitivity of defect detection. After this series of preprocessing steps, the overall quality of the image has been significantly improved, providing a better foundation for subsequent defect detection.

[0096] In summary, this image preprocessing technology solution effectively optimizes the image quality through steps such as noise reduction, grayscale processing and contrast adjustment, and provides high-quality image data for subsequent printed paper defect detection.

[0097] In one embodiment of the present invention, contrast adjustment is performed on the grayscale image to obtain contrast-adjusted image information, including:

[0098] S2031, retrieving the grayscale value corresponding to each pixel in the grayscale image;

[0099] S2032. Obtain a grayscale reference value of the grayscale image using the grayscale value corresponding to each pixel in the grayscale image; wherein the grayscale reference value is obtained by the following formula:

[0100]

[0101] Among them, H c Represents the grayscale reference value of the grayscale image; n represents the number of pixels contained in the grayscale image; H i Indicates the gray value corresponding to the i-th pixel; H z Represents the grayscale median value corresponding to all pixels contained in the grayscale image;

[0102] S2033, comparing the grayscale value corresponding to each pixel with the grayscale reference value, and obtaining a difference between the grayscale value corresponding to each pixel and the grayscale reference value;

[0103] S2034, obtaining a target grayscale value corresponding to each pixel point by using a difference between the grayscale value corresponding to each pixel point and the grayscale reference value;

[0104]

[0105] Among them, H mi represents the target grayscale value corresponding to the i-th pixel of the grayscale image;

[0106] S2035, adjusting the grayscale of each pixel according to the target grayscale value corresponding to each pixel, and obtaining a grayscale image after the grayscale adjustment;

[0107] S2036: Perform contrast adjustment on the grayscale image after the grayscale adjustment to obtain image information after the contrast adjustment.

[0108] The working principle of the above technical solution is: call the gray value (S2031):

[0109] This step is part of the preprocessing process, and its main purpose is to obtain the grayscale value of each pixel in the grayscale image. The grayscale value is usually an integer between 0 and 255, representing the brightness of the pixel in the image.

[0110] Obtaining grayscale reference value (S2032):

[0111] After obtaining the grayscale values ​​of all pixels, a grayscale reference value is calculated based on these grayscale values. This reference value can be the average, median or other statistics of the grayscale values ​​of all pixels, representing the average brightness or typical brightness of the entire grayscale image.

[0112] Calculate the grayscale difference (S2033):

[0113] Compare the grayscale value of each pixel with the grayscale reference value calculated previously, and calculate the difference between them. This difference reflects the difference between the brightness of the pixel and the average brightness of the overall grayscale image.

[0114] Get the target grayscale value (S2034):

[0115] According to the difference between the grayscale value of each pixel and the grayscale reference value, the target grayscale value of each pixel is calculated through a certain algorithm or rule. This target grayscale value may be a new grayscale value obtained by stretching, compressing or some transformation based on the difference.

[0116] Grayscale adjustment (S2035):

[0117] Replace the grayscale value of each pixel with the target grayscale value calculated previously to complete the adjustment of the grayscale image. The purpose of this step is to change the brightness distribution of the pixels in the grayscale image so that it better meets the needs of subsequent contrast adjustment.

[0118] Contrast adjustment (S2036):

[0119] After grayscale adjustment is completed, the contrast of the grayscale image is further adjusted. Contrast adjustment can be achieved by stretching the pixel intensity distribution range, applying histogram equalization or other contrast enhancement algorithms to highlight the details and features in the image.

[0120] The effect of the above technical solution is: by calculating the grayscale reference value and adjusting the grayscale value of each pixel, the above technical solution can optimize the brightness distribution of the pixels in the grayscale image, making the image more uniform and clear. The combination of grayscale adjustment and contrast adjustment can highlight the details and features in the image, especially for printed paper defect detection, which helps to more accurately identify defective areas. After such a preprocessing process, the image quality has been significantly improved, providing a better data basis for subsequent defect detection, thereby improving the accuracy and reliability of defect detection. The above technical solution can adapt to grayscale images of different qualities and types. By adjusting the grayscale reference value and contrast parameters, it can flexibly respond to image processing needs in various scenarios.

[0121] On the other hand, by calculating the grayscale values ​​of all pixels and considering their distribution, the above technical solution can comprehensively evaluate the grayscale level of the entire grayscale image. Each pixel is taken into account, so the result is more representative. Grayscale reference value (H c ) can reflect the overall brightness level of the grayscale image. c A higher value means that the image is brighter overall; conversely, if H c If the value is low, the image will be darker overall. Since the grayscale values ​​of all pixels are taken into account and compared, the above technical solution is highly robust to local noise or abnormal values ​​in the image, and can reduce the impact of external factors on the grayscale reference value, making the result more stable. Regardless of how the dynamic range of the grayscale image changes (i.e., the grayscale difference between the darkest and brightest pixels), the above technical solution can effectively calculate the reference value that reflects the overall grayscale level. At the same time, the grayscale intermediate value (H) introduced in the formula z ) provides a reference point for calculating the grayscale reference value. z , H can be further adjusted c The calculation is closer to the actual grayscale distribution characteristics of the image. The above technical solution is relatively simple and intuitive, easy to program and implement, and has high computational efficiency, which is suitable for processing large-scale image data. The grayscale reference value of the grayscale image obtained by the method can provide a comprehensive, stable and easy-to-implement grayscale level evaluation in terms of performance indicators, which is helpful for subsequent image processing and analysis.

[0122] In summary, the above technical solution optimizes the brightness distribution and contrast of the grayscale image through the two key steps of grayscale adjustment and contrast adjustment, provides high-quality image data for subsequent printed paper defect detection, and improves the accuracy and reliability of detection.

[0123] In one embodiment of the present invention, contrast adjustment is performed on the grayscale image after the grayscale adjustment to obtain image information after the contrast adjustment, including:

[0124] Step 1: retrieve the maximum pixel grayscale value and its corresponding pixel point corresponding to the grayscale image after grayscale adjustment, and use the pixel point corresponding to the maximum pixel grayscale value as the first marked pixel point;

[0125] Step 2, extracting the grayscale value of the first marked pixel before grayscale adjustment;

[0126] Step 3: Obtain a first contrast compensation coefficient using the grayscale value of the first marked pixel before grayscale adjustment and the grayscale value after grayscale adjustment; wherein the first contrast compensation coefficient is obtained by the following formula:

[0127]

[0128] Among them, S 01 represents the first contrast compensation coefficient; S0 represents the preset initial value of the compensation coefficient; H x01 represents the grayscale value of the first marked pixel before grayscale adjustment; H h01 represents the grayscale value of the first marked pixel after grayscale adjustment;

[0129] Step 4: retrieve the minimum pixel grayscale value and the corresponding pixel point corresponding to the grayscale image after grayscale adjustment, and use the pixel point corresponding to the minimum pixel grayscale value as the second marked pixel point;

[0130] Step 5, extracting the grayscale value of the second marked pixel before grayscale adjustment;

[0131] Step 6: Obtain a second contrast compensation coefficient using the grayscale value of the second marking pixel before grayscale adjustment and the grayscale value after grayscale adjustment; wherein the second contrast compensation coefficient is obtained by the following formula:

[0132]

[0133] Among them, S 02 Represents the second contrast compensation coefficient; H x02 represents the grayscale value of the second marking pixel before grayscale adjustment; H h02 represents the grayscale value of the second marked pixel after grayscale adjustment;

[0134] Step 7: Obtain a target contrast value using the first contrast compensation coefficient and the second contrast compensation coefficient; wherein the target contrast value is obtained by the following formula:

[0135]

[0136] Among them, D m Indicates the target contrast value; H maxrepresents the grayscale value of the first marked pixel before grayscale adjustment; H min represents the grayscale value of the second marked pixel before grayscale adjustment;

[0137] Step 8: performing contrast adjustment on the grayscale image after the grayscale adjustment according to the target contrast value to obtain image information after the contrast adjustment.

[0138] The working principle of the above technical solution is as follows: in the grayscale image after grayscale adjustment, find the pixel with the largest grayscale value, that is, the brightest pixel, and mark it as the first marked pixel, and obtain the original grayscale value of the first marked pixel before grayscale adjustment. According to the original grayscale value of the first marked pixel and the grayscale value after grayscale adjustment, calculate a contrast compensation coefficient, which is used to compensate for the difference in the maximum grayscale value when adjusting the image contrast later. In the grayscale image after grayscale adjustment, find the pixel with the smallest grayscale value, that is, the darkest pixel, and mark it as the second marked pixel, and then obtain the original grayscale value of the second marked pixel before grayscale adjustment. According to the original grayscale value of the second marked pixel and the grayscale value after grayscale adjustment, calculate another contrast compensation coefficient to compensate for the difference in the minimum grayscale value. Combine the first and second contrast compensation coefficients to calculate the target contrast value. This value will be used as the target value for subsequent contrast adjustment. According to the calculated target contrast value, the grayscale image after grayscale adjustment is contrast adjusted to optimize the contrast of the image so that it better meets the needs of visual perception or subsequent defect detection.

[0139] The effect of the above technical solution is: by using the information of the maximum and minimum pixel grayscale before and after adjustment, an accurate contrast compensation coefficient is calculated, thereby achieving accurate adjustment of the image contrast. By adjusting the maximum and minimum grayscale values, it is ensured that the important features in the image are retained during the contrast adjustment process, preventing excessive enhancement or weakening of certain areas. The above technical solution can calculate different contrast compensation coefficients according to the grayscale distribution characteristics of different images, so as to adapt to the contrast adjustment requirements in different scenarios. After the contrast adjustment, the details and features of the image are more prominent, which helps to improve the accuracy and reliability of subsequent printed paper defect detection.

[0140] At the same time, by respectively obtaining the pixel points corresponding to the maximum and minimum pixel grayscale values ​​(i.e., the first and second marked pixel points), and considering the grayscale value changes of these pixel points before and after the grayscale adjustment, the first and second contrast compensation coefficients can be accurately calculated. These two coefficients comprehensively consider the grayscale changes of the brightest and darkest parts of the image, thereby improving the accuracy of the contrast calculation. The above technical solution not only considers the grayscale value after the grayscale adjustment, but also combines the grayscale value before the grayscale adjustment, so that the calculated contrast compensation coefficient can better reflect the actual contrast change of the image. This flexibility enables the above technical solution to adapt to different grayscale adjustment methods and adjustment degrees, and improves the versatility and applicability of contrast calculation. At the same time, by using the first and second contrast compensation coefficients, combined with the maximum and minimum grayscale values ​​before the grayscale adjustment, the target contrast value can be calculated. This value comprehensively considers the overall brightness and contrast distribution of the image, which helps to optimize the contrast performance of the image. By adjusting the contrast of the grayscale-adjusted image according to the target contrast value, the visual quality and detail expression of the image can be further improved. Since the above technical solution is based on the calculation of the pixel grayscale value, it has good stability and reliability. In different environments, as long as the grayscale value of the pixel can be accurately obtained, the target contrast value can be calculated according to the same steps and formula, thus ensuring the consistency and stability of image processing. Using the above technical solution to obtain the target contrast value can improve the accuracy, flexibility, optimization effect and performance stability of contrast calculation, providing strong support for the performance improvement of image processing and display technology.

[0141] In summary, the above technical solution achieves the purpose of accurate contrast adjustment of the grayscale image after grayscale adjustment by calculating the contrast compensation coefficient, optimizes the visual effect and feature expression of the image, and provides a better data basis for subsequent defect detection.

[0142] In one embodiment of the present invention, defect detection and judgment are performed on each to-be-detected area of ​​a target image to obtain a defect detection result corresponding to the target image, including:

[0143] S401, extracting image blocks of each area to be detected;

[0144] S402, extracting image features of an image region corresponding to the image block, wherein the image features include texture information, shape information, and color information;

[0145] S403, inputting the image features into a convolutional neural network model for defect detection to perform defect detection and identification, and obtaining a defect detection result corresponding to each image block;

[0146] S404: Integrate the defect detection results corresponding to the image blocks of each area to be detected to generate defect detection results corresponding to the target image.

[0147] The working principle of the above technical solution is: extracting the image block of the area to be detected (S401):

[0148] This step involves dividing the target image into multiple regions to be detected and extracting corresponding image blocks from these regions. The image block can be the entire region to be detected or a part of the region, depending on the needs of the actual application and the characteristics of the image.

[0149] Extracting image features (S402):

[0150] From each extracted image block, key image features are further extracted. These features include texture information (such as spatial relationships between pixels, repetitive patterns, etc.), shape information (such as edges, contours, etc.) and color information (such as color distribution, color histogram, etc.). These features can reflect the key information in the image block and provide an important basis for subsequent defect detection.

[0151] Defect detection and identification using a convolutional neural network model (S403):

[0152] The extracted image features are input into a pre-trained convolutional neural network model for processing. This model has been trained with a large number of defect samples and can learn the characteristics and patterns of defects. Through the forward propagation of the model, the defect detection results corresponding to each image block can be obtained, such as whether there is a defect, the type and location of the defect, etc.

[0153] Integrate defect detection results (S404):

[0154] Summarize and integrate the defect detection results corresponding to the image blocks of each area to be inspected. This includes merging the detection results of each image block into a complete detection result and processing possible duplicate or contradictory detection results. Finally, generate the overall defect detection result corresponding to the target image.

[0155] The effect of the above technical solution is: by using the convolutional neural network model for defect detection, the efficiency of detection can be significantly improved. The convolutional neural network can automatically learn and extract image features, avoiding the tedious manual feature extraction process in the traditional method. The convolutional neural network model trained with a large number of samples can accurately identify defects and reduce the probability of missed detection and false detection. At the same time, the robustness of detection is enhanced by comprehensively considering multiple features such as texture, shape and color. The above technical solution can adapt to different types of defect detection tasks, and only needs to adjust or retrain the convolutional neural network model. In addition, for images of different sizes and resolutions, the image block extraction method and feature extraction method can also be flexibly adjusted. The entire defect detection and judgment process is automated, reducing the need for manual intervention and improving the reliability and consistency of detection.

[0156] In summary, the above technical solution realizes an efficient, accurate, flexible and automated defect detection process by utilizing a convolutional neural network model and a variety of image features for defect detection, which is of great significance for the quality control of products such as printing paper.

[0157] The embodiment of the present invention proposes a printing paper defect detection system based on machine vision, such as Figure 2 As shown, the printing paper defect detection system comprises:

[0158] An image acquisition module is used to control the camera installed on the printing paper conveyor belt to acquire the image information of each printing paper in real time;

[0159] A target image acquisition module is used to perform image preprocessing on the image information, acquire the preprocessed image information, and use the preprocessed image information as the target image to be identified;

[0160] A partitioning module, used for performing region setting for the target image to obtain multiple regions to be detected;

[0161] The defect detection module is used to perform defect detection and judgment on each to-be-detected area of ​​the target image, and obtain the defect detection result corresponding to the target image.

[0162] The working principle of the above technical solution is as follows: the camera installed on the printing paper conveyor belt captures the image information of each printing paper in real time. The image acquisition device in the machine vision system is used to ensure that the surface image of the printing paper can be obtained continuously and quickly. The collected image information is preprocessed, which usually includes operations such as filtering, enhancement and binarization to eliminate noise, enhance features and improve image quality. The preprocessed image information serves as the basis for subsequent defect detection, that is, the target image to be identified. Multiple areas to be detected are set on the target image. These areas can be set based on prior knowledge, the structure of the printing paper, or the expected location of defects. The purpose of area setting is to decompose the detection task into smaller and more specific parts so that defect detection can be performed more effectively. Detailed defect detection is performed on each area to be detected. This usually involves the application of algorithms such as feature extraction, template matching, and machine learning classification. The system will determine whether there is a defect in the area based on a preset threshold or model, and output the corresponding detection result.

[0163] The effect of the above technical solution is as follows: the above technical solution of this embodiment can quickly detect defects on a large number of printed papers by real-time acquisition and processing of image information, thereby greatly improving the detection efficiency. At the same time, by using image preprocessing and feature extraction technology, the method can accurately identify various defects on printed paper, reducing the possibility of false detection and missed detection. The area setting method enables the method to adapt to printed papers of different structures and sizes, and can also cope with different types of defects by adjusting algorithm parameters. The above technical solution of this embodiment realizes the automation and intelligence of printed paper defect detection, reduces the need for manual intervention, and improves the stability and reliability of the production line. By reducing manual inspection costs and improving production efficiency, the method helps to reduce production costs, improve product quality, and thus enhance the competitiveness of enterprises.

[0164] In summary, the printing paper defect detection method based on machine vision achieves efficient, accurate and flexible printing paper defect detection by combining technical means such as real-time image acquisition, preprocessing, area setting and defect detection, providing strong support for quality control and product improvement in the printing industry.

[0165] In one embodiment of the present invention, the target image acquisition module includes:

[0166] A noise reduction processing module, used to perform noise reduction processing on the image information by using median filtering, Gaussian filtering or mean filtering to obtain image information after noise reduction processing;

[0167] A grayscale processing module, used to perform grayscale processing on the image information after the noise reduction processing, and obtain a grayscale image corresponding to the image information after the noise reduction processing;

[0168] The contrast adjustment module is used to perform contrast adjustment on the grayscale image to obtain image information after contrast adjustment, wherein the image information after contrast adjustment is the preprocessed image information.

[0169] The working principle of the above technical solution is: the image may be interfered by various noises during the acquisition process, such as photoelectric conversion noise, electromagnetic interference, etc. In order to eliminate these noises and improve the image quality, median filtering, Gaussian filtering or mean filtering are used to reduce the noise of the image information.

[0170] Median filtering is a nonlinear filtering method based on sorting statistics theory, which can effectively remove salt and pepper noise.

[0171] Gaussian filtering is a linear filtering method that reduces noise by performing weighted averaging on the image.

[0172] Mean filtering calculates the average value within the neighborhood of a pixel to replace the original pixel value, which also has the effect of noise reduction.

[0173] Color images contain rich color information, but in defect detection, color information may not be necessary and may increase the complexity of processing. Therefore, converting the image information after denoising into a grayscale image, that is, retaining only the brightness information of the image, is conducive to subsequent feature extraction and defect detection.

[0174] Grayscale processing usually involves weighting and summing the values ​​of the three RGB channels of a color image in a certain proportion to obtain a grayscale value to represent the brightness of the pixel.

[0175] Contrast reflects the degree of difference between light and dark areas in an image. If the contrast is too low, the details in the image may not be clear, affecting the effect of defect detection. Therefore, the contrast of the grayscale image is adjusted to make the difference between light and dark in the image more obvious.

[0176] Contrast adjustment can be achieved by stretching the pixel intensity distribution range or applying histogram equalization.

[0177] The effects of the above technical solution are as follows: through noise reduction processing, the noise interference in the image is effectively reduced, the signal-to-noise ratio of the image is improved, and clearer image data is provided for subsequent feature extraction and defect detection. Grayscale processing converts color images into grayscale images, simplifies the complexity of image data, and reduces the difficulty and amount of processing. Contrast adjustment makes the difference between light and dark in the image more significant, which is conducive to highlighting defect features and improving the accuracy and sensitivity of defect detection. After this series of preprocessing steps, the overall quality of the image has been significantly improved, providing a better foundation for subsequent defect detection.

[0178] In summary, this image preprocessing technology solution effectively optimizes the image quality through steps such as noise reduction, grayscale processing and contrast adjustment, and provides high-quality image data for subsequent printed paper defect detection.

[0179] In one embodiment of the present invention, the contrast adjustment module includes:

[0180] A grayscale value retrieving module, used to retrieve the grayscale value corresponding to each pixel in the grayscale image;

[0181] A grayscale reference value acquisition module, used to acquire a grayscale reference value of the grayscale image using the grayscale value corresponding to each pixel in the grayscale image;

[0182] A difference acquisition module, used for comparing the grayscale value corresponding to each pixel with the grayscale reference value, and acquiring the difference between the grayscale value corresponding to each pixel and the grayscale reference value;

[0183] A target grayscale value acquisition module, used to acquire a target grayscale value corresponding to each pixel point by using a difference between the grayscale value corresponding to each pixel point and the grayscale reference value;

[0184] A grayscale adjustment execution module, used to adjust the grayscale of each pixel according to the target grayscale value corresponding to each pixel, and obtain a grayscale image after the grayscale adjustment;

[0185] The contrast adjustment execution module is used to perform contrast adjustment on the grayscale image after the grayscale adjustment to obtain image information after the contrast adjustment.

[0186] The working principle of the above technical solution is as follows: This step is part of the preprocessing process, and its main purpose is to obtain the grayscale value of each pixel from the grayscale image. The grayscale value is usually an integer between 0 and 255, representing the brightness of the pixel in the image.

[0187] After obtaining the grayscale values ​​of all pixels, a grayscale reference value is calculated based on these grayscale values. This reference value can be the average, median or other statistics of the grayscale values ​​of all pixels, representing the average brightness or typical brightness of the entire grayscale image.

[0188] Compare the grayscale value of each pixel with the grayscale reference value calculated previously, and calculate the difference between them. This difference reflects the difference between the brightness of the pixel and the average brightness of the overall grayscale image.

[0189] According to the difference between the grayscale value of each pixel and the grayscale reference value, the target grayscale value of each pixel is calculated through a certain algorithm or rule. This target grayscale value may be a new grayscale value obtained by stretching, compressing or some transformation based on the difference.

[0190] Replace the grayscale value of each pixel with the target grayscale value calculated previously to complete the adjustment of the grayscale image. The purpose of this step is to change the brightness distribution of the pixels in the grayscale image so that it better meets the needs of subsequent contrast adjustment.

[0191] After grayscale adjustment is completed, the contrast of the grayscale image is further adjusted. Contrast adjustment can be achieved by stretching the pixel intensity distribution range, applying histogram equalization or other contrast enhancement algorithms to highlight the details and features in the image.

[0192] The effect of the above technical solution is: by calculating the grayscale reference value and adjusting the grayscale value of each pixel, the above technical solution can optimize the brightness distribution of the pixels in the grayscale image, making the image more uniform and clear. The combination of grayscale adjustment and contrast adjustment can highlight the details and features in the image, especially for printed paper defect detection, which helps to more accurately identify defective areas. After such a preprocessing process, the image quality has been significantly improved, providing a better data basis for subsequent defect detection, thereby improving the accuracy and reliability of defect detection. The above technical solution can adapt to grayscale images of different qualities and types. By adjusting the grayscale reference value and contrast parameters, it can flexibly respond to image processing needs in various scenarios.

[0193] In summary, the above technical solution optimizes the brightness distribution and contrast of the grayscale image through the two key steps of grayscale adjustment and contrast adjustment, provides high-quality image data for subsequent printed paper defect detection, and improves the accuracy and reliability of detection.

[0194] In one embodiment of the present invention, the contrast adjustment execution module includes:

[0195] A first marking pixel point determination module is used to retrieve the maximum pixel grayscale value and the corresponding pixel point corresponding to the grayscale image after grayscale adjustment, and use the pixel point corresponding to the maximum pixel grayscale value as the first marking pixel point;

[0196] A first grayscale value extraction module, used to extract the grayscale value of the first marked pixel before grayscale adjustment;

[0197] A first contrast compensation coefficient acquisition module, used to acquire a first contrast compensation coefficient by using the grayscale value of the first marked pixel before grayscale adjustment and the grayscale value after grayscale adjustment;

[0198] A second marking pixel point determination module is used to retrieve the minimum pixel grayscale value and the corresponding pixel point corresponding to the grayscale image after grayscale adjustment, and use the pixel point corresponding to the minimum pixel grayscale value as the second marking pixel point;

[0199] A second grayscale value extraction module, used to extract the grayscale value of the second marked pixel before grayscale adjustment;

[0200] A second contrast compensation coefficient acquisition module, used to acquire a second contrast compensation coefficient by using the grayscale value of the second marked pixel before grayscale adjustment and the grayscale value after grayscale adjustment;

[0201] A target contrast value acquisition module, used for acquiring a target contrast value by using the first contrast compensation coefficient and the second contrast compensation coefficient;

[0202] The adjustment module is used to perform contrast adjustment on the grayscale image after the grayscale adjustment according to the target contrast value to obtain image information after the contrast adjustment.

[0203] The working principle of the above technical solution is as follows: in the grayscale image after grayscale adjustment, find the pixel with the largest grayscale value, that is, the brightest pixel, and mark it as the first marked pixel, and obtain the original grayscale value of the first marked pixel before grayscale adjustment. According to the original grayscale value of the first marked pixel and the grayscale value after grayscale adjustment, calculate a contrast compensation coefficient, which is used to compensate for the difference in the maximum grayscale value when adjusting the image contrast later. In the grayscale image after grayscale adjustment, find the pixel with the smallest grayscale value, that is, the darkest pixel, and mark it as the second marked pixel, and then obtain the original grayscale value of the second marked pixel before grayscale adjustment. According to the original grayscale value of the second marked pixel and the grayscale value after grayscale adjustment, calculate another contrast compensation coefficient to compensate for the difference in the minimum grayscale value. Combine the first and second contrast compensation coefficients to calculate the target contrast value. This value will be used as the target value for subsequent contrast adjustment. According to the calculated target contrast value, the grayscale image after grayscale adjustment is contrast adjusted to optimize the contrast of the image so that it better meets the needs of visual perception or subsequent defect detection.

[0204] The effect of the above technical solution is: by using the information of the maximum and minimum pixel grayscale before and after adjustment, an accurate contrast compensation coefficient is calculated, thereby achieving accurate adjustment of the image contrast. By adjusting the maximum and minimum grayscale values, it is ensured that the important features in the image are retained during the contrast adjustment process, preventing excessive enhancement or weakening of certain areas. The above technical solution can calculate different contrast compensation coefficients according to the grayscale distribution characteristics of different images, so as to adapt to the contrast adjustment requirements in different scenarios. After the contrast adjustment, the details and features of the image are more prominent, which helps to improve the accuracy and reliability of subsequent printed paper defect detection.

[0205] In summary, the above technical solution achieves the purpose of accurate contrast adjustment of the grayscale image after grayscale adjustment by calculating the contrast compensation coefficient, optimizes the visual effect and feature expression of the image, and provides a better data basis for subsequent defect detection.

[0206] In one embodiment of the present invention, the defect detection module includes:

[0207] An image block extraction module, used to extract an image block of each area to be detected;

[0208] An image feature extraction module, used to extract image features of an image region corresponding to the image block, wherein the image features include texture information, shape information and color information;

[0209] A defect detection and recognition module, used to input the image features into a convolutional neural network model for defect detection to perform defect detection and recognition, and obtain a defect detection result corresponding to each image block;

[0210] The information integration module is used to integrate the defect detection results corresponding to the image blocks of each area to be detected to generate defect detection results corresponding to the target image.

[0211] The working principle of the above technical solution is as follows: This step involves dividing the target image into multiple areas to be detected and extracting corresponding image blocks from these areas. The image block can be the entire area to be detected or a part of the area, depending on the needs of the actual application and the characteristics of the image.

[0212] From each extracted image block, key image features are further extracted. These features include texture information (such as spatial relationships between pixels, repetitive patterns, etc.), shape information (such as edges, contours, etc.) and color information (such as color distribution, color histogram, etc.). These features can reflect the key information in the image block and provide an important basis for subsequent defect detection.

[0213] The extracted image features are input into a pre-trained convolutional neural network model for processing. This model has been trained with a large number of defect samples and can learn the characteristics and patterns of defects. Through the forward propagation of the model, the defect detection results corresponding to each image block can be obtained, such as whether there is a defect, the type and location of the defect, etc.

[0214] Summarize and integrate the defect detection results corresponding to the image blocks of each area to be inspected. This includes merging the detection results of each image block into a complete detection result and processing possible duplicate or contradictory detection results. Finally, generate the overall defect detection result corresponding to the target image.

[0215] The effect of the above technical solution is: by using the convolutional neural network model for defect detection, the efficiency of detection can be significantly improved. The convolutional neural network can automatically learn and extract image features, avoiding the tedious manual feature extraction process in the traditional method. The convolutional neural network model trained with a large number of samples can accurately identify defects and reduce the probability of missed detection and false detection. At the same time, the robustness of detection is enhanced by comprehensively considering multiple features such as texture, shape and color. The above technical solution can adapt to different types of defect detection tasks, and only needs to adjust or retrain the convolutional neural network model. In addition, for images of different sizes and resolutions, the image block extraction method and feature extraction method can also be flexibly adjusted. The entire defect detection and judgment process is automated, reducing the need for manual intervention and improving the reliability and consistency of detection.

[0216] In summary, the above technical solution realizes an efficient, accurate, flexible and automated defect detection process by utilizing a convolutional neural network model and multiple image features for defect detection, which is of great significance for the quality control of products such as printing paper.

[0217] Obviously, those skilled in the art can make various changes and modifications to the present invention without departing from the spirit and scope of the present invention. Thus, if these modifications and variations of the present invention fall within the scope of the claims of the present invention and their equivalents, the present invention is also intended to include these modifications and variations.

Claims

1. A printing paper defect detection method based on machine vision, characterized in that: The printing paper defect detection method comprises: Control the camera installed on the printing paper conveyor belt to collect the image information of each printing paper in real time; Performing image preprocessing on the image information, obtaining preprocessed image information, and using the preprocessed image information as a target image to be identified; Performing region setting for the target image to obtain a plurality of regions to be detected; Perform defect detection and judgment on each to-be-detected area of ​​the target image, and obtain a defect detection result corresponding to the target image; Performing image preprocessing on the image information to obtain preprocessed image information includes: Performing noise reduction processing on the image information by using median filtering, Gaussian filtering or mean filtering to obtain image information after noise reduction processing; Performing grayscale processing on the image information after the noise reduction processing to obtain a grayscale image corresponding to the image information after the noise reduction processing; Performing contrast adjustment on the grayscale image to obtain contrast-adjusted image information, wherein the contrast-adjusted image information is the preprocessed image information; Performing contrast adjustment on the grayscale image to obtain image information after contrast adjustment includes: Retrieve the grayscale value corresponding to each pixel in the grayscale image; Obtaining a grayscale reference value of the grayscale image using the grayscale value corresponding to each pixel in the grayscale image; Compare the grayscale value corresponding to each pixel with the grayscale reference value to obtain the difference between the grayscale value corresponding to each pixel and the grayscale reference value; Obtaining a target grayscale value corresponding to each pixel point by using a difference between the grayscale value corresponding to each pixel point and the grayscale reference value; Adjusting the grayscale of each pixel according to the target grayscale value corresponding to each pixel to obtain a grayscale image after grayscale adjustment; Contrast adjustment is performed on the grayscale image after the grayscale adjustment to obtain image information after the contrast adjustment.

2. The printing paper defect detection method based on machine vision according to claim 1, characterized in that: Performing contrast adjustment on the grayscale image after the grayscale adjustment to obtain image information after the contrast adjustment includes: Retrieving the maximum pixel grayscale value and the corresponding pixel point corresponding to the grayscale image after grayscale adjustment, and taking the pixel point corresponding to the maximum pixel grayscale value as the first marked pixel point; Extracting the grayscale value of the first marked pixel before grayscale adjustment; Obtaining a first contrast compensation coefficient by using the grayscale value of the first marked pixel before grayscale adjustment and the grayscale value after grayscale adjustment; Retrieving the minimum pixel grayscale value and the corresponding pixel point corresponding to the grayscale image after grayscale adjustment, and taking the pixel point corresponding to the minimum pixel grayscale value as the second marked pixel point; Extracting the grayscale value of the second marked pixel before grayscale adjustment; Obtaining a second contrast compensation coefficient by using the grayscale value of the second marked pixel before grayscale adjustment and the grayscale value after grayscale adjustment; Obtaining a target contrast value using the first contrast compensation coefficient and the second contrast compensation coefficient; The contrast of the grayscale image after the grayscale adjustment is adjusted according to the target contrast value to obtain image information after the contrast adjustment.

3. The printing paper defect detection method based on machine vision according to claim 1, characterized in that: Performing defect detection and judgment on each to-be-detected area of ​​the target image to obtain a defect detection result corresponding to the target image includes: Extracting image blocks of each area to be detected; Extracting image features of an image region corresponding to the image block, wherein the image features include texture information, shape information, and color information; Inputting the image features into a convolutional neural network model for defect detection to perform defect detection and identification, and obtaining a defect detection result corresponding to each image block; The defect detection results corresponding to the image blocks of each area to be detected are integrated to generate defect detection results corresponding to the target image.

4. The printing paper defect detection system based on machine vision is characterized by: The printing paper defect detection system comprises: An image acquisition module is used to control the camera installed on the printing paper conveyor belt to acquire the image information of each printing paper in real time; A target image acquisition module is used to perform image preprocessing on the image information, acquire the preprocessed image information, and use the preprocessed image information as the target image to be identified; A partitioning module, used for performing region setting for the target image to obtain multiple regions to be detected; The defect detection module is used to perform defect detection and judgment on each to-be-detected area of ​​the target image, and obtain the defect detection result corresponding to the target image.

5. The printing paper defect detection system based on machine vision according to claim 4, characterized in that: The target image acquisition module comprises: A noise reduction processing module, used to perform noise reduction processing on the image information by using median filtering, Gaussian filtering or mean filtering to obtain image information after noise reduction processing; A grayscale processing module, used to perform grayscale processing on the image information after the noise reduction processing, and obtain a grayscale image corresponding to the image information after the noise reduction processing; The contrast adjustment module is used to perform contrast adjustment on the grayscale image to obtain image information after contrast adjustment, wherein the image information after contrast adjustment is the preprocessed image information.

6. The printing paper defect detection system based on machine vision according to claim 5, characterized in that: The contrast adjustment module comprises: A grayscale value retrieving module, used to retrieve the grayscale value corresponding to each pixel in the grayscale image; A grayscale reference value acquisition module, used to acquire a grayscale reference value of the grayscale image using the grayscale value corresponding to each pixel in the grayscale image; A difference acquisition module, used for comparing the grayscale value corresponding to each pixel with the grayscale reference value, and acquiring the difference between the grayscale value corresponding to each pixel and the grayscale reference value; A target grayscale value acquisition module, used to acquire a target grayscale value corresponding to each pixel point by using a difference between the grayscale value corresponding to each pixel point and the grayscale reference value; A grayscale adjustment execution module, used to adjust the grayscale of each pixel according to the target grayscale value corresponding to each pixel, and obtain a grayscale image after the grayscale adjustment; The contrast adjustment execution module is used to perform contrast adjustment on the grayscale image after the grayscale adjustment to obtain image information after the contrast adjustment.

7. The printing paper defect detection system based on machine vision according to claim 6, characterized in that: The contrast adjustment execution module comprises: A first marking pixel point determination module is used to retrieve the maximum pixel grayscale value and the corresponding pixel point corresponding to the grayscale image after grayscale adjustment, and use the pixel point corresponding to the maximum pixel grayscale value as the first marking pixel point; A first grayscale value extraction module, used to extract the grayscale value of the first marked pixel before grayscale adjustment; A first contrast compensation coefficient acquisition module, used to acquire a first contrast compensation coefficient by using the grayscale value of the first marked pixel before grayscale adjustment and the grayscale value after grayscale adjustment; A second marking pixel point determination module is used to retrieve the minimum pixel grayscale value and the corresponding pixel point corresponding to the grayscale image after grayscale adjustment, and use the pixel point corresponding to the minimum pixel grayscale value as the second marking pixel point; A second grayscale value extraction module, used to extract the grayscale value of the second marked pixel before grayscale adjustment; A second contrast compensation coefficient acquisition module, used to acquire a second contrast compensation coefficient by using the grayscale value of the second marked pixel before grayscale adjustment and the grayscale value after grayscale adjustment; A target contrast value acquisition module, used for acquiring a target contrast value by using the first contrast compensation coefficient and the second contrast compensation coefficient; The adjustment module is used to perform contrast adjustment on the grayscale image after the grayscale adjustment according to the target contrast value to obtain image information after the contrast adjustment.

8. The printing paper defect detection system based on machine vision according to claim 4, characterized in that: The defect detection module comprises: An image block extraction module, used to extract an image block of each area to be detected; An image feature extraction module, used to extract image features of an image region corresponding to the image block, wherein the image features include texture information, shape information and color information; A defect detection and recognition module, used to input the image features into a convolutional neural network model for defect detection to perform defect detection and recognition, and obtain a defect detection result corresponding to each image block; The information integration module is used to integrate the defect detection results corresponding to the image blocks of each area to be detected to generate defect detection results corresponding to the target image.

Citation Information

Patent Citations

  • Strip steel defect detection method based on image recognition

    CN116071316A