A cross-cutting foreign object identification method, controller, medium and device
By collecting and analyzing cross-cutting images in real time in a cold rolling narrow lap welding machine, scrap steel bars can be identified and alarmed, solving the strip quality problems and production line instability caused by scrap steel bars on the cross-cutting shear, and enabling timely detection and handling.
Patent Information
- Application Number
- CN202210605926.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-05-30
- Publication Date
- 2026-01-27
- Estimated Expiration
- 2042-05-30
AI Technical Summary
During the production process of cold-rolled narrow lap welding machines, scrap strips from the cross-cutting shears can easily stick to and fall onto the strip steel, causing strip steel quality problems or unstable production line operation. Existing manual identification methods are not timely enough, leading to frequent malfunctions.
The system uses a camera to collect video data in real time, and uses image recognition algorithms to analyze each frame of the image. It then crops the target area, calculates the similarity between the target image and the reference image, and if the similarity exceeds a preset threshold, it determines that there is a foreign object and sends an alarm notification.
It enables timely identification of scrap steel strips on the cross-cutting shear, avoiding strip quality problems and production line malfunctions, and improving production stability.
Smart Images

Figure CN114972995B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of metallurgical technology, and in particular to a method, controller, medium and device for identifying foreign objects during cross-cutting. Background Technology
[0002] When welding two coils of strip steel, the cold-rolled narrow lap welding machine needs to cut the tail of the front coil and the head of the back coil before welding to ensure that the two coils fit together better.
[0003] However, the scrap strips cut off often stick to the cross-cutting shear due to magnetism. When the cross-cutting shear cuts the strip steel again, the scrap strips fall onto the running cold-rolled strip steel and are carried over to subsequent processes, causing strip steel quality problems or leading to unstable production line operation.
[0004] Currently, the method involves manually observing the strip steel to identify scrap strips on it. However, quality problems or operational malfunctions often occur because production operators fail to notice the scrap steel strips stuck to the cross-cutting shear in time. Summary of the Invention
[0005] To address the problems existing in the prior art, embodiments of the present invention provide a method, controller, medium, and device for identifying foreign objects on a cross-cutting shear, in order to solve or partially solve the technical problem of quality problems in strip steel or production line malfunctions caused by the inability to detect scrap steel bars on the cross-cutting shear in a timely manner.
[0006] This invention provides a method for identifying foreign objects by cross-cutting, the method comprising:
[0007] During the production process, the current image to be cut is retrieved sequentially from the image queue;
[0008] The current image is cropped to obtain the target image;
[0009] Determine the target similarity value between the target image and all reference images in the image database, wherein the image database stores multiple cross-sectional images without foreign objects covering them;
[0010] If the target similarity value is determined to meet the preset similarity value threshold range, then it is determined that there is a foreign object on the transverse cutter.
[0011] In the above scheme, cropping the current image to obtain the target image includes:
[0012] Based on the analysis of historical images showing foreign objects on the cross-section shear, the target area is determined; the target area is the area containing the foreign object.
[0013] The target image is obtained by cropping the current image based on the location corresponding to the target region.
[0014] In the above scheme, determining the target similarity value between the target image and all reference images in the image database includes:
[0015] For any reference image, obtain the first grayscale image matrix corresponding to the target image and the second grayscale image matrix corresponding to the reference image; and obtain the first product matrix of the first grayscale image matrix and the second grayscale image matrix;
[0016] Enhancement processing is performed on the first grayscale image matrix, the second grayscale image matrix, and the first product matrix to obtain the corresponding first grayscale image enhancement matrix and the second grayscale image enhancement matrix, respectively.
[0017] Filter the first grayscale image matrix and the second grayscale image matrix to obtain the corresponding first filtered image matrix and second filtered image matrix, and obtain the second product matrix of the first filtered image matrix and the second filtered image matrix;
[0018] Enhancement processing is performed on the first filtered image matrix and the second filtered image matrix respectively to obtain the corresponding first filtered image enhancement matrix and second filtered image enhancement matrix;
[0019] The first grayscale image enhancement matrix is filtered to obtain a third filtered image enhancement matrix; the second grayscale image enhancement matrix is filtered to obtain a fourth filtered image enhancement matrix; and the first product matrix is filtered to obtain a first product enhancement matrix.
[0020] The similarity matrix is determined based on the first filtered image enhancement matrix, the second filtered image enhancement matrix, the third filtered image enhancement matrix, the fourth filtered image enhancement matrix, the first product enhancement matrix, and the second product matrix.
[0021] Determine the average grayscale value of each pixel in the similarity matrix, where the average value is the similarity value;
[0022] The maximum similarity value among all similarity values is taken as the target similarity value.
[0023] In the above scheme, determining the similarity matrix based on the first filtered image enhancement matrix, the second filtered image enhancement matrix, the third filtered image enhancement matrix, the fourth filtered image enhancement matrix, the first product enhancement matrix, and the second product matrix includes:
[0024] The first difference matrix MC1_2 between the third filtered image enhancement matrix and the first filtered image enhancement matrix is obtained according to the formula MC1_2 = M1_2G - MG1_2;
[0025] The second difference matrix MC1_2 between the fourth filtered image enhancement matrix and the second filtered image enhancement matrix is obtained according to the formula MC2_2=M2_2G-MG2_2;
[0026] The third difference matrix MC12 between the first product enhancement matrix and the second product matrix is obtained according to the formula MC12 = M12G - MG12;
[0027] The first reference matrix S1 is determined according to the formula S1=(2*MG12+Const1)*(2*MC12+Const2);
[0028] The second reference matrix S2 is determined according to the formula S2=(M1_2G+M2_2G+Const1)*(MC1_2+MC2_2+Const2);
[0029] The similarity matrix is determined based on the first reference matrix and the second reference matrix; wherein...
[0030] M1_2G is the third filtered image enhancement matrix, MG1_2 is the first filtered image enhancement matrix, M2_2G is the fourth filtered image enhancement matrix, MG2_2 is the second filtered image enhancement matrix, M12G is the first product enhancement matrix, MG12 is the second product matrix, Const1 is the first correction coefficient, and Const2 is the second correction coefficient.
[0031] In the above scheme, determining the similarity matrix based on the first reference matrix and the second reference matrix includes:
[0032] The similarity matrix SIM is determined according to the formula SIM = S1 / S2; where...
[0033] S1 is the first reference matrix, and S2 is the second reference matrix.
[0034] In the above scheme, if it is determined that the target similarity value meets a preset similarity value threshold, then after determining that there is a foreign object on the transverse cutter, the method further includes:
[0035] Obtain the target reference image corresponding to the target similarity value;
[0036] The difference image matrix is obtained by performing a difference processing on the first grayscale image matrix corresponding to the target image and the mean of the target grayscale image of the target reference image.
[0037] The difference image matrix is binarized to obtain the processed image;
[0038] The processed image is then pushed to the host computer for display.
[0039] In the above scheme, if it is determined that the target similarity value meets a preset similarity value threshold, then after determining that there is a foreign object on the transverse cutter, the method further includes:
[0040] Push alarm notification messages.
[0041] A second aspect of the present invention provides a cross-cutting foreign object identification controller, the controller comprising:
[0042] The acquisition unit is used to sequentially acquire the current cross-cut image from the image queue during the production process;
[0043] The cropping unit is used to crop the current image to obtain the target image;
[0044] The determining unit is used to determine the target similarity value between the target image and all reference images in the image database, wherein the image database stores multiple cross-sectional images without foreign objects covering them; if the target similarity value is determined to meet a preset similarity value threshold range, then it is determined that there are foreign objects on the cross-section.
[0045] A third aspect of the present invention provides a computer-readable storage medium having a computer program stored thereon that, when executed by a processor, implements the steps of the method described in any of the first aspects.
[0046] A fourth aspect of the present invention provides a computer device including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor, when executing the program, implements the steps of the method described in any of the first aspects.
[0047] This invention provides a method, controller, medium, and device for identifying foreign objects on a cross-cutting shear. The method includes: during the production process, sequentially acquiring current images of the cross-cutting shear from an image queue; cropping the current image to obtain a target image; determining the target similarity value between the target image and all reference images in an image database, wherein the image database stores multiple cross-cutting shear images without foreign object coverage; if the target similarity value meets a preset similarity threshold, then it is determined that a foreign object exists on the cross-cutting shear. Thus, during the production process, images of the cross-cutting shear can be acquired and analyzed to accurately determine whether foreign objects are covering the shear, thereby promptly detecting scrap steel strips on the cross-cutting shear, preventing quality problems in the strip steel, and avoiding production line malfunctions. Attached Figure Description
[0048] Various other advantages and benefits will become apparent to those skilled in the art upon reading the following detailed description of preferred embodiments. The accompanying drawings are for illustrative purposes only and are not intended to limit the invention. Furthermore, the same reference numerals denote the same parts throughout the drawings.
[0049] In the attached diagram:
[0050] Figure 1 A schematic diagram of the structure of the cross-cutting foreign object identification system provided in an embodiment of the present invention is shown;
[0051] Figure 2 This diagram illustrates a flow chart of the cross-cutting foreign object identification method provided in an embodiment of the present invention.
[0052] Figure 3 A schematic diagram of the cross-cutting foreign object identification controller structure provided in an embodiment of the present invention is shown;
[0053] Figure 4 A schematic diagram of the computer device structure provided in an embodiment of the present invention is shown;
[0054] Figure 5 A schematic diagram of a computer-readable storage medium structure provided in an embodiment of the present invention is shown. Detailed Implementation
[0055] Exemplary embodiments of the present disclosure will now be described in more detail with reference to the accompanying drawings. While exemplary embodiments of the present disclosure are shown in the drawings, it should be understood that the present disclosure may be implemented in various forms and should not be limited to the embodiments set forth herein. Rather, these embodiments are provided so that this disclosure will be thorough and complete, and will fully convey the scope of the disclosure to those skilled in the art.
[0056] To better understand the technical solution of this application, we will first introduce the transverse cutting foreign object recognition system, such as... Figure 1 As shown, the system includes: a first camera 1, a second camera 2, a controller 3, and a host computer 4; wherein,
[0057] The first camera 1 is installed on one side of the cross-cutting scissors 5 to record one side of the cross-cutting scissors 5 in real time and send the corresponding video data to the controller 3.
[0058] The second camera 2 is installed on the other side of the cross-cutting scissors 5, and is used to record the other side of the cross-cutting scissors 5 in real time and send the corresponding video data to the controller 3;
[0059] When controller 3 receives video data, it acquires each frame of the video data and stores each frame in an image queue so that an image recognition algorithm can be used to identify each frame to determine whether there are foreign objects such as waste strips on the image.
[0060] It is worth noting that, in this embodiment, to avoid errors caused by asynchronous image data reception and processing, a first thread acquires video data captured by the first camera 1 and the second camera 2, and stores each frame of the video data into an image queue for processing. A second thread processes each frame of the image queue sequentially in real time. To improve processing efficiency, the first and second threads are parallel threads.
[0061] Specifically, during the production process, controller 3 sequentially retrieves the current cross-cut images from the image queue;
[0062] The current image is cropped to obtain the target image;
[0063] Determine the target similarity value between the target image and all reference images in the image database, wherein the image database stores multiple cross-sectional images without foreign objects covering them;
[0064] If the target similarity value is determined to meet the preset similarity value threshold, then it is determined that there is a foreign object on the transverse cutter.
[0065] The specific implementation of how controller 3 identifies each frame of image will be described in detail in subsequent controller-side embodiments, so it will not be repeated here.
[0066] Based on the same inventive concept as the foregoing embodiments, this embodiment also provides a method for identifying transversely cut foreign objects, applied in a controller, such as... Figure 2 As shown, the method includes:
[0067] S210, during the production process, the current image for cross-cutting is sequentially retrieved from the image queue;
[0068] As mentioned above, during the production process, the controller acquires video data from the first and second cameras and stores each frame of the video data in an image queue. Then, when performing image recognition, the current image can be sequentially retrieved from the image queue and the current image can be recognized.
[0069] S211, Crop the current image to obtain the target image;
[0070] To improve the accuracy and efficiency of recognition, this embodiment cropps the current image after obtaining it to obtain the target image.
[0071] In one implementation, cropping the current image to obtain a target image for any given current image includes:
[0072] Based on the analysis of historical images showing foreign objects on the cross-cutting shear, the target area was determined; the target area is the region containing foreign objects; the foreign objects are waste strips.
[0073] The target image is obtained by cropping the current image based on the location corresponding to the target region.
[0074] Specifically, since the cross-cutting shear has a large area, if there are waste strips pasted on the cross-cutting shear, they are generally pasted in a certain area. Therefore, this embodiment analyzes historical images of foreign objects on the cross-cutting shear to determine the target area, and then crops the current image based on the position of the target area. The target image obtained in this way is equivalent to cutting off the surrounding blank areas and only keeping the area where foreign objects may exist. This can improve the efficiency of image recognition in subsequent image recognition.
[0075] S212, determine the target similarity value between the target image and all reference images in the image database, wherein the image database stores multiple cross-sectional images without foreign objects covering them;
[0076] Then, the target similarity value between the target image and all reference images in the image database is determined. The image database stores multiple cross-sectional images without foreign objects covering them.
[0077] Here, the image database stores normal cross-sectional images, meaning the cross-sectional surface is free of any foreign objects. The number of reference images is multiple, generally 30 to 50.
[0078] Then, for the target photo, determine the target similarity value between the target image and all reference images in the image database, including:
[0079] For any reference image, obtain the first grayscale image matrix M1 corresponding to the target image and the second grayscale image matrix M2 corresponding to the reference image; and obtain the first product matrix M12 of the first grayscale image matrix and the second grayscale image matrix; where M12 = M1 * M2;
[0080] Enhancement processing is performed on the first grayscale image matrix M1 and the second grayscale image matrix M2 to obtain the corresponding first grayscale image enhancement matrix M1_2 and second grayscale image enhancement matrix M2_2, respectively; where M1_2 = M1*M1; M2_2 = M2*M2;
[0081] Filter the first grayscale image matrix M1 and the second grayscale image matrix M2 to obtain the corresponding first filtered image matrix MG1 and second filtered image matrix MG2, and obtain the second product matrix MG12 of the first filtered image matrix and the second filtered image matrix; wherein, MG12 = MG1 * MG2;
[0082] Enhancement processing is performed on the first filtered image matrix MG1, the second filtered image matrix MG2, and the second product matrix MG12 respectively to obtain the corresponding first filtered image enhancement matrix MG1_2 and second filtered image enhancement matrix MG2_2; wherein, MG1_2 = MG1 * MG1; MG2_2 = MG2 * MG2;
[0083] The first grayscale image enhancement matrix M1_2 is filtered to obtain the third filtered image enhancement matrix M1_2G; the second grayscale image enhancement matrix M2_2 is filtered to obtain the fourth filtered image enhancement matrix M2_2G; and the first product matrix M12 is filtered to obtain the first product enhancement matrix M12G.
[0084] The similarity matrix is determined based on the first filtered image enhancement matrix, the second filtered image enhancement matrix, the third filtered image enhancement matrix, the fourth filtered image enhancement matrix, the first product enhancement matrix, and the second product matrix.
[0085] Determine the average grayscale value of each pixel in the similarity matrix; the average value is the similarity value.
[0086] The maximum similarity value among all similarity values is taken as the target similarity value.
[0087] In one embodiment, determining a similarity matrix based on the first filtered image enhancement matrix, the second filtered image enhancement matrix, the third filtered image enhancement matrix, the fourth filtered image enhancement matrix, the first product enhancement matrix, and the second product matrix includes:
[0088] The first difference matrix MC1_2 between the third filtered image enhancement matrix and the first filtered image enhancement matrix is obtained according to the formula MC1_2=M1_2G-MG1_2;
[0089] The second difference matrix MC1_2 between the fourth filtered image enhancement matrix and the second filtered image enhancement matrix is obtained according to the formula MC2_2=M2_2G-MG2_2;
[0090] The third difference matrix MC12 between the first product enhancement matrix and the second product matrix is obtained according to the formula MC12 = M12G - MG12;
[0091] The first reference matrix S1 is determined according to the formula S1=(2*MG12+Const1)*(2*MC12+Const2);
[0092] The second reference matrix S2 is determined according to the formula S2=(M1_2G+M2_2G+Const1)*(MC1_2+MC2_2+Const2);
[0093] The similarity matrix is determined according to the first reference matrix and the second reference matrix in the formula; wherein...
[0094] M1_2G is the third filtered image enhancement matrix, MG1_2 is the first filtered image enhancement matrix, M2_2G is the fourth filtered image enhancement matrix, MG2_2 is the second filtered image enhancement matrix, M12G is the first product enhancement matrix, MG12 is the second product matrix, Const1 is the first correction coefficient, and Const2 is the second correction coefficient. Both the first and second correction coefficients are used to improve the accuracy of similarity values. The value range of the first correction coefficient is 1 to 10, and in this embodiment, the value of the first correction coefficient is 7.5115. The value range of the second correction coefficient is 1 to 100, and in this embodiment, Const2 = 68.7215.
[0095] In one implementation, determining the similarity matrix based on a first reference matrix and a second reference matrix includes:
[0096] The similarity matrix SIM is determined according to the formula SIM = S1 / S2; where...
[0097] S1 is the first reference matrix, and S2 is the second reference matrix.
[0098] Then, the average grayscale value of each pixel in the similarity matrix is calculated, and this average value is used as the similarity value. This process yields multiple similarity values, with the maximum similarity value being selected as the target similarity value.
[0099] S213, if it is determined that the target similarity value meets the preset similarity value threshold range, then it is determined that there is a foreign object on the transverse cutter.
[0100] Determine whether the target similarity value meets the preset similarity value threshold range. If it is determined that the target similarity value meets the preset similarity value threshold range, then it is determined that there is a foreign object on the cross-section.
[0101] In this embodiment, the similarity threshold range is (0.85, 0.95). That is, when the target similarity value is determined to be greater than 0.85 and less than 0.95, it is determined that there is a foreign object, such as a scrap strip, on the cross-cutting surface. When the target similarity value is greater than 0.95, it means that the target image is very similar to the reference image, so the possibility of foreign objects being present in the cross-cutting in the target image is low. When the target similarity value is less than 0.85, it means that there is a lot of interference noise in the target image, and the recognition result may be inaccurate.
[0102] In one embodiment, if a foreign object is determined to be present on the cross-cutting shears, the method further includes, in order to make the foreign object more prominent:
[0103] Obtain the target reference image corresponding to the target similarity value;
[0104] The difference image matrix is obtained by performing a difference processing on the first grayscale image matrix corresponding to the target image and the mean grayscale image of the target reference image.
[0105] Binarize the difference image matrix to obtain the processed image;
[0106] The processed image is pushed to the host computer for display.
[0107] To promptly alert staff to handle the cross-cutting shear, if the target similarity value meets a preset similarity threshold, and it is determined that a foreign object exists on the cross-cutting shear, the method further includes:
[0108] Push alarm notification messages.
[0109] In this embodiment, the alarm notification information can be an audible and visual alarm or a voice prompt; there are no restrictions on this.
[0110] It should be noted that after the current image is fully recognized, it is deleted from the image queue to ensure that the memory of the image queue does not overflow and to avoid operational failures.
[0111] Based on the same inventive concept as the foregoing embodiments, this embodiment also provides a cross-cutting foreign object identification controller, such as... Figure 3 As shown, the controller includes:
[0112] The acquisition unit 31 is used to sequentially acquire the current image of the cross-section from the image queue during the production process;
[0113] Cropping unit 32 is used to crop the current image to obtain the target image;
[0114] The determining unit 33 is used to determine the target similarity value between the target image and all reference images in the image database, wherein the image database stores multiple cross-sectional images without foreign objects covering them; if the target similarity value is determined to meet the preset similarity value threshold range, then it is determined that there are foreign objects on the cross-section.
[0115] Since the controller described in this embodiment of the invention is the controller used to implement the tire pressure monitoring method of this invention, those skilled in the art can understand the specific structure and variations of the device based on the method described in this embodiment of the invention, and therefore will not be described in detail here. All controllers used in the methods of this embodiment of the invention fall within the scope of protection of this invention.
[0116] Based on the same inventive concept as in the foregoing embodiments, this embodiment of the invention also provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the steps of any of the methods described above.
[0117] Based on the same inventive concept as in the foregoing embodiments, this embodiment of the invention also provides a computer device, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the program to implement the steps of any of the methods described above.
[0118] Through one or more embodiments of the present invention, the present invention has the following beneficial effects or advantages:
[0119] This invention provides a method, controller, medium, and device for identifying foreign objects on a cross-cutting shear. The method includes: during the production process, sequentially acquiring current images of the cross-cutting shear from an image queue; cropping the current image to obtain a target image; determining the target similarity value between the target image and all reference images in an image database, wherein the image database stores multiple cross-cutting shear images without foreign object coverage; if the target similarity value meets a preset similarity threshold, then it is determined that a foreign object exists on the cross-cutting shear. Thus, during the production process, images of the cross-cutting shear can be acquired and analyzed to accurately determine whether foreign objects are covering the shear, thereby promptly detecting scrap steel strips on the cross-cutting shear, preventing quality problems in the strip steel, and avoiding production line malfunctions.
[0120] The algorithms and displays provided herein are not inherently related to any particular computer, virtual system, or other device. Various general-purpose systems can also be used in conjunction with the teachings herein. The required structure for constructing such systems is apparent from the above description. Furthermore, this invention is not directed to any particular programming language. It should be understood that the contents of the invention described herein can be implemented using various programming languages, and the above description of specific languages is for the purpose of disclosing the best mode of implementation of the invention.
[0121] Numerous specific details are set forth in the specification provided herein. However, it will be understood that embodiments of the invention may be practiced without these specific details. In some instances, well-known methods, structures, and techniques have not been shown in detail so as not to obscure the understanding of this specification.
[0122] Similarly, it should be understood that, in order to simplify this disclosure and aid in understanding one or more of the various aspects of the invention, in the above description of exemplary embodiments of the invention, various features of the invention are sometimes grouped together in a single embodiment, figure, or description thereof. However, this method of disclosure should not be construed as reflecting an intention that the claimed invention requires more features than are expressly recited in each claim. Rather, as reflected in the following claims, inventive aspects lie in fewer than all features of a single foregoing disclosed embodiment. Therefore, the claims following the detailed description are hereby expressly incorporated into this detailed description, wherein each claim itself is a separate embodiment of the invention.
[0123] Those skilled in the art will understand that modules in the device of the embodiments can be adaptively changed and placed in one or more devices different from that embodiment. Modules, units, or components in the embodiments can be combined into a single module, unit, or component, and further, they can be divided into multiple sub-modules, sub-units, or sub-components. Except where at least some of such features and / or processes or units are mutually exclusive, any combination can be used to combine all features disclosed in this specification (including the accompanying claims, abstract, and drawings) and all processes or units of any method or device so disclosed. Unless expressly stated otherwise, each feature disclosed in this specification (including the accompanying claims, abstract, and drawings) may be replaced by an alternative feature that serves the same, equivalent, or similar purpose.
[0124] Furthermore, those skilled in the art will understand that although some embodiments herein include certain features included in other embodiments but not others, combinations of features from different embodiments are intended to be within the scope of the invention and form different embodiments. For example, in the following claims, any of the claimed embodiments can be used in any combination.
[0125] The various component embodiments of the present invention can be implemented in hardware, or as software modules running on one or more processors, or a combination thereof. Those skilled in the art will understand that microprocessors or digital signal processors (DSPs) can be used in practice to implement some or all of the functions of some or all of the components of the gateway, proxy server, or system according to embodiments of the present invention. The present invention can also be implemented as a device or apparatus program (e.g., a computer program and computer program product) for performing some or all of the methods described herein. Such programs implementing the present invention can be stored on a computer-readable medium or can be in the form of one or more signals. Such signals can be downloaded from an Internet website, provided on a carrier signal, or provided in any other form.
[0126] It should be noted that the above embodiments are illustrative of the invention and not restrictive, and that those skilled in the art can devise alternative embodiments without departing from the scope of the appended claims. In the claims, any reference signs placed between parentheses should not be construed as limiting the claims. The word "comprising" does not exclude the presence of elements or steps not listed in the claims. The word "a" or "an" preceding an element does not exclude the presence of a plurality of such elements. The invention can be implemented by means of hardware comprising several different elements and by means of a suitably programmed computer. In the unit claims enumerating several means, several of these means may be embodied by the same item of hardware. The use of the words first, second, and third, etc., does not indicate any order. These words can be interpreted as names.
[0127] Although preferred embodiments of this application have been described, those skilled in the art, upon learning the basic inventive concept, can make other changes and modifications to these embodiments. Therefore, the appended claims are intended to be interpreted as including the preferred embodiments as well as all changes and modifications falling within the scope of this application.
[0128] The above description is merely a preferred embodiment of the present invention and is not intended to limit the scope of protection of the present invention. Any modifications, equivalent substitutions, and improvements made within the spirit and principles of the present invention should be included within the scope of protection of the present invention.
Claims
1. A method for identifying foreign objects by cross-cutting, characterized in that, The method includes: During the production process, the current image to be cut is retrieved sequentially from the image queue; The current image is cropped to obtain the target image; Determine the target similarity value between the target image and all reference images in the image database, wherein the image database stores multiple cross-sectional images without foreign objects covering them; If the target similarity value is determined to meet the preset similarity value threshold range, then it is determined that there is a foreign object on the transverse cutter. The step of cropping the current image to obtain the target image includes: Based on the analysis of historical images showing foreign objects on the cross-section shear, the target area is determined; the target area is the area containing the foreign object. The current image is cropped based on the location corresponding to the target region to obtain the target image; Determining the target similarity value between the target image and all reference images in the image database includes: For any reference image, obtain the first grayscale image matrix corresponding to the target image and the second grayscale image matrix corresponding to the reference image; and obtain the first product matrix of the first grayscale image matrix and the second grayscale image matrix; Enhancement processing is performed on the first grayscale image matrix, the second grayscale image matrix, and the first product matrix to obtain the corresponding first grayscale image enhancement matrix and the second grayscale image enhancement matrix, respectively. Filter the first grayscale image matrix and the second grayscale image matrix to obtain the corresponding first filtered image matrix and second filtered image matrix, and obtain the second product matrix of the first filtered image matrix and the second filtered image matrix; Enhancement processing is performed on the first filtered image matrix and the second filtered image matrix respectively to obtain the corresponding first filtered image enhancement matrix and second filtered image enhancement matrix; The first grayscale image enhancement matrix is filtered to obtain a third filtered image enhancement matrix; the second grayscale image enhancement matrix is filtered to obtain a fourth filtered image enhancement matrix; and the first product matrix is filtered to obtain a first product enhancement matrix. A similarity matrix is determined based on the first filtered image enhancement matrix, the second filtered image enhancement matrix, the third filtered image enhancement matrix, the fourth filtered image enhancement matrix, the first product enhancement matrix, and the second product matrix. Determine the average grayscale value of each pixel in the similarity matrix, where the average value is the similarity value; The maximum similarity value among all similarity values is taken as the target similarity value.
2. The method as described in claim 1, characterized in that, The step of determining the similarity matrix based on the first filtered image enhancement matrix, the second filtered image enhancement matrix, the third filtered image enhancement matrix, the fourth filtered image enhancement matrix, the first product enhancement matrix, and the second product matrix includes: The first difference matrix MC1_2 between the third filtered image enhancement matrix and the first filtered image enhancement matrix is obtained according to the formula MC1_2 = M1_2G - MG1_2; The second difference matrix MC1_2 between the fourth filtered image enhancement matrix and the second filtered image enhancement matrix is obtained according to the formula MC2_2 = M2_2G - MG2_2; The third difference matrix MC12 between the first product enhancement matrix and the second product matrix is obtained according to the formula MC12 = M12G - MG12; The first reference matrix S1 is determined according to the formula S1 = (2 * MG12 + Const1) * (2 * MC12 + Const2); The second reference matrix S2 is determined according to the formula S2 = (M1_2G + M2_2G + Const1) * (MC1_2 + MC2_2 + Const2); The similarity matrix is determined based on the first reference matrix and the second reference matrix; wherein... M1_2G is the third filtered image enhancement matrix, MG1_2 is the first filtered image enhancement matrix, M2_2G is the fourth filtered image enhancement matrix, MG2_2 is the second filtered image enhancement matrix, M12G is the first product enhancement matrix, MG12 is the second product matrix, Const1 is the first correction coefficient, and Const2 is the second correction coefficient.
3. The method as described in claim 2, characterized in that, Determining the similarity matrix based on the first reference matrix and the second reference matrix includes: The similarity matrix SIM is determined according to the formula SIM=S1 / S2; where... S1 is the first reference matrix, and S2 is the second reference matrix.
4. The method as described in claim 1, characterized in that, If the target similarity value is determined to meet a preset similarity threshold, then after determining that there is a foreign object on the transverse cutter, the method further includes: Obtain the target reference image corresponding to the target similarity value; The difference image matrix is obtained by performing a difference processing on the first grayscale image matrix corresponding to the target image and the mean of the target grayscale image of the target reference image. The difference image matrix is binarized to obtain the processed image; The processed image is then pushed to the host computer for display.
5. The method as described in claim 1, characterized in that, If the target similarity value is determined to meet a preset similarity threshold, then after determining that there is a foreign object on the transverse cutter, the method further includes: Push alarm notification messages.
6. A cross-cutting foreign object identification controller, characterized in that, The controller includes: The acquisition unit is used to sequentially acquire the current cross-cut image from the image queue during the production process; The cropping unit is used to crop the current image to obtain the target image; The determining unit is used to determine the target similarity value between the target image and all reference images in the image database, wherein the image database stores multiple cross-sectional images without foreign objects covering them; if the target similarity value is determined to meet a preset similarity value threshold range, then it is determined that there are foreign objects on the cross-section.
7. A computer-readable storage medium having a computer program stored thereon, characterized in that, When executed by a processor, the program implements the steps of the method according to any one of claims 1-5.
8. A computer device, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that, When the processor executes the program, it implements the steps of the method according to any one of claims 1-5.
Citation Information
Patent Citations
Station icon identification method and identification system
CN104185069A
Shooting method, device, storage medium and electronic device
CN107566742A
Method and System for Image Recognition Using a Similarity Inverse Matrix
US20080133521A1