Inspection device, method for inspection, and program
Patent Information
- Application Number
- JP2023127514
- Authority / Receiving Office
- JP · JP
- Patent Type
- Applications
- Current Assignee / Owner
- Filing Date
- 2023-08-04
- Publication Date
- 2025-02-17
AI Technical Summary
【0014】 本発明によれば、収容体の不良の検出精度が向上するという効果を奏する。
Smart Images

Figure 2025023415000001_ABST
Abstract
Description
[Technical field]
[0001] The present invention relates to an inspection device, an inspection method, and a program for inspecting an object to be inspected. [Background technology]
[0002] Conventionally, there is known a visual inspection device that can capture an image of an inspection object under optimal imaging conditions regardless of the transport position of the inspection object (for example, see Patent Document 1). In this visual inspection device, the inspection object is captured while being irradiated with a plurality of light sources arranged in a plane, and an image for visual inspection of the inspection object is generated by again irradiating the object with a light source selected based on the position of the inspection object detected in the captured image. [Prior art documents] [Patent documents]
[0003] [Patent Document 1] JP 2020-046310 A Summary of the Invention [Problem to be solved by the invention]
[0004] Conventional visual inspection devices require multiple light sources arranged over an area wider than the width of the object being inspected. Even if multiple light sources are used, the illuminance may vary depending on the shape of the object being inspected, which may reduce the accuracy of detecting defects in the object being inspected.
[0005] The present invention has been made in consideration of these points, and has an object to improve the accuracy of detecting defects in containers. [Means for solving the problem]
[0006] The inspection apparatus of the first aspect of the present invention comprises an image data acquisition unit that acquires a plurality of image data sets generated by an imaging device photographing an object to be inspected while the object is being transported through an inspection target area in an imaging region of the imaging device with light being irradiated onto the object to be inspected, and a defect detection unit that detects defects in the object to be inspected based on the plurality of image data sets, each of which captures a partial region of the object to be inspected.
[0007] The multiple pieces of captured image data are generated by photographing multiple different areas of the object to be inspected in the transport direction, and the defect detection unit may determine that the object to be inspected is defective when it detects an abnormality in the object to be inspected in combined image data obtained by combining the multiple pieces of captured image data.
[0008] The multiple pieces of captured image data are generated by the imaging device taking images at different times while the inspection object is being transported in the transport direction, and the defect detection unit may detect defects in the inspection object based on the multiple pieces of captured image data after moving at least one of the pieces of captured image data in a direction perpendicular to the transport direction so as to increase image continuity in two adjacent pieces of captured image data among the multiple pieces of captured image data.
[0009] The object to be inspected may include a linear area in the transport direction, and the defect detection unit may create the combined image data by moving at least one of the captured image data so that the linear area becomes linear.
[0010] The object to be inspected may include a predetermined auxiliary region, and the defect detection unit may create the combined image data by moving at least one of the captured image data so that a shape of the auxiliary region in the combined image data becomes a predetermined shape stored in a memory unit.
[0011] The multiple pieces of captured image data are generated by photographing multiple different areas of the object to be inspected, and the defect detection unit is a machine learning model trained by machine learning using teacher image data generated by photographing multiple different areas of the object to be inspected when a defect is present, or teacher image data generated by photographing multiple different areas of the object to be inspected when no defect is present, and defects in the object to be inspected may be detected by inputting the multiple pieces of captured image data or combined image data in which the multiple pieces of captured image data are combined into a machine learning model that outputs a result of determining whether or not the object to be inspected has a defect.
[0012] An inspection method according to a second aspect of the present invention includes a computer-executed step of acquiring a plurality of image data pieces generated by an imaging device photographing an object to be inspected while the object is being transported through an inspection target area in an imaging region of the imaging device while being irradiated with light, and detecting defects in the object to be inspected based on the plurality of image data pieces, each of which captures a partial region of the object to be inspected.
[0013] A program of a third aspect of the present invention is a program for causing a computer to execute the steps of: acquiring multiple pieces of image data generated by an imaging device photographing an object to be inspected while the object is being transported through an inspection range in an imaging area of an imaging device with light irradiated onto the object; and detecting defects in the object to be inspected based on the multiple pieces of image data, each of which captures a partial area of the object to be inspected. Effect of the Invention
[0014] According to the present invention, there is an effect that the accuracy of detecting defects in a container is improved. [Brief description of the drawings]
[0015] [Figure 1] FIG. 2 is a diagram for explaining an overview of an inspection system S. [Diagram 2]1 is a diagram showing a configuration of an inspection device 1. FIG. [Diagram 3] 4 is a diagram showing an example of test result data stored in the storage unit 13. FIG. [Figure 4] 13 is a diagram for explaining a process in which the defect detection section 142 detects defects in the inspection object W based on the combined image data. FIG. [Diagram 5] FIG. 13 is a diagram showing partial image data captured in an inspection target range at a plurality of different times. [Figure 6] FIG. 13 is a diagram for explaining a method for creating combined image data. [Figure 7] 4 is a flowchart showing a process flow in the inspection system S. DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS
[0016] [Overview of Inspection System S] FIG. 1 is a diagram for explaining an overview of an inspection system S. The inspection system S is a system for inspecting an object W to be inspected. The object W to be inspected may be any object, but the following description will exemplify a case in which the object W to be inspected has a container A and a connecting member B attached to the container A by a fastener C so as to cover an end of the container A. The container A is an object such as a bag or a box having a space for storing some kind of item. The container A is, for example, a bag that stores food such as rice or flour.
[0017] Although details will be described later, the connecting member B is, for example, a lid having a shape that covers the opening of the container A. The fastener C is a member for connecting the container A and the connecting member B by penetrating the container A and the connecting member B with a partial area of the container A and a partial area of the connecting member B overlapping each other, and is, for example, a thread or a linear metal (for example, a stapler core).
[0018] The inspection system S includes an inspection device 1, an imaging device 2, and a conveying device 3. The inspection device 1 inspects the inspection object W based on image data generated by the imaging device 2 by photographing the inspection object W. The conveying device 3 is a device for conveying the inspection object W so that the inspection object W passes through an imaging area of the imaging device 2, and is, for example, a belt conveyor.
[0019] The imaging device 2 has an imaging element. In the inspection system S, the imaging device 2 generates captured image data (hereinafter, sometimes referred to as "image data") by capturing an image of the inspection object W in a state where light is irradiated onto the inspection object W. The imaging device 2 captures an image of an area including a central position of the inspection object W in the transport direction.
[0020] The imaging device 2 inputs the captured image data to the inspection device 1. The inspection device 1 inspects the inspection object W for defects that do not satisfy a predetermined standard, such as stains or tears, based on the image data.
[0021] [Configuration of inspection device 1] 2 is a diagram showing the configuration of the inspection device 1. The inspection device 1 has a communication unit 11, a display unit 12, a storage unit 13, and a control unit 14. The control unit 14 has an image data acquisition unit 141 and a defect detection unit 142.
[0022] The communication unit 11 has a communication interface for transmitting and receiving data to and from an external device. The communication unit 11 receives image data from, for example, the imaging device 2. The communication unit 11 inputs the received image data to the image data acquisition unit 141. The communication unit 11 may transmit the result of the defect detection unit 142 determining whether or not there is a defect to an external computer.
[0023] The display unit 12 is, for example, a display, and displays the result of the defect detection unit 142 determining whether or not there is a defect.
[0024] The storage unit 13 includes storage media such as a Read Only Memory (ROM), a Random Access Memory (RAM), and a Solid State Drive (SSD), etc. The storage unit 13 stores a program executed by the control unit 14.
[0025] The storage unit 13 stores various data necessary for inspecting the object to be inspected W. The storage unit 13 stores, for example, image data received by the communication unit 11. The storage unit 13 may store the image data in association with identification information for identifying the object to be inspected W.
[0026] The storage unit 13 also stores reference data for determining whether the inspection object W is good or bad. The storage unit 13 stores the reference data in association with each inspection item. The reference data may be data showing an image of a good product or data showing an image of a defective product. The reference data may be a machine learning model created by deep learning to distinguish between good and defective products.
[0027] The storage unit 13 also stores inspection result data indicating the result of the determination of the presence or absence of defects by the defect detection unit 142. Fig. 3 is a diagram showing an example of the inspection result data stored in the storage unit 13. Fig. 3 shows an inspection result based on image data of the front side of the inspection object W and an inspection result based on image data of the rear side of the inspection object W.
[0028] 3, the judgment results of each inspection item based on each image data are associated with the inspection object ID of the inspection object W, and the overall judgment result is associated with the inspection object ID of the inspection object W. If all of the inspection items are pass (◯), the overall judgment result is "pass," and if at least one of the inspection items is fail (×), the overall judgment result is "fail."
[0029] "Dirt", which is an inspection item corresponding to the image data, is a state in which dirt that should not be there is present and there is a part of the surface of the inspection object W that is different in color from other parts. "Tear" is a state in which part of the inspection object W is torn.
[0030] The control unit 14 includes, for example, a CPU (Central Processing Unit). The control unit 14 executes a program stored in the storage unit 13, thereby functioning as an image data acquisition unit 141 and a defect detection unit 142.
[0031] The image data acquisition unit 141 acquires, via the communication unit 11, image data generated by imaging the inspection object W with the imaging device 2 while the inspection object W is irradiated with light. The inspection object W may be irradiated with light by the imaging device 2, or may be irradiated with light by another device. The image data acquisition unit 141 acquires image data generated by imaging the inspection object W irradiated with light while the inspection object W is being transported so as to pass through the imaging area of the imaging device 2.
[0032] The image data acquisition unit 141 stores the acquired image data in the storage unit 13 in association with the inspection object ID. The image data acquisition unit 141 accepts the setting of the inspection object ID of the first inspection object W at the time when the inspection is started, for example, via the communication unit 11, and updates the inspection object ID according to a predetermined rule every time new image data is acquired, thereby determining the inspection object ID corresponding to each image data. When the inspection object W includes the inspection object ID or an image including the inspection object ID, the image data acquisition unit 141 may identify the inspection object ID by reading the inspection object ID from the image data.
[0033] The image data acquisition unit 141 may store the image data in the storage unit 13 in association with the time when the image data was captured together with the inspection object ID or as the inspection object ID.
[0034] The defect detection unit 142 detects defects in the inspection object W based on the image data. The defect detection unit 142 detects defects in the inspection object W based on, for example, the state of at least one of the connecting member B and the fastener C in the image data.
[0035] The defect detection unit 142 detects, for example, a defect that the fastener C does not have a predetermined shape. As an example, the defect detection unit 142 reads out reference image data showing the shape of the fastener C in a normal state from the storage unit 13, and compares the shape of the fastener C shown by the image data with the shape of the fastener C shown by the reference image data. The defect detection unit 142 determines that the inspection object W is defective when there is a difference of a predetermined amount or more between the comparison results.
[0036] [Inspection using multiple captured image data] However, if the object W to be inspected has width and it is difficult to illuminate it with a uniform illuminance, the illuminance varies depending on the part of the object W to be inspected, and the accuracy of defect detection may be reduced using only one piece of image data generated by the imaging device 2. Therefore, the image data acquisition unit 141 may acquire multiple pieces of image data (hereinafter, sometimes referred to as "multiple partial image data") generated by capturing images of different areas of the object W to be inspected multiple times while the object W passes through the imaging area of the imaging device 2.
[0037] The multiple partial image data are generated by the imaging device 2 capturing images of the inspection object W at different times while the inspection object W is being transported in the transport direction (the longitudinal direction of the connecting member B in the example of FIG. 1), and each of the multiple partial image data includes image data of multiple different regions of the connecting member B. The multiple partial image data may be generated by the imaging device 2 capturing images of the inspection object W at different times.
[0038] The defect detection unit 142 detects defects in the object W based on a plurality of partial image data, each of which shows a partial area of the object W. However, if the defect detection unit 142 detects defects using each partial image data individually, there is a risk that defects existing near the ends of each partial image data may not be detected. Therefore, the defect detection unit 142 determines that the object W has a defect when it detects an abnormality in the shape of the object W, a stain on the object W, a tear on the object W, or the like in the combined image data obtained by combining a plurality of partial image data.
[0039] 4 to 6 are diagrams for explaining the process in which the defect detection unit 142 detects defects in the inspection object W based on the combined image data. In the example shown in FIG. 4, the inspection object W is transported so as to pass through the inspection target range in the order of times T1, T2, T3, and T4. The inspection target range is, for example, a range that includes the center of the imaging region of the imaging device 2 and in which the inspection object W is best imaged. A joining auxiliary line L, which is a linear area in the transport direction (i.e., the horizontal direction), is drawn on the inspection object W shown in FIG. 4. The inspection target range may be a range where light is irradiated.
[0040] Fig. 5 is a diagram showing partial image data captured in an inspection range at multiple different times (times T1, T2, T3, and T4). Fig. 6 is a diagram for explaining a method of creating combined image data by combining the multiple partial image data shown in Fig. 5.
[0041] The defect detection unit 142 creates the tentative combined image data as shown in Fig. 6(a) by arranging the multiple partial image data in the order of the time when they were photographed. The defect detection unit 142 creates the tentative combined image data by arranging the multiple partial image data photographed continuously at a predetermined time interval determined based on the conveying speed of the conveying device 3, for example. The defect detection unit 142 creates the tentative combined image data by comparing the partial image data with the image data photographed without the inspection object W, excluding the partial image data that does not include the inspection object W, and arranging the multiple partial image data that include at least a part of the inspection object W.
[0042] 6(a), the joining auxiliary line L is discontinuous because the object W may have a curved or uneven shape, or the multiple partial image data may be displaced in the vertical direction due to the influence of vibrations while the object W is being transported. If the defect detection unit 142 determines the presence or absence of a defect in this state, the determination accuracy will decrease.
[0043] Therefore, the defect detection unit 142 creates combined image data by correcting the tentative combined image data by moving at least one partial image data in a direction perpendicular to the transport direction (i.e., the longitudinal direction of the joining member B) so that the image continuity of two adjacent partial image data out of the plurality of partial image data (e.g., the plurality of partial image data) is increased. The defect detection unit 142 corrects the tentative combined image data by, for example, moving the positions of the plurality of partial image data so that the shape of the joining auxiliary line L in the tentative combined image data becomes a predetermined shape (e.g., a straight line shape). The defect detection unit 142 may correct pixel values so that the boundary line between the plurality of partial image data becomes less noticeable.
[0044] The defect detection unit 142 detects defects in the inspection object W based on the corrected combined image data as shown in Fig. 6(b). The defect detection unit 142 detects defects in the inspection object W based on the combined image data corrected in this manner, thereby improving the accuracy of defect detection.
[0045] [Detecting defects using machine learning models] The defect detection unit 142 may detect defects in the inspection object W using a machine learning model. The machine learning model is created by machine learning using, for example, teacher image data generated by photographing different areas of the coupling member B attached to the container A in a state where there is a defect, or teacher image data generated by photographing different areas of the coupling member B attached to the container A in a state where there is no defect. The teacher image data is, for example, a set of multiple partial image data corresponding to multiple different areas, or combined image data in which multiple partial image data are combined. The machine learning model receives image data and outputs a result of determining whether or not there is a defect in the inspection object W.
[0046] The defect detection unit 142 detects defects in the object to be inspected W based on the results output from the machine learning model by inputting to the machine learning model a plurality of partial image data or combined image data in which a plurality of partial image data are combined, which correspond to a plurality of regions of one object to be inspected W. If the machine learning model has previously been trained using teacher image data composed of a plurality of partial image data, the defect detection unit 142 can determine whether the object to be inspected W is good or bad based on the plurality of partial image data without creating combined image data by combining the plurality of partial image data, thereby shortening the processing time.
[0047] [Processing flow in inspection system S] Fig. 7 is a flowchart showing the flow of processing in the inspection system S. The flowchart shown in Fig. 7 starts at the point when the inspection system S starts inspecting the object W to be inspected.
[0048] The imaging device 2 images the object W to be inspected while it is being transported (S11). The imaging device 2 images the object W to be inspected, for example, based on the control of the inspection device 1. The image data acquisition unit 141 acquires a plurality of partial image data (S12), and the defect detection unit 142 combines the plurality of partial image data to create tentative combined image data (S13). The defect detection unit 142 creates combined image data by changing the positions of the partial image data in the tentative combined image data to correct the tentative combined image data (S14).
[0049] The defect detection unit 142 analyzes the combined image data to determine whether the inspection object W is good or bad. The defect detection unit 142 analyzes the combined image data (S15) and determines whether there is any dirt (S16) and whether there is any tear (S17). If all of these are normal (YES in S17), the defect detection unit 142 determines that the result of the inspection based on the combined image data is normal. If both the result of the inspection based on the combined image data and the result of the inspection based on the combined image data are normal, the defect detection unit 142 determines that the inspection object W is normal (S18).
[0050] If the defect detection unit 142 detects an abnormality in either S16 or S17, it determines that the inspection object W is abnormal (defective) (S19). The defect detection unit 142 repeats the processes from S11 to S19 until an operation to end the inspection is performed (NO in S20).
[0051] [Effects of Inspection Device 1] As described above, the image data acquisition unit 141 acquires a plurality of captured image data (i.e., a plurality of partial image data) generated by the imaging device 2 capturing an image of the inspection object W while the inspection object W is being transported through the inspection target range in the imaging area of the imaging device 2 with light being irradiated onto the inspection object W. Then, the defect detection unit 142 detects defects in the inspection object W based on the plurality of captured image data, each of which captures a partial area of the inspection object W. By operating in this manner, the defect detection unit 142 improves the detection accuracy of defects in the inspection object W when the inspection object W is not irradiated with light at a uniform illuminance and the illuminance varies depending on the part of the inspection object W.
[0052] In the above description, a case where the straight joining auxiliary line L is drawn on the inspection object W has been exemplified, but the inspection object W may include a predetermined auxiliary area having a shape other than a straight line. For example, the auxiliary area may be an ellipse, a wavy line, or text. The defect detection unit 142 creates the combined image data by moving at least one captured image data so that the shape of the auxiliary area in the combined image data becomes a predetermined shape stored in the storage unit 13.
[0053] In addition, in the above explanation, a container is used as an example of the object to be inspected W, but the object to be inspected W is not limited to a container, and may be any object as long as the object has a shape to which light may not be uniformly irradiated.
[0054] Although the present invention has been described above using the embodiments, the technical scope of the present invention is not limited to the scope described in the above embodiments, and various modifications and changes are possible within the scope of the gist of the present invention. For example, all or part of the device can be configured by distributing or integrating functionally or physically in any unit. In addition, new embodiments resulting from any combination of multiple embodiments are also included in the embodiments of the present invention. The effect of the new embodiment resulting from the combination combines the effect of the original embodiment. [Explanation of symbols]
[0055] 1. Inspection equipment 2. Imaging device 3. Conveyor 11 Communications Department 12 Display section 13 Storage section 14 Control section 141 Image data acquisition unit 142 Defect detection unit
Claims
1. an image data acquisition unit that acquires a plurality of pieces of image data generated by an imaging device capturing images of an object to be inspected while the object is being conveyed through an inspection target area in an imaging region of the imaging device while being irradiated with light; a defect detection unit that detects defects of the object to be inspected based on the plurality of pieces of captured image data, each of which captures a partial region of the object to be inspected; An inspection device having the above structure.
2. the plurality of captured image data are generated by capturing images of a plurality of different regions in a transport direction of the inspection object, the defect detection unit determines that the object to be inspected has a defect when detecting an abnormality of the object to be inspected in combined image data obtained by combining the plurality of captured image data.
2. The inspection device according to claim 1.
3. the plurality of captured image data are generated by capturing images of the inspection object at different timings while the inspection object is being transported in the transport direction by the imaging device, the defect detection unit detects defects of the inspection object based on the plurality of captured image data after moving at least one of the captured image data in a direction perpendicular to the transport direction so that image continuity in two adjacent captured image data pieces among the plurality of captured image data pieces is increased.
3. The inspection device according to claim 2.
4. the object to be inspected includes a linear region in the transport direction, the defect detection unit creates the combined image data by moving at least one of the captured image data so that the linear region becomes linear.
4. The inspection device according to claim 3.
5. The object to be inspected includes a predetermined auxiliary region, the defect detection unit creates the combined image data by moving at least one of the captured image data so that a shape of the auxiliary region in the combined image data becomes a predetermined shape stored in a storage unit.
4. The inspection device according to claim 3.
6. the plurality of captured image data are generated by capturing images of a plurality of different regions of the inspection object, The defect detection unit detects defects in the object by inputting the plurality of captured image data or combined image data in which the plurality of captured image data are combined into a machine learning model that is machine-learned using teacher image data generated by photographing a plurality of different areas of the object to be inspected in a state in which there is a defect, or teacher image data generated by photographing a plurality of different areas of the object to be inspected in a state in which there is no defect, and outputs a result of determining whether or not the object to be inspected has a defect.
2. The inspection device according to claim 1.
7. The computer executes acquiring a plurality of captured image data sets generated by an imaging device capturing images of an inspection object while the inspection object is being conveyed through an inspection target area in an imaging region of the imaging device while being irradiated with light; detecting defects of the object to be inspected based on the plurality of captured image data, each of which captures a partial area of the object to be inspected; An inspection method having the following features.
8. On the computer, acquiring a plurality of captured image data sets generated by an imaging device capturing images of an inspection object while the inspection object is being conveyed through an inspection target area in an imaging region of the imaging device while being irradiated with light; detecting defects of the object to be inspected based on the plurality of captured image data, each of which captures a partial area of the object to be inspected; A program for executing the above.
Citation Information
Patent Citations
Visual inspection device and visual inspection method
JP2020046310A