Method and device for detecting whether paper is suitable for printing or not and electronic equipment

By analyzing the images after printing a predetermined pattern on the paper, it is determined whether the paper ink absorbs uniformly, and the problem of lack of a method for determining whether the paper is suitable for printing in the prior art is solved, and better printing effect control is achieved.

CN119494831APending Publication Date: 2025-02-21GREE ELECTRIC APPLIANCE INC OF ZHUHAI +1
View PDF 0 Cites 1 Cited by

Patent Information

Application Number
CN202411647893.9
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-11-18
Publication Date
2025-02-21

AI Technical Summary

Technical Problem

There is a lack of a method in the prior art to determine whether the paper is suitable for printing, which makes printing effects difficult to control and problems such as poor printing effects or inappropriate materials.

Method used

By acquiring an image in the case where the ink is not completely dried after the paper is printed with a predetermined pattern, it is determined whether the paper is suitable for printing. Specific steps include pre-processing the image, analyzing the grayscale value difference and variance to determine the ink absorption uniformity and ink dryness.

Benefits of technology

Effective detection of whether paper is suitable for printing is achieved, the problem of lack of such methods in the prior art is solved, and the controllability of printing effects and the user experience of the product is improved.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119494831A_ABST
    Figure CN119494831A_ABST
Patent Text Reader

Abstract

The invention provides a method and device for detecting whether paper is suitable for printing or not and electronic equipment. The method comprises the steps that an image of at least one piece of paper printed with a preset pattern and under the condition that ink is not completely dried is obtained, at least one first image is obtained, and under the condition that the multiple first images are obtained, the paper corresponding to the multiple first images is the same kind of paper; determining whether the paper absorbs ink uniformly according to the at least one first image; according to the method, whether the paper is suitable for printing is determined according to whether the paper absorbs ink uniformly, and whether the paper is not suitable for printing is determined under the condition that the paper absorbs ink non-uniformly, so that the problem that a method for determining whether the paper is suitable for printing is lacked in the prior art is solved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of paper printing, and in particular, to a method for detecting whether paper is suitable for printing, a detection device, a computer-readable storage medium, a processor, an electronic device, and a computer program product. Background Art

[0002] Paper printing is widely used in practice, such as artistic patterns and packaging boxes. Various manufacturers will print the patterns and effects they want according to their needs. The effect of paper printing is not only affected by the printing process, but also by the type of ink and printing paper materials. In particular, there are many kinds of existing paper materials, and they have different fiber structures, which have a huge impact on the drying, ink absorption and clarity of printing.

[0003] In existing printing, demand personnel generally only purchase paper based on the manufacturer's advertisements or technical recommendations. Whether the paper is suitable for printing the corresponding pattern can only be judged by visual inspection and experience. As a result, the quality of the printing effect is difficult to control, resulting in poor printing effects or inappropriate printing materials, which in turn affects the user experience of the product and even produces defective products, resulting in cost waste.

[0004] Therefore, there is an urgent need for a method that can detect whether paper is suitable for printing patterns. Summary of the invention

[0005] The main purpose of the present application is to provide a method, a detection device, a computer-readable storage medium, a processor, an electronic device and a computer program product for detecting whether paper is suitable for printing, so as to at least solve the problem in the prior art of lacking a method for determining whether paper is suitable for printing.

[0006] In order to achieve the above-mentioned purpose, according to one aspect of the present application, a method for detecting whether a paper is suitable for printing is provided, comprising: acquiring an image of at least one paper after a predetermined pattern is printed on the paper and the ink is not completely dry, to obtain at least one first image, and in the case of acquiring multiple first images, the paper corresponding to the multiple first images is the same type of paper; determining whether the paper absorbs ink uniformly according to at least one first image; determining whether the paper is suitable for printing according to whether the paper absorbs ink uniformly, and in the case where the paper absorbs ink unevenly, determining that the paper is not suitable for printing.

[0007] Optionally, determining whether the paper absorbs ink uniformly based on at least one of the first images includes: preprocessing the first image to obtain at least one second image, the preprocessing at least including binarization; obtaining the difference in grayscale values ​​of at least two first inked areas of at least one of the second images to obtain a grayscale difference, and determining that the paper absorbs ink unevenly when there is a grayscale difference that is greater than or equal to a difference threshold; and determining that the paper absorbs ink uniformly when all of the grayscale differences are less than the difference threshold, and that the center lines of the two first inked areas have an angle greater than 0 degrees.

[0008] Optionally, the angle between the center lines of any two of the first ink-containing areas is between 60° and 90°, and the ratio of the area of ​​the intersection between any two of the first ink-containing areas to the area of ​​the corresponding first ink-containing area is less than 1 / 3.

[0009] Optionally, obtaining at least one first image after at least one paper is printed with a predetermined pattern and the ink is not completely dry includes: obtaining multiple images after the paper is printed with a predetermined pattern and the ink is not completely dry, obtaining multiple first images, and the amount of ink corresponding to any two of the papers is different.

[0010] Optionally, determining whether the paper is suitable for printing based on whether the paper absorbs ink evenly includes: when the paper absorbs ink evenly, controlling the acquisition of a third image of the paper to obtain the third image; performing a second preprocessing on the third image to obtain a fourth image; determining whether the ink is evenly dried based on the fourth image, at least determining whether the paper is suitable for printing based on whether the ink is evenly dried, and determining that the paper is not suitable for printing if it is determined that the ink is unevenly dried.

[0011] Optionally, the second preprocessing includes at least grayscale conversion processing, and determining whether the ink is evenly dried based on the fourth image includes: calculating the variance of the grayscale values ​​of at least two second ink-containing areas of the fourth image to obtain at least two variances, and calculating the difference between any two variances to obtain at least one variance difference value, and in the case where there is one variance difference value that is not within a preset range, determining that the ink is unevenly dried, and in the case where all the variance difference values ​​are within the preset range, determining that the ink is evenly dried.

[0012] Optionally, the angle between the center lines of any two of the first ink-containing areas is between 60° and 90°, and the ratio of the area of ​​the intersection between any two of the second ink-containing areas to the area of ​​the corresponding second ink-containing area is less than 1 / 3.

[0013] Optionally, determining whether the paper is suitable for printing is based at least on whether the ink is evenly dried, including: when the ink is evenly dried, controlling the acquisition of a fifth image of the paper to obtain the fifth image; performing a third preprocessing on the fifth image to obtain a sixth image, and determining whether there are burrs on the edges of the printed lines based on the sixth image, and when the burrs exist, obtaining relevant information about the burrs, the relevant information including at least the number of the burrs; determining whether the paper is suitable for printing based on the relevant information, and when at least the number of the burrs is greater than or equal to a quantity threshold, determining that the paper is not suitable for printing.

[0014] Optionally, the third preprocessing includes at least binarization processing, and the relevant information also includes a grayscale value variance sum, the grayscale value variance sum is the sum of the variances of the grayscale values ​​of all burr areas, and the burr area is the smallest area including the burrs. Determining whether the paper is suitable for printing based on the relevant information also includes: when the number of burrs is less than the number threshold and the grayscale value variance sum is less than the sum threshold, determining that the paper is suitable for printing.

[0015] According to another aspect of the present application, a device for detecting whether a paper is suitable for printing is provided, comprising:

[0016] An acquisition unit, which acquires an image of at least one paper after a predetermined pattern is printed and the ink is not completely dried, to obtain at least one first image. When a plurality of the first images are acquired, the papers corresponding to the plurality of the first images are the same paper;

[0017] a first determining unit, for determining whether the paper absorbs ink uniformly according to at least one of the first images;

[0018] The second determination unit determines whether the paper is suitable for printing according to whether the paper absorbs ink uniformly, and determines that the paper is not suitable for printing when the paper absorbs ink unevenly.

[0019] According to another aspect of the present application, a computer-readable storage medium is provided, including: the computer-readable storage medium includes a stored program, wherein when the program is run, the device where the computer-readable storage medium is located is controlled to execute any one of the above-mentioned methods for detecting whether a paper is suitable for printing.

[0020] According to another aspect of the present application, a processor is provided, including: the processor is used to run a program, wherein when the program is run, any one of the above-mentioned methods for detecting whether a paper is suitable for printing is executed.

[0021] According to another aspect of the present application, an electronic device is provided, comprising: one or more processors, a memory, and one or more programs, wherein the one or more programs are stored in the memory and are configured to be executed by the one or more processors, and the one or more programs include a method for detecting whether a paper is suitable for printing as described above.

[0022] According to another aspect of the present application, a computer program product is provided, comprising: a computer program, wherein when the computer program is executed by a processor, the steps of any one of the above methods are implemented.

[0023] By applying the technical solution of the present application, firstly, an image of at least one paper after printing a predetermined pattern and when the ink is not completely dried is obtained to obtain at least one first image. In the case of obtaining multiple first images, the paper corresponding to the multiple first images is the same type of paper; secondly, whether the paper absorbs ink uniformly is determined based on at least one first image; finally, whether the paper is suitable for printing is determined based on whether the paper absorbs ink uniformly. In the case of uneven ink absorption, it is determined that the paper is not suitable for printing. Compared with the prior art, the solution of the present application uses image processing technology to detect the ink absorption of at least the image at the initial moment when the printed pattern is completed. By judging whether the paper absorbs ink uniformly, it is detected whether the paper is suitable for printing the pattern, thereby solving the problem of the lack of a method for determining whether the paper is suitable for printing in the prior art. BRIEF DESCRIPTION OF THE DRAWINGS

[0024] The drawings constituting part of the present application are used to provide a further understanding of the present application. The exemplary embodiments and descriptions of the present application are used to explain the present application and do not constitute an improper limitation on the present application. In the drawings:

[0025] Figure 1 A hardware structure block diagram of a mobile terminal for executing a method for detecting whether paper is suitable for printing provided in an embodiment of the present application is shown;

[0026] Figure 2 A schematic diagram showing a flow chart of a method for detecting whether a paper is suitable for printing according to an embodiment of the present application;

[0027] FIG3( a ) shows a schematic diagram of random arrangement of fibers in a method for detecting whether paper is suitable for printing according to an embodiment of the present application;

[0028] FIG3( b ) shows a schematic diagram of fiber orientation arrangement in a method for detecting whether paper is suitable for printing according to an embodiment of the present application;

[0029] FIG3( c ) shows a schematic diagram of staggered arrangement of fibers in a method for detecting whether paper is suitable for printing according to an embodiment of the present application;

[0030] FIG3( d ) shows a schematic diagram of fiber layer arrangement in a method for detecting whether paper is suitable for printing according to an embodiment of the present application;

[0031] FIG3( e) shows a schematic diagram of a fiber mesh arrangement of a method for detecting whether a paper is suitable for printing according to an embodiment of the present application;

[0032] Figure 4 A schematic diagram of printing ink absorption detection of a method for detecting whether a paper is suitable for printing provided in an embodiment of the present application is shown;

[0033] Figure 5 A schematic diagram of ink drying detection of a method for detecting whether a paper is suitable for printing provided in an embodiment of the present application is shown;

[0034] Figure 6 A schematic diagram of printing clarity detection of a method for detecting whether paper is suitable for printing provided in an embodiment of the present application is shown;

[0035] Figure 7 A main flow chart of a method for detecting whether a paper is suitable for printing according to an embodiment of the present application is shown;

[0036] Figure 8 A structural block diagram of a device for detecting whether a paper is suitable for printing provided in accordance with an embodiment of the present application is shown. DETAILED DESCRIPTION

[0037] It should be noted that, in the absence of conflict, the embodiments and features in the embodiments of the present application can be combined with each other. The present application will be described in detail below with reference to the accompanying drawings and in combination with the embodiments.

[0038] In order to enable those skilled in the art to better understand the solution of the present application, the technical solution in the embodiments of the present application will be clearly and completely described below in conjunction with the drawings in the embodiments of the present application. Obviously, the described embodiments are only part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without creative work should fall within the scope of protection of the present application.

[0039] It should be noted that the terms "first", "second", etc. in the specification and claims of the present application and the above-mentioned drawings are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequential order. It should be understood that the data used in this way can be interchanged where appropriate, so that the embodiments of the present application described here. In addition, the terms "including" and "having" and any of their variations are intended to cover non-exclusive inclusions, for example, a process, method, system, product or device comprising a series of steps or units is not necessarily limited to those steps or units clearly listed, but may include other steps or units that are not clearly listed or inherent to these processes, methods, products or devices.

[0040] As introduced in the background technology, the prior art lacks a method for determining whether paper is suitable for printing. To solve the above problem, the embodiments of the present application provide a method for detecting whether paper is suitable for printing, a detection device, a computer-readable storage medium, a processor, an electronic device and a computer program product.

[0041] The technical solutions in the embodiments of the present invention will be described clearly and completely below in conjunction with the accompanying drawings in the embodiments of the present invention.

[0042] The method embodiments provided in the embodiments of the present application can be executed in a mobile terminal, a computer terminal or a similar computing device. Taking running on a mobile terminal as an example, Figure 1 1 is a hardware structure block diagram of a mobile terminal for detecting whether a paper is suitable for printing according to an embodiment of the present invention. Figure 1 As shown, the mobile terminal may include one or more ( Figure 1 Only one is shown in the figure) a processor 102 (the processor 102 may include but is not limited to a processing device such as a microprocessor MCU or a programmable logic device FPGA) and a memory 104 for storing data, wherein the mobile terminal may also include a transmission device 106 and an input / output device 108 for communication functions. It can be understood by those skilled in the art that Figure 1 The structure shown is only for illustration and does not limit the structure of the mobile terminal. Figure 1 More or fewer components as shown, or with Figure 1 Different configurations are shown.

[0043] The memory 104 can be used to store computer programs, for example, software programs and modules of application software, such as the computer program corresponding to the display method of device information in the embodiment of the present invention. The processor 102 executes various functional applications and data processing by running the computer program stored in the memory 104, that is, the above method is implemented. The memory 104 may include a high-speed random access memory, and may also include a non-volatile memory, such as one or more magnetic storage devices, flash memory, or other non-volatile solid-state memory. In some examples, the memory 104 may further include a memory remotely arranged relative to the processor 102, and these remote memories can be connected to the mobile terminal via a network. Examples of the above-mentioned network include but are not limited to the Internet, an intranet, a local area network, a mobile communication network, and a combination thereof. The transmission device 106 is used to receive or send data via a network. The above-mentioned specific examples of the network may include a wireless network provided by a communication provider of the mobile terminal. In one example, the transmission device 106 includes a network adapter (Network Interface Controller, referred to as NIC), which can be connected to other network devices through a base station so as to communicate with the Internet. In one example, the transmission device 106 may be a radio frequency (RF) module, which is used to communicate with the Internet wirelessly.

[0044] In this embodiment, a method for detecting whether a piece of paper is suitable for printing and is run on a mobile terminal, a computer terminal or a similar computing device is provided. It should be noted that the steps shown in the flowchart of the accompanying drawings can be executed in a computer system such as a set of computer executable instructions, and although a logical order is shown in the flowchart, in some cases, the steps shown or described can be executed in an order different from that shown here.

[0045] Figure 2 FIG. 1 is a flow chart of a method for detecting whether a paper is suitable for printing according to an embodiment of the present application. Figure 2 As shown, the method comprises the following steps:

[0046] Step S201, obtaining an image of at least one paper after a predetermined pattern is printed and the ink is not completely dried, to obtain at least one first image. When multiple first images are obtained, the papers corresponding to the multiple first images are the same type of paper.

[0047] Specifically, the basic steps of printing are to print ink on paper and then wait for it to dry and store. The sampling process is to monitor and sample the status of the printed pattern in real time based on the camera. The sampling can be done by interval sampling. The optimal angle direction for shooting is: the camera shooting direction is facing the printed pattern.

[0048] Specifically, the captured images need to include the following states: the captured images mainly need to include the following states: the picture state just after printing (the printed pattern image within a short time after printing is completed, the short time can be defined according to actual conditions), the printed picture after a specific interval, and the printed picture after complete drying.

[0049] Step S202: determining whether the paper absorbs ink uniformly according to at least one of the first images.

[0050] Specifically, the ink absorbency of paper is closely related to the fiber arrangement of the paper. Paper has a certain fiber structure. According to the different fiber structures, the fiber structure of paper can be divided into: random arrangement as shown in Figure 3(a) (the fibers have no specific direction, and the ink can penetrate evenly), directional arrangement as shown in Figure 3(b) (the fiber arrangement has a direction, and the ink penetrates quickly in the direction of the fiber arrangement and slowly perpendicular to the arrangement direction. Among them, the left picture shows the transverse fibers and the right picture shows the longitudinal fibers), staggered arrangement as shown in Figure 3(c) (the ink can penetrate evenly), layered arrangement as shown in Figure 3(d) (fibers in a certain direction are stacked at a certain angle, and their surface ink absorbency is poor), and mesh arrangement as shown in Figure 3(e) (the ink can penetrate evenly).

[0051] Step S203, determining whether the paper is suitable for printing according to whether the paper absorbs ink uniformly. In the case that the paper absorbs ink unevenly, determining that the paper is not suitable for printing.

[0052] Specifically, in order to ensure the printing effect, printing evaluation is carried out for various types of fiber structures to ensure that the printing ink output is the same, printing is carried out on different papers, the ink absorption after printing is observed, and the most suitable paper type is determined.

[0053] In the above embodiment, first, an image of at least one paper after printing a predetermined pattern and when the ink is not completely dry is obtained to obtain at least one first image. In the case of obtaining multiple first images, the paper corresponding to the multiple first images is the same type of paper; secondly, whether the paper absorbs ink uniformly is determined based on at least one first image; finally, whether the paper is suitable for printing is determined based on whether the paper absorbs ink uniformly. In the case of uneven ink absorption, it is determined that the paper is not suitable for printing. Compared with the prior art, the solution of the present application uses image processing technology to detect the ink absorption of at least the image at the initial moment when the printed pattern is completed. By judging whether the paper absorbs ink uniformly, it is detected whether the paper is suitable for printing the pattern, thereby solving the problem of the lack of a method for determining whether the paper is suitable for printing in the prior art.

[0054] In one embodiment of the present application, determining whether the paper absorbs ink uniformly based on at least one of the first images includes: preprocessing the first image to obtain at least one second image, wherein the preprocessing includes at least binarization; obtaining the difference in grayscale values ​​of at least two first ink-bearing areas of at least one of the second images to obtain a grayscale difference, and determining that the paper absorbs ink unevenly when one of the grayscale differences is greater than or equal to a difference threshold, and determining that the paper absorbs ink uniformly when all of the grayscale differences are less than the difference threshold, and the center lines of the two first ink-bearing areas have an angle greater than 0 degrees. In this method, by preprocessing and analyzing the first image, it is possible to more effectively determine whether the paper absorbs ink uniformly.

[0055] Specifically, basic image preprocessing is performed on the photos after they are taken, such as image binarization and image enhancement. The image preprocessing is not targeted at a specific paper material structure, but only performs image binarization on the taken images and uses histogram equalization to enhance the images. This process will make the printed pattern clearer.

[0056] Specifically, when the paper absorbs ink unevenly, the grayscale value of the image captured in the photo will be uneven. For example, for directional paper, the grayscale value in the fiber arrangement direction and the grayscale value perpendicular to the arrangement will be significantly different. The reason is that the degree of ink absorption is different, and the degree of reflection of the printed pattern will be different. When the ink absorption is uniform, the degree of reflection of the printed part is basically the same. Based on the regional pixel value detection of the printed image, it is judged whether the paper is suitable for actual printing.

[0057] Specifically, in the printed pattern that has just been printed (just completed can be a set time), such as Figure 4 As shown, areas A, B, C, and D are the overall printed patterns, including horizontal, vertical, oblique, and circular graphic areas. Due to the fiber structure, only directional and layered arrangements have uneven ink absorption or poor ink absorption. Gu can collect the horizontal and vertical areas of the printed pattern in each printing paper. Assume Figure 4For paper with a directionally arranged fiber, the fiber direction is vertical, that is, consistent with the direction of the longitudinal area A in the figure. The areas D1 and D2 in the collection area D, D1 is the intersection area of ​​the horizontal sampling rectangle and the circular area D, and the intersection points are d1, d2, d3, and d4; D2 is the intersection area d5 and d6 of the longitudinal sampling rectangle and the circular area D. The horizontal and longitudinal rectangular frames are used for sampling here, which is based on the direction of the directionally arranged fibers, that is, along the arrangement direction of the fibers and perpendicular to the arrangement direction of the fibers, so that the contrast of the ink absorption effect is most obvious, highlighting the contrast effect. In practice, the sampling width of the rectangular frame should not be too large. If the width is too large, it will cause the horizontal and vertical overlapping effects, making the contrast effect not obvious enough. The specific span can be determined according to the actual operation. According to the image brightness measurement algorithm, the grayscale brightness of regions D1 and D2 is measured. Assuming that the overall grayscale (brightness) value of D1 is L_D1, and the grayscale value of D2 is L_D2, if L_D1≠L_D2, it means that the directional arrangement of paper has a greater impact on this printing, and the directional paper cannot be selected. If L_D1=L_D2, it means that the directional paper is also suitable for this printing. The difference threshold in this embodiment is equal to 0, and the difference threshold can also be set according to actual conditions. At the same time, the same detection is performed on the papers arranged randomly, staggered, meshed, and layered, and their grayscale values ​​are L_R, L_C, L_N, and L_F respectively. If L_F is the largest (the layered arrangement has poor ink absorption and high reflective brightness), it means that the layered arrangement paper is not suitable for this printing, otherwise the layered arrangement paper is also suitable for printing. In this example, it can be recorded whether the paper has inconsistent ink absorption, and the brightness value of the printed pattern of each paper sampling area can be recorded simultaneously.

[0058] Specifically, the above operations are all carried out to test the ink absorbency of paper under the condition of the same ink. In order to achieve better detection effect, the amount of printing ink can be changed as needed to verify the printing effect of different amounts of ink on various paper types. The specific increase or decrease does not have a fixed standard and can also be determined according to actual needs.

[0059] In order to make the ink absorption detection more accurate, in one embodiment of the present application, the angle between the center lines of any two of the above-mentioned first ink-containing areas is between 60° and 90°, and the ratio of the area of ​​the intersection area between any two of the above-mentioned first ink-containing areas to the area of ​​the corresponding first ink-containing area is less than 1 / 3.

[0060] In another embodiment, obtaining at least one image of a paper after printing a predetermined pattern and when the ink is not completely dried, to obtain at least one first image, includes: obtaining multiple images of the paper after printing the predetermined pattern and when the ink is not completely dried, to obtain multiple first images, wherein the ink amounts corresponding to any two of the paper are different. In this method, by obtaining multiple images of printing that are not completely dried, the ink absorbency of the paper and the drying property of the ink are further detected.

[0061] Specifically, for the description of paper with different types of fiber arrangements, the drying state of the paper can be detected by collecting images of the printed pattern at specific intervals after printing. According to common ink printing, the drying time is from a few seconds to a few minutes, and the selected interval time can be, for example, 10 seconds for image collection. As long as the interval time is within the drying time range, it is theoretically feasible. The specific interval time can be determined according to actual conditions, and the printed pictures after the specific interval time can theoretically be taken after multiple specific intervals and multiple photos, so that the comparison effect will be more obvious, but there is at least one photo. At the same time, the influence of the choice of drying time on the detection results is that if the selected time is too long, the intermediate drying process will be lost, resulting in inaccurate or even misaligned results of the drying comparison of various types of paper; if the selected time is too short, too many images will be sampled, which will increase the calculation task, but the detection result will be more accurate.

[0062] Specifically, for multiple papers with the same type of fiber arrangement, the same amount of ink is used for testing to obtain ink absorbency test result 1 for the same paper type; for multiple papers with different types of fiber arrangements, different amounts of ink are used for testing to obtain ink absorbency test result 2 for different paper types; at the same time, the same amount of ink is set for multiple papers with different types of fiber arrangements, so as to obtain ink absorbency test result 3 for different paper types, and test result 1, test result 2 and test result 3 are summarized to ensure that the test results are more accurate.

[0063] In order to more effectively screen out paper suitable for printing, in one embodiment of the present application, whether the paper is suitable for printing is determined based on whether the paper absorbs ink evenly, including: when the paper absorbs ink evenly, controlling the acquisition of a third image of the paper to obtain the third image; performing a second preprocessing on the third image to obtain a fourth image; determining whether the ink is evenly dried based on the fourth image, at least determining whether the paper is suitable for printing based on whether the ink is evenly dried, and when it is determined that the ink is unevenly dried, determining that the paper is not suitable for printing.

[0064] Specifically, for printed images taken at certain intervals, a specific amount of ink is limited, and drying detection is performed on the printed pattern of each paper in order to detect the absorption state of the ink after printing and the saturation of the print. In theory, the shorter the interval detection time is, the better, because the shorter the time, the more details of the intermediate drying process can be obtained. However, the shorter the time, the more image sampling will be.

[0065] Specifically, the speed of drying can be reflected from the ink absorption time. When the ink is evenly absorbed, the pixel values ​​of the printed pattern are uniform. Another evaluation index of drying is the saturation of the printed pattern. The higher the saturation, the higher the pixel value of the printed pattern. For color detection, conventional color calculation algorithms can be used, such as combining color space conversion with grayscale calculation.

[0066] Specifically, image binarization is adopted to extract the undried printed pattern area according to the image binarization threshold, wherein the image binarization threshold is set according to the actual situation; pixel statistics are adopted to calculate the undried printed pattern area to obtain the area of ​​the undried printed area; and the drying speed is determined according to the size of the area.

[0067] In another embodiment, the second preprocessing includes at least grayscale conversion processing, namely, averaging method and weighted averaging method, and determining whether the ink is evenly dried according to the fourth image includes: calculating the variance of the grayscale values ​​of at least two second ink-containing areas of the fourth image to obtain at least two variances, and calculating the difference between any two variances to obtain at least one variance difference, and determining that the ink is unevenly dried when one of the variance differences is not within the preset range, and determining that the ink is evenly dried when all the variance differences are within the preset range. In this method, by judging whether the variance difference is within the preset range, it is further determined whether the ink is evenly dried.

[0068] Specifically, saturation is used to distinguish the vividness of the image after printing. The higher the saturation, the more vivid the image. To calculate the saturation, it is necessary to calculate it once after the fourth image has completely dried to clarify the saturation of the printed pattern. After the printed pattern is completely dried, the cvtColor method of OpenCv is used to convert the RGB image of the third image into the HSV color space, extract the saturation of the second channel of the HSV color space (i.e., the saturation channel, which has many saturation values), and finally calculate the average saturation in the saturation channel. This average value reflects the final saturation of the pattern.

[0069] Specifically, Figure 5 As shown, assuming that printing is performed on paper with directional fiber arrangement (in this embodiment, horizontal, as shown by the arrow in the figure), it is necessary to specifically detect the uniformity of the pixel values ​​of the horizontal area A, the oblique area C, and the vertical area B. Because the fiber direction is horizontal, horizontal printing dries faster and the regional pixels are uniform, as shown in FIG. Figure 5 In the horizontal printing pattern in area A, there is a clear light spot in the vertical direction, and there is unabsorbed ink, such as Figure 5 The M point in the figure indicates that the ink is not completely absorbed, and the absorption speeds in the longitudinal direction and the oblique direction (generally referred to as non-lateral direction) are inconsistent, resulting in uneven pixels in the regional pattern, such as Figure 5The middle point L indicates uneven ink absorption. The method is based on pixel value detection and uniformity judgment based on variance. The size of the light spot area can be calculated simultaneously to illustrate the size of the ink undried area. Similarly, the same judgment is made for papers with other fiber arrangements. It should be noted that when uneven pixels are detected, the same judgment can be made after a certain interval. If uneven pixels still exist, the paper is judged to be unsuitable. The corresponding pixel uniformity detection results at the interval time are recorded, which can be the size of the light spot area and the pixel value (brightness), to illustrate whether there is a non-drying area at each time interval and the degree of non-drying.

[0070] Specifically, the drying time and ink absorbency are interrelated to a certain extent. Ink absorbency is tested in a short time to preliminarily determine whether the printed paper is suitable, while the drying test is to detect the drying process of the paper and finally verify whether the printing is uniform (spot) after drying.

[0071] In order to more effectively detect the dryness of the ink, in one embodiment of the present application, the angle between the center lines of any two of the above-mentioned first ink-containing areas is between 60° and 90°, and the ratio of the area of ​​the intersection area between any two of the above-mentioned second ink-containing areas to the area of ​​the corresponding second ink-containing areas is less than 1 / 3.

[0072] In another embodiment, whether the paper is suitable for printing is determined at least based on whether the ink is evenly dried, including: when the ink is evenly dried, controlling the acquisition of a fifth image of the paper to obtain the fifth image; performing a third preprocessing on the fifth image to obtain a sixth image, and determining whether there are burrs on the edge of the printed line based on the sixth image, and when there are burrs, obtaining relevant information about the burrs, the relevant information at least including the number of the burrs; determining whether the paper is suitable for printing based on the relevant information, and determining that the paper is not suitable for printing when at least the number of the burrs is greater than or equal to a threshold value. In this method, by acquiring and analyzing images of paper with evenly dried ink, and by comparing the number of burrs with a threshold value, it is further determined whether the paper is suitable for printing.

[0073] Specifically, for the printed image after it is completely dried, the clarity of the printing is mainly aimed at the edge contour details after the ink diffuses. It can be seen from the actual printing that after printing is completed, the ink at the edge of the printed pattern will diffuse. When diffusion occurs, the amount of ink in the diffused part will become less and less as the diffusion proceeds, that is, visually the color of the diffused part extending outward becomes lighter and lighter. This phenomenon is the burrs caused by the above-mentioned divergence.

[0074] Specifically, according to the paper fiber structure type, the logic of sampling horizontal and vertical rectangular frame patterns of horizontal printing, vertical printing and other printing can also be used in the clarity detection, that is, Figure 4 As shown, the contour of the selected image is detected, and the contour position of the image is extracted according to the edge detection algorithm of image processing. When the printing is not clear enough or the ink diverges, the edge of the printed line will have burrs, and the burr points come from the divergence of the ink, and the pixel values ​​of the burr points are different.

[0075] In order to further determine whether the paper is suitable for printing, in one embodiment of the present application, the above-mentioned third preprocessing includes at least binarization processing, and the above-mentioned relevant information also includes the sum of grayscale value variances, the above-mentioned sum of grayscale value variances is the sum of the variances of the grayscale values ​​of all burr areas, and the above-mentioned burr area is the smallest area including the above-mentioned burrs. Determining whether the above-mentioned paper is suitable for printing based on the above-mentioned relevant information also includes: when the number of the above-mentioned burrs is less than the above-mentioned number threshold and the above-mentioned sum of grayscale value variances is less than the sum threshold, determining that the above-mentioned paper is suitable for printing.

[0076] Specifically, Figure 6 As shown in the figure, the details of the enlarged contour line A are shown in the figure. By detecting the detail points on A and applying the image processing closing and opening operations, the burr parts on the contour can be extracted, such as X, Y, Z, etc. As the ink diverges, the burrs are generated, and the pixel values ​​of the burr parts are not uniform. The grayscale calculation is used to calculate the pixel values ​​of each point in the X, Y, and Z regions, and the variance is used to calculate whether the pixels in each region are uniform. When the variance value exceeds the actual set threshold, it means that the printing is not clear and there are indeed burr points. According to the above detection, burr detection is performed on various types of paper with different fiber structures, and the number of burr points detected and the sum of the variance values ​​are recorded. It is explained here that the number of burr points reflects the number of unclear details, and the sum of the variances reflects the degree of printing diffusion.

[0077] Specifically, the color of the pattern that is diffused (diverged) is getting lighter and lighter. On the technical level, the amount of ink in the diffused part of the pattern is uneven, that is, the grayscale values ​​are different. When multiple burr areas are extracted using open and close operations (existing technology), the variance of the grayscale values ​​of the pixels in the burr area is calculated. Theoretically, when the variance is 0, it means that the pixels are uniform and there is no divergence. The larger the variance, the greater the degree of divergence and the larger the area of ​​ink extension. The variance of all divergent areas is calculated, and then the sum of the variances is calculated. The larger the sum of the variances, the greater the degree of overall printing diffusion.

[0078] Specifically, the variance calculation is for the burr area, and the variance of the grayscale values ​​of all pixels in the area is calculated. The number of burr points is not necessarily related to the area. In theory, the more burr areas there are, the more areas the image diverges, but the number of burr points is not necessarily more.

[0079] Specifically, for each type of test, a certain amount of printing ink is set to increase the data control set each time, and the data of each test result is counted, as shown in Table 1.

[0080] Table 1

[0081]

[0082] The parameters of drying test can be summarized as blanks in the printing effect table as items to be filled in. In addition, the demand personnel can also combine the quality of paper (strength, progress, etc.) and the price of paper, and make a trade-off based on factors such as "printing effect", "paper quality" and "paper price". The trade-off method depends on the actual demand, such as conventional data fitting methods.

[0083] Specifically, all kinds of tests are aimed at ink spraying on paper materials. If it is expanded to wood spraying, leather spraying and even metal spraying, it will involve the absorption and drying of the paint. In addition to the need for horizontal and vertical sampling tests for directional and layered fibers, the other detection logic is basically the same in theory. As for whether there is a fiber structure texture in wood and leather spraying, the difference lies in the design of specific sampling according to the structure texture, such as sampling and analysis along the direction of the wood or leather texture and in the vertical direction.

[0084] In order to enable those skilled in the art to more clearly understand the technical solution of the present application, the implementation process of the method for detecting whether paper is suitable for printing of the present application will be described in detail below in conjunction with specific embodiments.

[0085] This embodiment relates to a specific method for detecting whether paper is suitable for printing, comprising the following steps:

[0086] start;

[0087] Set the amount of ink for printing;

[0088] Taking an image of a newly printed pattern to obtain a first image;

[0089] Performing ink absorption detection on the first image: preprocessing the first image to obtain a second image, and calculating the difference in grayscale values ​​of two first ink-containing areas in the second image, and comparing the difference with a difference threshold, thereby performing ink absorption detection on the paper;

[0090] When the paper absorbs ink uniformly, images of the printed pattern are photographed at intervals of a specific length to obtain a third image;

[0091] Performing ink drying detection on the third image: preprocessing the third image to obtain a fourth image, calculating the difference in the variance of the grayscale values ​​of the two second ink-containing regions of the fourth image, and comparing the difference with a difference threshold, thereby performing ink drying detection;

[0092] When the ink is evenly dried, an image of the printed pattern after drying is captured to obtain a fifth image;

[0093] Performing clarity detection on the fifth image: preprocessing the fifth image to obtain a sixth image, calculating the number of burrs in the sixth image and the variance of the grayscale value of the burrs, and comparing the sum of the variances with a threshold value, thereby performing clarity detection;

[0094] Recording the test result data, wherein the result data includes data related to ink absorption, drying and clarity;

[0095] Determine whether to continue testing. If yes, change the amount of printing ink and repeat the above steps. If no, select the appropriate type of paper and end the process.

[0096] The main process of this process is as follows Figure 7 shown.

[0097] It should be noted that the steps shown in the flowcharts of the accompanying drawings can be executed in a computer system such as a set of computer executable instructions, and that, although a logical order is shown in the flowcharts, in some cases, the steps shown or described can be executed in an order different from that shown here.

[0098] The embodiment of the present application also provides a device for detecting whether a paper is suitable for printing. It should be noted that the device for detecting whether a paper is suitable for printing in the embodiment of the present application can be used to execute the detection method for whether a paper is suitable for printing provided in the embodiment of the present application. The device is used to implement the above-mentioned embodiments and preferred implementation modes, and the descriptions that have been made will not be repeated. As used below, the term "module" can implement a combination of software and / or hardware for a predetermined function. Although the device described in the following embodiments is preferably implemented in software, the implementation of hardware, or a combination of software and hardware, is also possible and conceived.

[0099] The following is an introduction to a device for detecting whether a paper is suitable for printing provided in an embodiment of the present application.

[0100] Figure 8 Schematic diagram of a device for detecting whether paper is suitable for printing according to an embodiment of the present application. Figure 8 As shown, the device comprises:

[0101] The acquisition unit 10 acquires an image of at least one paper after a predetermined pattern is printed and the ink is not completely dried, and obtains at least one first image. When multiple first images are acquired, the papers corresponding to the multiple first images are the same paper.

[0102] Specifically, the basic steps of printing are to print ink on paper and then wait for it to dry and store. The sampling process is to monitor and sample the status of the printed pattern in real time based on the camera. The sampling can be done by interval sampling. The optimal angle direction for shooting is: the camera shooting direction is facing the printed pattern.

[0103] Specifically, the captured images need to include the following states: the captured images mainly need to include the following states: the picture state just after printing (the printed pattern image within a short time after printing is completed, the short time can be defined according to actual conditions), the printed picture after a specific interval, and the printed picture after complete drying.

[0104] The first determination unit 20 determines whether the paper absorbs ink uniformly according to at least one of the first images.

[0105] Specifically, the ink absorbency of paper is closely related to the fiber arrangement of the paper. Paper has a certain fiber structure. According to the different fiber structures, the fiber structure of paper can be divided into: random arrangement (the fibers have no specific direction, and the ink can penetrate evenly), directional arrangement (the fiber arrangement has a direction, and the ink penetrates quickly in the direction of the fiber arrangement and slowly perpendicular to the arrangement direction), staggered arrangement (the ink can penetrate evenly), layered arrangement (fibers in a certain direction are stacked at a certain angle, and their surface ink absorbency is poor), and mesh arrangement (the ink can penetrate evenly).

[0106] The second determination unit 30 determines whether the paper is suitable for printing according to whether the paper absorbs ink uniformly. If the paper absorbs ink unevenly, the second determination unit 30 determines that the paper is not suitable for printing.

[0107] Specifically, in order to ensure the printing effect, printing evaluation is carried out for various types of fiber structures to ensure that the printing ink output is the same, printing is carried out on different papers, the ink absorption after printing is observed, and the most suitable paper type is determined.

[0108] In the above embodiment, first, an image of at least one paper after printing a predetermined pattern and when the ink is not completely dry is obtained to obtain at least one first image. In the case of obtaining multiple first images, the paper corresponding to the multiple first images is the same type of paper; secondly, whether the paper absorbs ink uniformly is determined based on at least one first image; finally, whether the paper is suitable for printing is determined based on whether the paper absorbs ink uniformly. In the case of uneven ink absorption, it is determined that the paper is not suitable for printing. Compared with the prior art, the solution of the present application uses image processing technology to detect the ink absorption of at least the image at the initial moment when the printed pattern is completed. By judging whether the paper absorbs ink uniformly, it is detected whether the paper is suitable for printing the pattern, thereby solving the problem of the lack of a method for determining whether the paper is suitable for printing in the prior art.

[0109] In one embodiment of the present application, the first determination unit includes a first preprocessing subunit and an acquisition subunit, wherein the first preprocessing subunit is used to preprocess the first image to obtain at least one second image, wherein the preprocessing at least includes binarization; the acquisition subunit is used to obtain the difference in grayscale values ​​of at least two first ink-bearing areas of at least one second image to obtain a grayscale difference, and when there is a grayscale difference greater than or equal to a difference threshold, it is determined that the paper absorbs ink unevenly, and when all the grayscale differences are less than the difference threshold, it is determined that the paper absorbs ink evenly, and the center lines of the two first ink-bearing areas have an angle greater than 0 degrees. In this solution, by preprocessing and analyzing the first image, it can be more effectively determined whether the paper absorbs ink evenly.

[0110] Specifically, basic image preprocessing is performed on the photos after they are taken, such as image binarization and image enhancement. The image preprocessing is not targeted at a specific paper material structure, but only performs image binarization on the taken images and uses histogram equalization to enhance the images. This process will make the printed pattern clearer.

[0111] Specifically, when the paper absorbs ink unevenly, the grayscale value of the image captured in the photo will be uneven. For example, for directional paper, the grayscale value in the fiber arrangement direction and the grayscale value perpendicular to the arrangement will be significantly different. The reason is that the degree of ink absorption is different, and the degree of reflection of the printed pattern will be different. When the ink absorption is uniform, the degree of reflection of the printed part is basically the same. Based on the regional pixel value detection of the printed image, it is judged whether the paper is suitable for actual printing.

[0112] Specifically, the above operations are all carried out to test the ink absorbency of paper under the condition of the same ink. In order to achieve better detection effect, the amount of printing ink can be changed as needed to verify the printing effect of different amounts of ink on various paper types. The specific increase or decrease does not have a fixed standard and can also be determined according to actual needs.

[0113] In order to make the ink absorbency detection more accurate, in one embodiment of the present application, at least two of the above-mentioned first ink-containing areas include a first transverse ink-containing area and a first longitudinal ink-containing area, and the ratio of the area of ​​the intersection area between any two of the above-mentioned first ink-containing areas to the area of ​​the corresponding first ink-containing area is less than 1 / 3.

[0114] In another embodiment, the acquisition subunit includes an acquisition module, wherein the acquisition module is used to acquire images of a plurality of the above-mentioned papers after the predetermined pattern is printed and the ink is not completely dried, to obtain a plurality of the above-mentioned first images, and the ink amounts corresponding to any two of the above-mentioned papers are different. In this solution, by obtaining a plurality of images of the printing that are not completely dried, the ink absorption of the paper and the drying property of the ink are further detected.

[0115] Specifically, for the description of paper with different types of fiber arrangements, the drying state of the paper can be detected by collecting images of the printed pattern at specific intervals after printing. According to common ink printing, the drying time is from a few seconds to a few minutes, and the selected interval time can be, for example, 10 seconds for image collection. As long as the interval time is within the drying time range, it is theoretically feasible. The specific interval time can be determined according to actual conditions, and the printed pictures after the specific interval time can theoretically be taken after multiple specific intervals and multiple photos, so that the comparison effect will be more obvious, but there is at least one photo. At the same time, the influence of the choice of drying time on the detection results is that if the selected time is too long, the intermediate drying process will be lost, resulting in inaccurate or even misaligned results of the drying comparison of various types of paper; if the selected time is too short, too many images will be sampled, which will increase the calculation task, but the detection result will be more accurate.

[0116] Specifically, for multiple papers with the same type of fiber arrangement, the same amount of ink is used for testing to obtain ink absorbency test result 1 for the same paper type; for multiple papers with different types of fiber arrangements, different amounts of ink are used for testing to obtain ink absorbency test result 2 for different paper types; at the same time, the same amount of ink is set for multiple papers with different types of fiber arrangements, so as to obtain ink absorbency test result 3 for different paper types, and test result 1, test result 2 and test result 3 are summarized to ensure that the test results are more accurate.

[0117] In order to more effectively screen out paper suitable for printing, in one embodiment of the present application, the second determination unit includes a control subunit, a second preprocessing subunit and a determination subunit, wherein the control subunit is used to control the acquisition of a third image of the paper to obtain the third image when the paper absorbs ink evenly; the second preprocessing subunit is used to perform a second preprocessing on the third image to obtain a fourth image; the determination subunit is used to determine whether the ink is evenly dried according to the fourth image, at least determine whether the paper is suitable for printing based on whether the ink is evenly dried, and determine that the paper is not suitable for printing when it is determined that the ink is unevenly dried.

[0118] Specifically, for printed images taken at certain intervals, a specific amount of ink is limited, and drying detection is performed on the printed pattern of each paper in order to detect the absorption state of the ink after printing and the saturation of the print. In theory, the shorter the interval detection time is, the better, because the shorter the time, the more details of the intermediate drying process can be obtained. However, the shorter the time, the more image sampling will be.

[0119] Specifically, the speed of drying can be reflected from the ink absorption time. When the ink is evenly absorbed, the pixel values ​​of the printed pattern are uniform. Another evaluation index of drying is the saturation of the printed pattern. The higher the saturation, the higher the pixel value of the printed pattern. For color detection, conventional color calculation algorithms can be used, such as combining color space conversion with grayscale calculation.

[0120] Specifically, image binarization is adopted to extract the undried printed pattern area according to the image binarization threshold, wherein the image binarization threshold is set according to the actual situation; pixel statistics are adopted to calculate the undried printed pattern area to obtain the area of ​​the undried printed area; and the drying speed is determined according to the size of the area.

[0121] In another embodiment, the second preprocessing at least includes grayscale conversion processing, namely, averaging method and weighted averaging method, and the determination subunit includes a calculation module, wherein the calculation module is used to calculate the variance of the grayscale values ​​of at least two second ink-containing areas of the fourth image to obtain at least two of the above-mentioned variances, and calculate the difference between any two of the above-mentioned variances to obtain at least one variance difference value, and when there is one of the above-mentioned variance difference values ​​that is not within the preset range, it is determined that the above-mentioned ink is unevenly dried, and when all of the above-mentioned variance difference values ​​are within the preset range, it is determined that the above-mentioned ink is uniformly dried. In this solution, by judging whether the variance difference value is within the preset range, it is further determined whether the ink is uniformly dried.

[0122] Specifically, saturation is used to distinguish the vividness of the image after printing. The higher the saturation, the more vivid the image. To calculate the saturation, it is necessary to calculate it once after the fourth image has completely dried to clarify the saturation of the printed pattern. After the printed pattern is completely dried, the cvtColor method of OpenCv is used to convert the RGB image of the third image into the HSV color space, extract the saturation of the second channel of the HSV color space (i.e., the saturation channel, which has many saturation values), and finally calculate the average saturation in the saturation channel. This average value reflects the final saturation of the pattern.

[0123] Specifically, the drying time and ink absorbency are interrelated to a certain extent. Ink absorbency is tested in a short time to preliminarily determine whether the printed paper is suitable, while the drying test is to detect the drying process of the paper and finally verify whether the printing is uniform (spot) after drying.

[0124] In order to more effectively detect the dryness of the ink, in one embodiment of the present application, the angle between the center lines of any two of the above-mentioned first ink-containing areas is between 60° and 90°, and the ratio of the area of ​​the intersection area between any two of the above-mentioned second ink-containing areas to the area of ​​the corresponding second ink-containing areas is less than 1 / 3.

[0125] In another embodiment, the determination subunit includes a control module, a preprocessing module and a determination module, wherein the control module is used to control the acquisition of the fifth image of the paper when the ink is evenly dried to obtain the fifth image; the preprocessing module is used to perform a third preprocessing on the fifth image to obtain a sixth image, and determine whether there are burrs on the edge of the printed line according to the sixth image, and obtain relevant information about the burrs when the burrs exist, and the relevant information at least includes the number of the burrs; the determination module is used to determine whether the paper is suitable for printing according to the relevant information, and determine that the paper is not suitable for printing when at least the number of the burrs is greater than or equal to the number threshold. In this solution, by performing image acquisition and analysis on the paper with evenly dried ink, and by comparing the number of burrs with the threshold, it is further determined whether the paper is suitable for printing.

[0126] Specifically, for the printed image after it is completely dried, the clarity of the printing is mainly aimed at the edge contour details after the ink diffuses. It can be seen from the actual printing that after printing is completed, the ink at the edge of the printed pattern will diffuse. When diffusion occurs, the amount of ink in the diffused part will become less and less as the diffusion proceeds, that is, visually the color of the diffused part extending outward becomes lighter and lighter. This phenomenon is the burrs caused by the above-mentioned divergence.

[0127] Specifically, according to the type of paper fiber structure, the logic of sampling horizontal and vertical rectangular frame patterns of horizontal printing, vertical printing and other printings can also be used in clarity detection to detect the contour of the selected image, and extract the contour position of the image according to the edge detection algorithm of image processing. When the printing is not clear enough or the ink diverges, the edge of the printed line will have burrs, and the burr points are caused by the divergence of ink, and the pixel values ​​of the burr points are different.

[0128] In order to further determine whether the paper is suitable for printing, in one embodiment of the present application, the above-mentioned third preprocessing includes at least binarization processing, and the above-mentioned relevant information also includes the sum of grayscale value variances, the above-mentioned sum of grayscale value variances is the sum of the variances of the grayscale values ​​of all burr areas, and the above-mentioned burr area is the smallest area including the above-mentioned burrs. The determination module also includes a determination submodule, wherein the determination submodule is used to determine that the above-mentioned paper is suitable for printing when the number of the above-mentioned burrs is less than the above-mentioned number threshold and the above-mentioned sum of grayscale value variances is less than the sum threshold.

[0129] Specifically, the color of the pattern that is diffused (diverged) is getting lighter and lighter. On the technical level, the amount of ink in the diffused part of the pattern is uneven, that is, the grayscale values ​​are different. When multiple burr areas are extracted using open and close operations (existing technology), the variance of the grayscale values ​​of the pixels in the burr area is calculated. Theoretically, when the variance is 0, it means that the pixels are uniform and there is no divergence. The larger the variance, the greater the degree of divergence and the larger the area of ​​ink extension. The variance of all divergent areas is calculated, and then the sum of the variances is calculated. The larger the sum of the variances, the greater the degree of overall printing diffusion.

[0130] Specifically, the variance calculation is for the burr area, and the variance of the grayscale values ​​of all pixels in the area is calculated. The number of burr points is not necessarily related to the area. In theory, the more burr areas there are, the more areas the image diverges, but the number of burr points is not necessarily more.

[0131] Specifically, for each type of test, a certain amount of printing ink is set each time to increase the data control set, and the data of each test result is counted. The parameters of the drying test can be comprehensively summarized as the printing effect. In addition, the demand personnel can also collect the quality of the paper (strength, progress, etc.) and the price of the paper, and make a trade-off based on factors such as "printing effect", "paper quality" and "paper price". The method of weighing depends on the actual demand, such as the conventional data fitting method.

[0132] Specifically, all kinds of tests are aimed at ink spraying on paper materials. If it is expanded to wood spraying, leather spraying and even metal spraying, it will involve the absorption and drying of the paint. In addition to the need for horizontal and vertical sampling tests for directional and layered fibers, the other detection logic is basically the same in theory. As for whether there is a fiber structure texture in wood and leather spraying, the difference lies in the design of specific sampling according to the structure texture, such as sampling and analysis along the direction of the wood or leather texture and in the vertical direction.

[0133] The device for detecting whether paper is suitable for printing comprises a processor and a memory, wherein the acquisition unit, the first determination unit, the second determination unit, etc. are stored in the memory as program units, and the processor executes the program units stored in the memory to realize corresponding functions. The modules are all located in the same processor; or, the modules are located in different processors in any combination.

[0134] The processor includes a kernel, which retrieves the corresponding program unit from the memory. One or more kernels can be set to detect whether the paper is suitable for printing by adjusting the kernel parameters.

[0135] The memory may include non-permanent memory in a computer-readable medium, random access memory (RAM) and / or non-volatile memory, such as read-only memory (ROM) or flash RAM, and the memory includes at least one memory chip.

[0136] An embodiment of the present invention provides a computer-readable storage medium, wherein the computer-readable storage medium includes a stored program, wherein when the program is executed, the device where the computer-readable storage medium is located is controlled to execute the method for detecting whether the paper is suitable for printing, the method comprising:

[0137] Step S201, obtaining an image of at least one paper after a predetermined pattern is printed and the ink is not completely dried, to obtain at least one first image. When multiple first images are obtained, the papers corresponding to the multiple first images are the same type of paper.

[0138] Step S202: determining whether the paper absorbs ink uniformly according to at least one of the first images.

[0139] Step S203, determining whether the paper is suitable for printing according to whether the paper absorbs ink uniformly. In the case that the paper absorbs ink unevenly, determining that the paper is not suitable for printing.

[0140] An embodiment of the present invention provides a processor, the processor is used to run a program, wherein when the program is run, a method for detecting whether the paper is suitable for printing is executed, the method comprising:

[0141] Step S201, obtaining an image of at least one paper after a predetermined pattern is printed and the ink is not completely dried, to obtain at least one first image. When multiple first images are obtained, the papers corresponding to the multiple first images are the same type of paper.

[0142] Step S202: determining whether the paper absorbs ink uniformly according to at least one of the first images.

[0143] Step S203, determining whether the paper is suitable for printing according to whether the paper absorbs ink uniformly. In the case that the paper absorbs ink unevenly, determining that the paper is not suitable for printing.

[0144] An embodiment of the present invention provides a device, the device including a processor, a memory, and a program stored in the memory and executable on the processor, and when the processor executes the program, at least the following steps are implemented:

[0145] Step S201, obtaining an image of at least one paper after a predetermined pattern is printed and the ink is not completely dried, to obtain at least one first image. When multiple first images are obtained, the papers corresponding to the multiple first images are the same type of paper.

[0146] Step S202: determining whether the paper absorbs ink uniformly according to at least one of the first images.

[0147] Step S203, determining whether the paper is suitable for printing according to whether the paper absorbs ink uniformly. In the case that the paper absorbs ink unevenly, determining that the paper is not suitable for printing.

[0148] The devices in this article can be servers, PCs, PADs, mobile phones, etc.

[0149] The present application also provides a computer program product, which, when executed on a data processing device, is suitable for executing a program for initializing at least the following method steps:

[0150] Step S201, obtaining an image of at least one paper after a predetermined pattern is printed and the ink is not completely dried, to obtain at least one first image. When multiple first images are obtained, the papers corresponding to the multiple first images are the same type of paper.

[0151] Step S202: determining whether the paper absorbs ink uniformly according to at least one of the first images.

[0152] Step S203, determining whether the paper is suitable for printing according to whether the paper absorbs ink uniformly. In the case that the paper absorbs ink unevenly, determining that the paper is not suitable for printing.

[0153] Obviously, those skilled in the art should understand that the above modules or steps of the present invention can be implemented by a general computing device, they can be concentrated on a single computing device, or distributed on a network composed of multiple computing devices, they can be implemented by a program code executable by a computing device, so that they can be stored in a storage device and executed by the computing device, and in some cases, the steps shown or described can be executed in a different order than here, or they can be made into individual integrated circuit modules, or multiple modules or steps therein can be made into a single integrated circuit module for implementation. Thus, the present invention is not limited to any specific combination of hardware and software.

[0154] Those skilled in the art will appreciate that the embodiments of the present application may be provided as methods, systems, or computer program products. Therefore, the present application may adopt the form of a complete hardware embodiment, a complete software embodiment, or an embodiment in combination with software and hardware. Moreover, the present application may adopt the form of a computer program product implemented in one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) that include computer-usable program code.

[0155] The present application is described with reference to the flowcharts and / or block diagrams of the methods, devices (systems), and computer program products according to the embodiments of the present application. It should be understood that each process and / or box in the flowchart and / or block diagram, as well as the combination of the processes and / or boxes in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing device to generate a machine, so that the instructions executed by the processor of the computer or other programmable data processing device generate instructions for implementing the processes in the flowchart and / or block diagram. Figure 1 A process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in a block or multiple blocks.

[0156] These computer program instructions may also be stored in a computer-readable memory capable of directing a computer or other programmable data processing device to operate in a specific manner, so that the instructions stored in the computer-readable memory produce an article of manufacture comprising an instruction device, which implements the process Figure 1 A process or multiple processes and / or boxes Figure 1 A function specified in one or more boxes.

[0157] These computer program instructions can also be loaded onto a computer or other programmable data processing device so that a series of operating steps are executed on the computer or other programmable device to produce a computer-implemented process, thereby providing instructions for implementing the process. Figure 1 A process or multiple processes and / or boxes Figure 1 The steps for the functions specified in one or more boxes.

[0158] In a typical configuration, a computing device includes one or more processors (CPU), input / output interfaces, network interfaces, and memory.

[0159] The memory may include non-permanent memory in a computer-readable medium, random access memory (RAM) and / or non-volatile memory in the form of read-only memory (ROM) or flash RAM. The memory is an example of a computer-readable medium.

[0160] Computer readable media include permanent and non-permanent, removable and non-removable media that can be implemented by any method or technology to store information. Information can be computer readable instructions, data structures, program modules or other data. Examples of computer storage media include, but are not limited to, phase change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory or other memory technology, compact disk read-only memory (CD-ROM), digital versatile disk (DVD) or other optical storage, magnetic cassettes, magnetic disk storage or other magnetic storage devices or any other non-transmission media that can be used to store information that can be accessed by a computing device. As defined herein, computer readable media does not include temporary computer readable media (transitory media), such as modulated data signals and carrier waves.

[0161] It should also be noted that the terms "include", "comprises" or any other variations thereof are intended to cover non-exclusive inclusion, so that a process, method, commodity or device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, commodity or device. In the absence of more restrictions, the elements defined by the sentence "comprises a ..." do not exclude the existence of other identical elements in the process, method, commodity or device including the elements.

[0162] From the above description, it can be seen that the above embodiments of the present application achieve the following technical effects:

[0163] In the above embodiment, first, an image of at least one paper after printing a predetermined pattern and when the ink is not completely dry is obtained to obtain at least one first image. In the case of obtaining multiple first images, the paper corresponding to the multiple first images is the same type of paper; secondly, whether the paper absorbs ink uniformly is determined based on at least one first image; finally, whether the paper is suitable for printing is determined based on whether the paper absorbs ink uniformly. In the case of uneven ink absorption, it is determined that the paper is not suitable for printing. Compared with the prior art, the solution of the present application uses image processing technology to detect the ink absorption of at least the image at the initial moment when the printed pattern is completed. By judging whether the paper absorbs ink uniformly, it is detected whether the paper is suitable for printing the pattern, thereby solving the problem of the lack of a method for determining whether the paper is suitable for printing in the prior art.

[0164] The above description is only the preferred embodiment of the present application and is not intended to limit the present application. For those skilled in the art, the present application may have various modifications and variations. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present application shall be included in the protection scope of the present application.

Claims

1. A method for detecting whether paper is suitable for printing, characterized in that: include: Acquire at least one image of a paper after a predetermined pattern is printed and the ink is not completely dried, to obtain at least one first image, and in the case of acquiring a plurality of the first images, the paper corresponding to the plurality of the first images is the same type of paper; determining whether the paper absorbs ink uniformly according to at least one of the first images; Whether the paper is suitable for printing is determined based on whether the paper absorbs ink uniformly. In the case where the paper absorbs ink unevenly, it is determined that the paper is not suitable for printing.

2. The detection method according to claim 1, characterized in that: Determining whether the paper absorbs ink uniformly according to at least one of the first images includes: Preprocessing the first image to obtain at least one second image, wherein the preprocessing at least includes binarization processing; Obtain a difference in grayscale values ​​of at least two first inked areas of at least one of the second images to obtain a grayscale difference. When there is a grayscale difference that is greater than or equal to a difference threshold, determine that the paper absorbs ink unevenly. When all the grayscale differences are less than the difference threshold, determine that the paper absorbs ink evenly and center lines of the two first inked areas have an angle greater than 0 degrees.

3. The detection method according to claim 2, characterized in that: The included angle between the center lines of any two of the first ink-containing areas is between 60° and 90°, and the ratio of the area of ​​the intersection between any two of the first ink-containing areas to the area of ​​the corresponding first ink-containing area is less than 1 / 3.

4. The detection method according to claim 1, characterized in that: Acquiring at least one image of a paper after a predetermined pattern is printed and the ink is not completely dried, to obtain at least one first image, comprising: A plurality of images of the paper after the predetermined pattern is printed and the ink is not completely dried are acquired to obtain a plurality of the first images, and the ink amounts corresponding to any two of the paper are different.

5. The detection method according to claim 2, characterized in that: Determining whether the paper is suitable for printing according to whether the paper absorbs ink uniformly includes: When the paper absorbs ink uniformly, controlling to collect a third image of the paper to obtain the third image; Performing a second preprocessing on the third image to obtain a fourth image; It is determined based on the fourth image whether the ink is evenly dried, and whether the paper is suitable for printing at least based on whether the ink is evenly dried. If it is determined that the ink is not evenly dried, it is determined that the paper is not suitable for printing.

6. The detection method according to claim 5, characterized in that: The second preprocessing includes at least grayscale conversion processing, and determining whether the ink is evenly dried according to the fourth image includes: Calculate the variance of the grayscale values ​​of at least two second ink-containing areas of the fourth image to obtain at least two variances, and calculate the difference between any two of the variances to obtain at least one variance difference. If there is one variance difference value that is not within a preset range, determine that the ink is unevenly dried; if all the variance differences are within the preset range, determine that the ink is uniformly dried.

7. The detection method according to claim 6, characterized in that: The included angle between the center lines of any two of the first ink-containing areas is between 60° and 90°, and the ratio of the area of ​​the intersection between any two of the second ink-containing areas to the area of ​​the corresponding second ink-containing area is less than 1 / 3.

8. The detection method according to claim 5, characterized in that: Determining whether the paper is suitable for printing at least based on whether the ink is evenly dried, comprises: When the ink is evenly dried, controlling to collect a fifth image of the paper to obtain the fifth image; Performing a third preprocessing on the fifth image to obtain a sixth image, and determining whether there are burrs on the edge of the printed line according to the sixth image, and obtaining relevant information about the burrs if there are burrs, wherein the relevant information includes at least the number of the burrs; It is determined whether the paper is suitable for printing according to the relevant information, and when at least the number of the burrs is greater than or equal to a number threshold, it is determined that the paper is not suitable for printing.

9. The detection method according to claim 8, characterized in that: The third preprocessing includes at least binarization processing, the relevant information also includes the sum of grayscale value variances, the sum of grayscale value variances is the sum of the variances of the grayscale values ​​of all burr areas, the burr area is the smallest area including the burr, and determining whether the paper is suitable for printing based on the relevant information also includes: When the number of the burrs is less than the number threshold and the sum of the gray value variances is less than the sum threshold, it is determined that the paper is suitable for printing.

10. A device for detecting whether paper is suitable for printing, characterized in that: include: An acquisition unit, which acquires an image of at least one paper after a predetermined pattern is printed and the ink is not completely dried, to obtain at least one first image. When a plurality of the first images are acquired, the papers corresponding to the plurality of the first images are the same paper; a first determining unit, for determining whether the paper absorbs ink uniformly according to at least one of the first images; The second determination unit determines whether the paper is suitable for printing according to whether the paper absorbs ink uniformly, and determines that the paper is not suitable for printing when the paper absorbs ink unevenly.

11. A computer-readable storage medium, characterized in that: The computer-readable storage medium includes a stored program, wherein when the program is executed, the device where the computer-readable storage medium is located is controlled to execute the method for detecting whether paper is suitable for printing as claimed in any one of claims 1 to 9.

12. A processor, characterized in that: The processor is used to run a program, wherein the program, when running, executes the method for detecting whether paper is suitable for printing as claimed in any one of claims 1 to 9.

13. An electronic device, characterized in that: include: One or more processors, a memory, and one or more programs, wherein the one or more programs are stored in the memory and are configured to be executed by the one or more processors, and the one or more programs include a method for detecting whether the paper described in any one of claims 1 to 9 is suitable for printing.

14. A computer program product comprising a computer program, characterized in that When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 9 are implemented.

Citation Information

Cited By

  • Paper direction detection method based on machine vision

    CN120070441A