Anomaly detection method and anomaly detection device

A two-stage GAN-based learning model for image restoration and differential processing addresses over-detection in anomaly detection by separating imaging errors from genuine anomalies, improving detection accuracy.

JP7608857B2Active Publication Date: 2025-01-07TOYOTA JIDOSHA KK
View PDF 4 Cites 0 Cited by

Patent Information

Application Number
JP2021023265
Authority / Receiving Office
JP · JP
Patent Type
Patents
Current Assignee / Owner
Filing Date
2021-02-17
Publication Date
2025-01-07
Estimated Expiration
2041-02-17

AI Technical Summary

Technical Problem

Existing anomaly detection methods using image processing struggle to accurately distinguish between genuine anomalies and imaging errors, leading to over-detection of normal targets.

Method used

Utilizing a two-stage learning model comprising a generative adversarial network (GAN) for image restoration and differential image processing to separate imaging errors from genuine anomalies, enhancing the accuracy of anomaly detection by generating restored images and difference images that minimize over-detection.

Benefits of technology

The method improves anomaly detection accuracy by effectively removing imaging errors, thereby reducing false positives and enhancing the reliability of anomaly identification.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure 0007608857000001
    Figure 0007608857000001
  • Figure 0007608857000002
    Figure 0007608857000002
  • Figure 0007608857000003
    Figure 0007608857000003
Patent Text Reader

Abstract

To provide a technique which can reduce a failure such that a normal test object is detected as an abnormality and can improve abnormality detection accuracy in an abnormality detecting method.SOLUTION: An abnormality detecting method includes: obtaining a picked-up image obtained by picking up an image of a test object; inputting the picked-up image in a first learning model learned by using normal images obtained by picking up images of normal test objects, and generating a reproduced image; generating a difference image between the picked-up image and the reproduced image; inputting the generated difference image in a second learning model learned by using the normal difference images, and generating a reproduced difference image; and detecting an abnormality of the test object by using the difference image and the reproduced difference image.SELECTED DRAWING: Figure 2
Need to check novelty before this filing date? Find Prior Art

Description

[Technical field]

[0001] The present disclosure relates to an anomaly detection method and an anomaly detection device. [Background technology]

[0002] An image processing device is known that detects an abnormality in an image of an object to be inspected when the difference between a pseudo image generated by a neural network and the image of the object to be inspected is equal to or greater than a predetermined threshold value (for example, Patent Document 1). [Prior art documents] [Patent documents]

[0003] [Patent Document 1] JP 2020-160997 A Summary of the Invention [Problem to be solved by the invention]

[0004] In an anomaly detection method using an image of an inspection object, there is a demand for further improvement in the accuracy of detecting an anomaly in the inspection object. [Means for solving the problem]

[0005] The present disclosure can be realized in the following forms.

[0006] (1) According to one aspect of the present disclosure, there is provided an anomaly detection method, which includes acquiring an image of an inspection object, inputting the acquired image into a first learning model trained using normal images of a normal inspection object to generate a restored image, generating a difference image between the acquired image and the restored image, inputting the generated difference image into a second learning model trained using normal difference images to generate a restored difference image, and detecting an anomaly in the inspection object using the difference image and the restored difference image. According to this anomaly detection method, a restored differential image in which factors of overdetection contained in the differential image are extracted can be generated by a second learning model trained using a differential image between a captured image and a restored image. Therefore, when detecting an anomaly, factors of overdetection contained in the differential image can be distinguished from the anomaly, and the defect in which a normal test object is detected as an anomaly can be reduced or suppressed, thereby improving the accuracy of detecting an anomaly. (2) In the anomaly detection method of the above aspect, in detecting an abnormality in the inspection object, an image for abnormality determination may be generated using the difference between the difference image and the restored difference image, and an abnormality in the inspection object may be determined using the image for abnormality determination. According to the anomaly detection method of this aspect, an anomaly can be detected using an image from which factors causing overdetection contained in the difference image have been removed. (3) In the anomaly detection method of the above aspect, the first learning model may generate the restored image by removing positional deviation of the detection object in the captured image. According to this aspect of the anomaly detection method, the difference between the captured image and the restored image can be input to the second learning model, thereby generating a restored differential image that has learned the imaging error. (4) In the anomaly detection method of the above aspect, the first learning model may be a learning model using a generative adversarial network. According to this form of the anomaly detection method, the reproducibility of the image restored by the first learning model can be improved, and the accuracy of anomaly detection can be improved. (5) In the anomaly detection method of the above aspect, the second learning model may be a learning model using a generative adversarial network. According to the anomaly detection method of this aspect, it is possible to improve the reproducibility of the differential image restored by the second learning model, and to improve the accuracy of anomaly detection. (6) In the anomaly detection method of the above aspect, the first learning model and the second learning model may be the same type of learning model. According to the anomaly detection method of this embodiment, the imaging error contained in the difference image and the imaging error contained in the restored difference image tend to coincide with each other, compared with the case where different types of learning models are used. Therefore, the imaging error can be more accurately removed by the difference between the difference image and the restored difference image. The present disclosure may be realized in various forms other than the anomaly detection method, for example, in the form of an anomaly detection device, an image processing device, a manufacturing method for an anomaly detection device, a control method for an anomaly detection device, a computer program for implementing the control method, a non-transitory recording medium on which the computer program is recorded, etc. [Brief description of the drawings]

[0007] [Figure 1] FIG. 2 is a block diagram showing the internal functional configuration of the abnormality detection device. [Diagram 2] FIG. 2 is a block diagram showing an example of a functional configuration of a CPU in the abnormality detection device. [Diagram 3] FIG. 4 is a flow diagram showing an abnormality detection process executed by the abnormality detection device. [Figure 4] FIG. 4 is an explanatory diagram showing a captured image of an inspection object captured by an external device. [Diagram 5] FIG. 4 is an explanatory diagram showing an example of a restored image generated by a restored image generating unit. [Figure 6] FIG. 4 is an explanatory diagram showing an example of a difference image generated by a difference image generating unit. [Figure 7] FIG. 4 is an explanatory diagram showing an example of a restored differential image generated by a restored differential image generating unit. [Figure 8] FIG. 4 is an explanatory diagram showing an example of an image for abnormality determination generated by an image generating unit for abnormality determination; DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS

[0008] A. First embodiment: FIG. 1 is a block diagram showing an internal functional configuration of an abnormality detection device 100 according to a first embodiment of the present disclosure. The abnormality detection device 100 is a personal computer connected to an external device. The external device is, for example, a camera that captures an image of an object to be inspected by the abnormality detection device 100. In this embodiment, an image acquired by the abnormality detection device 100 is composed of an RGB input image signal composed of image signal components represented by R (red), G (green), and B (blue). The input image signal may be, for example, a YUV image signal composed of Y (luminance signal), U (first color difference signal), and V (second color difference signal), or may be a YCbCr image signal or a YPbPr image signal. The image may be a color image or a grayscale image having a luminance value of any color depth, such as 1 bit or 8 bits. The external device may be, for example, a manufacturing device for manufacturing an object to be inspected, an inspection device for inspecting an object to be inspected, or a camera provided in these devices.

[0009] The anomaly detection device 100 includes a CPU 110, which is a central processing unit, a storage unit 130, a transmission / reception unit 120, and a display unit 140. These units are connected to each other via a data bus 150 so that they can communicate with each other. The CPU 110, the storage unit 130, and the transmission / reception unit 120 can communicate with each other bidirectionally. Some or all of the processing functions of the anomaly detection device 100 may be realized, for example, by an edge or a cloud. For example, the anomaly detection device 100 may acquire an image captured by an external device via a network or the like, process the acquired image on an edge or a cloud, and then output the processing result to the outside via a network.

[0010] The CPU 110 is a microprocessor that performs overall control of the anomaly detection device 100. The storage unit 130 is, for example, a RAM, a ROM, or a hard disk drive (HDD) as a large-capacity storage medium. The HDD or ROM stores various programs for implementing the functions provided in this embodiment. The CPU 110 reads out the various programs from the HDD or ROM of the storage unit 130 and deploys them on the RAM, and executes them. As the large-capacity storage medium of the storage unit 130, a solid-state drive (SSD) may be provided instead of or in addition to the HDD.

[0011] The transmitting / receiving unit 120 communicates with an external device. In this embodiment, the transmitting / receiving unit 120 receives an image of an abnormality detection target captured by an external device via wireless communication. For example, wireless communication may be wireless communication through a wireless local network (LAN) using a 2.4 GHz band or a 5 GHz band conforming to the IEEE802.11a standard, wireless communication using a sub-giga band that is a frequency band below 1 GHz (916.5 MHz to 927.5 MHz), or wireless communication using Bluetooth (registered trademark). The transmitting / receiving unit 120 may be connected to the external device not only wirelessly but also by wired LAN such as Ethernet (registered trademark).

[0012] Display unit 140 is a display for displaying an operation screen of anomaly detection device 100 and result information of anomaly detection by anomaly detection device 100. Display unit 140 may be provided in an external device different from anomaly detection device 100, such as an inspection device. Anomaly detection device 100 may be provided with an input device, such as a keyboard, a mouse, or a touch panel.

[0013] 2 is a block diagram showing an example of a functional configuration of CPU 110 in abnormality detection device 100. CPU 110 executes various control programs stored in storage unit 130, thereby functioning as acquisition unit 111, restored image generation unit 113, difference image generation unit 115, restored difference image generation unit 117, abnormality determination image generation unit 118, and identification unit 119. Some or all of the functions of abnormality detection device 100 may be realized by a hardware circuit.

[0014] The function of each unit when the anomaly detection device 100 executes the anomaly detection process will be described. When detecting an anomaly in an inspection target, the acquisition unit 111 acquires a captured image of the inspection target from an external device. The acquisition unit 111 acquires an image of the same size as the image acquired as the learning image as the captured image of the detection target. The acquisition unit 111 outputs the acquired captured image of the inspection target to the restored image generation unit 113 and the difference image generation unit 115.

[0015] When the restored image generating unit 113 acquires the captured image of the inspection target from the acquiring unit 111, the restored image generating unit 113 generates a restored image by restoring the captured image by the trained neural network. The restored image generating unit 113 outputs the generated restored image to the differential image generating unit 115.

[0016] The difference image generating unit 115 generates a difference image between the captured image of the inspection object acquired from the acquiring unit 111 and the restored image acquired from the restored image generating unit 113. The restored image generating unit 113 generates the difference image by, for example, subtracting pixel values ​​of the restored image from pixel values ​​of the captured image. In this embodiment, the difference image is generated by subtracting, for each pixel of the captured image, a pixel of the restored image at a position corresponding to the pixel. In contrast, the difference image may be generated using the difference for each group including a plurality of pixels. The difference image generating unit 115 outputs the generated difference image to the restored difference image generating unit 117 and the abnormality determination image generating unit 118.

[0017] When the restored differential image generating unit 117 acquires the differential image from the differential image generating unit 115, the restored differential image generating unit 117 generates a restored differential image by restoring the acquired differential image using the trained neural network. The restored differential image generating unit 117 outputs the generated restored differential image to the abnormality determination image generating unit 118.

[0018] The image for abnormality determination generating unit 118 generates an image for abnormality determination using the difference between the difference image acquired from the difference image generating unit 115 and the restored difference image acquired from the restored difference image generating unit 117. The image for abnormality determination generating unit 118 generates an image for abnormality determination, for example, by subtracting pixel values ​​of the restored difference image from pixel values ​​of the difference image. In this embodiment, the image for abnormality determination is generated by subtracting, for each pixel of the difference image, a pixel of the restored difference image at a position corresponding to the pixel. The image for abnormality determination may be generated using the difference for each group including a plurality of pixels. The image for abnormality determination generating unit 118 outputs the generated image for abnormality determination to the identification unit 119.

[0019] The discrimination unit 119 detects an abnormality in the detection object by using the image for abnormality determination acquired from the image for abnormality determination generation unit 118. In this embodiment, the discrimination unit 119 determines that the detection object has an abnormality when the total value of pixel values ​​included in the image for abnormality determination is greater than a predetermined threshold value. The discrimination unit 119 outputs the abnormality determination result to the display unit 140.

[0020] A learning method of the learning model of anomaly detection device 100 will be described with reference to Fig. 2. As a preparation for executing anomaly detection processing, anomaly detection device 100 performs learning of the neural networks of restored image generation unit 113 and restored differential image generation unit 117. The neural network of restored image generation unit 113 is also called a "first learning model," and the neural network of restored differential image generation unit 117 is also called a "second learning model."

[0021] When the acquisition unit 111 acquires a learning image from an external device, it outputs the image to the restored image generation unit 113 and the restored differential image generation unit 117. In this embodiment, the acquisition unit 111 acquires an image of a normal inspection object (hereinafter also referred to as a "normal image") as the learning image. A normal inspection object means an inspection object that does not have an abnormality. The acquisition unit 111 may acquire an image of an inspection object that has an abnormality (hereinafter also referred to as an "abnormal image"), for example, if the number is a small number equal to or less than a predetermined number.

[0022] In this embodiment, the restored image generating unit 113 includes a Generative Adversarial Network (GAN) as a first learning model. Specifically, the restored image generating unit 113 includes a Conditional GAN ​​(CGAN). The restored image generating unit 113 includes a generator having a neural network that generates pseudo data, and a discriminator having a neural network that determines whether the pseudo data is true or false. When a normal image that is a learning image is input to the restored image generating unit 113, the generator generates a pseudo image. The restored image generating unit 113 trains a discriminator and a generator using the normal image and the pseudo image generated by the generator using the normal image.

[0023] In this embodiment, the restored differential image generating unit 117 includes a CGAN, which is the same type of learning model as the restored image generating unit 113, and includes a generating unit and a discriminator. In the case of learning, a normal differential image, which is a learning image, is input from the differential image generating unit 115 to the restored differential image generating unit 117. The normal differential image means a differential image between a normal image and a restored image generated using the normal image. In the case of learning the second learning model, the restored differential image generating unit 117 trains a discriminator and a generator using a normal differential image and a pseudo image generated by the generating unit using the normal differential image. The normal differential image used for learning of the restored differential image generating unit 117 may be generated, for example, using a normal image different from the normal image used for learning of the restored image generating unit 113. For example, an image prepared separately in advance may be used for learning of the restored differential image generating unit 117.

[0024] Here, the restored image generated using the normal image and the difference image between the normal image may include an image showing an imaging error included in the normal image before restoration. The imaging error is a part that can be removed from the normal image during restoration by the first learning model, and is a part that can be a cause of a defect in which a normal inspection target is detected as an abnormality. A defect in which a normal inspection target is detected as an abnormality is also called overdetection. The imaging error includes, for example, a shift or variation in the position or direction of the detection target in the captured image, and a detection variation of a part other than the detection target included in the captured image, such as a variation in the brightness of the background or a stain on the background. The second learning model is trained using a difference image including the imaging error. Therefore, the restored difference image generating unit 117 generates an image in which a part that can be removed by the restoration of the first learning model from the input captured image, that is, a part corresponding to the imaging error, is restored as a restored difference image. For the learning of the restored difference image generating unit 117, it is preferable that a large number of difference images in which the number and types of imaging errors that can be a cause of overdetection are extracted are input. According to the anomaly detection device 100 of this form, a restored difference image in which the imaging error is more clearly defined can be obtained. This increases the likelihood that the cause of overdetection can be removed, thereby improving the accuracy of anomaly detection by anomaly detection device 100. In this disclosure, "removing the cause of overdetection" means removing the cause of overdetection from the image.

[0025] Anomaly detection processing executed by anomaly detection device 100 will be described using Fig. 3 as well as Fig. 4 to Fig. 8 as appropriate. Fig. 3 is a flow diagram showing anomaly detection processing executed by anomaly detection device 100. This flow is started, for example, when the power supply of anomaly detection device 100 is turned on. This flow may be started when a captured image of an inspection target is input to acquisition unit 111, or when the power supply of an external device connected to anomaly detection device 100 is turned on. At the start of this flow, learning of the first learning model of restored image generation unit 113 using a normal image and learning of the second learning model of restored differential image generation unit 117 using a normal differential image are completed.

[0026] In step S10, the acquisition unit 111 acquires an image of the inspection target captured by an external device. FIG. 4 is an explanatory diagram showing an example of an image CP of the inspection target captured by an external device. The image CP of the inspection target is input to the acquisition unit 111 from the external device via the transmission / reception unit 120 by wireless communication. In FIG. 4, the captured image CP includes an image of a product PP as an example of the inspection target (hereinafter, also referred to as a "product image PP"). FIG. 4 shows an example of a state in which a foreign matter FM as an abnormality of the inspection target is attached to the product PP. Hereinafter, the image of the foreign matter FM is also referred to as a "foreign matter image FM". The captured image CP is an example of an abnormality image obtained by capturing an inspection target having an abnormality. The abnormality of the inspection target includes, in addition to the attachment of the foreign matter FM, various abnormalities such as dirt on the inspection target, unevenness on the surface, and missing parts. In the example of FIG. 4, the captured image CP includes an entire image of the product PP as the inspection target, but is not limited to the entire image of the product PP, and only an arbitrary position of the product PP may be captured. The acquisition unit 111 outputs the acquired captured image CP to the restored image generation unit 113 and the difference image generation unit 115.

[0027] In step S20, when the restored image generating unit 113 acquires the captured image CP shown in FIG. 4 from the acquiring unit 111, the restored image generating unit 113 generates a restored image RS by a trained first learning model. FIG. 5 is an explanatory diagram showing an example of the restored image RS generated by the restored image generating unit 113. As described above, the first learning model of the restored image generating unit 113 has completed learning using a normal image of the product image PP. Therefore, as shown in FIG. 5, the restored image RS is restored as an image close to a normal image, and the foreign matter image FM is not restored. Therefore, the restored product image PRS included in the restored image RS is generated in a state without the foreign matter image FM. At this time, the restored image RS can be restored after removing imaging errors such as a positional shift of the product PP in the captured image CP and variations in the background other than the product PP included in the captured image CP. The restored image generating unit 113 outputs the generated restored image RS to the difference image generating unit 115.

[0028] In step S30, the difference image generating unit 115 generates a difference image DP using the difference between the captured image CP shown in FIG. 4 and the restored image RS shown in FIG. 5. FIG. 6 is an explanatory diagram showing an example of the difference image DP generated by the difference image generating unit 115. The difference image DP is an image formed by the difference obtained by subtracting the pixels of the restored image RS from the pixels of the captured image CP. As shown in FIG. 6, the difference image DP includes a difference abnormal image PFM and a difference extraction image PDP. The difference abnormal image PFM is an image corresponding to the foreign matter image FM shown in FIG. 4. The difference extraction image PDP is an image corresponding to the difference obtained by subtracting the pixels of the restored product image PRS from the pixels of the product image PP. In other words, the difference extraction image PDP is an image in which the imaging error removed by the restored image generating unit 113 when the restored image RS is generated is extracted. The difference image generating unit 115 outputs the generated difference image DP to the restored difference image generating unit 117 and the abnormality judgment image generating unit 118.

[0029] In step S40, when the restored differential image generating unit 117 acquires the differential image DP from the differential image generating unit 115, the restored differential image generating unit 117 restores the differential image DP using a learned second learning model to generate a restored differential image DRS. FIG. 7 is an explanatory diagram showing an example of the restored differential image DRS generated by the restored differential image generating unit 117. As described above, the second learning model held by the restored differential image generating unit 117 has completed learning using a normal differential image. Therefore, the restored differential image DRS generated by the restored differential image generating unit 117 corresponds to an image in which the imaging error included in the differential image DP is restored. Therefore, as shown in FIG. 7, the restored differential image DRS is generated as an image close to the differential image DP that does not include the differential abnormal image PFM. The imaging error extraction image PDR is an image in which the imaging error that causes overdetection is extracted from the differential image DP, that is, an image equivalent to the difference extraction image PDP. The restored differential image generating unit 117 outputs the generated restored differential image DRS to the abnormality determination image generating unit 118.

[0030] In step S50, the image generating unit 118 for abnormality determination generates an image FDP for abnormality determination using the difference between the differential image DP and the restored differential image DRS. FIG. 8 is an explanatory diagram showing an example of the image FDP for abnormality determination generated by the image generating unit 118 for abnormality determination. The image generating unit 118 for abnormality determination generates an image FDP for abnormality determination shown in FIG. 8 using a difference obtained by subtracting the pixel values ​​of the restored differential image DRS shown in FIG. 7 from the pixel values ​​of the differential image DP shown in FIG. 6. The image FDP for abnormality determination corresponds to an image obtained by removing the difference extraction image PDP corresponding to the imaging error from the differential image DP. As shown in FIG. 8, the restored differential image DRS includes a restored differential abnormal image FFM. The restored differential abnormal image FFM corresponds to the differential abnormal image PFM of the differential image DP. The image generating unit 118 for abnormality determination outputs the generated image FDP for abnormality determination to the identification unit 119.

[0031] In step S60, the discrimination unit 119 detects the restored differential abnormal image FFM from the image for abnormality determination FDP to determine whether or not there is an abnormality. In this embodiment, when the total value of pixel values ​​included in the image for abnormality determination FDP is greater than a predetermined threshold, the discrimination unit 119 detects the restored differential abnormal image FFM as an abnormality and determines that there is an abnormality in the inspection object. When the total value of pixel values ​​included in the image for abnormality determination FDP is less than a predetermined threshold, the discrimination unit 119 determines that there is no abnormality in the inspection object. As another embodiment of the abnormality detection method using the image for abnormality determination FDP, for example, a Gaussian Mixture Model (GMM) or a Deep Autoencoder Gaussian Mixture Model (DAGMM) can be used. In this case, the discrimination unit 119 may further use a latent variable indicating an intermediate value at the time of image restoration by the restored differential image generating unit 117 in addition to the difference between the difference image DP and the restored differential image DRS. As another method of detecting the restored differential abnormal image FFM in the image for abnormality determination FDP, for example, an abnormality may be detected by extracting a feature point or a feature amount corresponding to the restored differential abnormal image FFM on the image for abnormality determination FDP. The restored differential abnormal image FFM may be detected by an operator's visual inspection of the image data of the image for abnormality determination FDP generated by the image generation unit for abnormality determination 118, and in this case, the discrimination unit 119 may be omitted. Also, for example, an abnormality may be detected by an operator visually comparing the image data of the differential image DP shown in FIG. 6 with the image data of the restored differential image DRS shown in FIG. 7, and an abnormality may be detected without generating the image for abnormality determination FDP. In this case, the image generation unit for abnormality determination 118 can be omitted. When the discrimination unit 119 finishes discriminating whether or not there is an abnormality in the inspection target, the discrimination unit 119 outputs the judgment result to the display unit 140, and this flow ends.

[0032] As described above, according to the anomaly detection device 100 of the present embodiment, a difference image DP is generated by the difference between the captured image CP and the restored image RS generated by the first learning model trained using a normal image. An abnormality in the inspection object is detected using the generated difference image DP and a restored difference image DRS generated by the second learning model trained using a normal difference image. The restored difference image DRS restores imaging errors that cause overdetection by learning using a normal difference image. By using this restored difference image DRS and the difference image DP, it is possible to distinguish between the difference abnormal image PFM of the inspection object contained in the difference image DP and the imaging errors that cause overdetection. Therefore, when detecting an abnormality, it is possible to detect the abnormality after removing the imaging errors, thereby reducing overdetection and improving the detection accuracy of the abnormality.

[0033] According to the anomaly detection device 100 of this embodiment, the discrimination unit 119 discriminates anomalies in the inspection object using an anomaly determination image FDP generated using the difference between the differential image DP and the restored differential image DRS. Therefore, anomalies can be detected using an image from which factors of overdetection contained in the differential image DP have been removed.

[0034] According to the anomaly detection device 100 of this embodiment, the first learning model removes imaging errors including positional deviation of the detection target in the captured image CP to generate a restored image RS. Therefore, the imaging errors contained in the captured image CP can be trained in the second learning model using a difference image DP between the restored image RS generated using the first learning model and the captured image CP.

[0035] According to the anomaly detection device 100 of this embodiment, the first learning model is a learning model using a generative adversarial network (GAN). Therefore, the reproducibility of the restored image RS by the first learning model can be improved, and the accuracy of anomaly detection can be improved.

[0036] According to the anomaly detection device 100 of the present embodiment, the second learning model is a learning model using a generative adversarial network (GAN). Therefore, the reproducibility of the restored differential image DRS by the second learning model can be improved, and the accuracy of anomaly detection can be improved.

[0037] According to the anomaly detection device 100 of the present embodiment, the first learning model of the restored image generating unit 113 and the second learning model of the restored differential image generating unit 117 use the same type of learning model, CGAN. Therefore, the tendency of the imaging error removed from the captured image CP by the restored image RS generated by the first learning model is more likely to match the tendency of the imaging error restored by the restored differential image DRS generated by the second learning model. As a result, the tendency of the imaging error included in the differential image DP is more likely to match the tendency of the imaging error included in the restored differential image DRS compared to an anomaly detection device having a different type of learning model. Therefore, the imaging error can be removed more accurately by the difference between the differential image DP and the restored differential image DRS.

[0038] B. Other embodiments: (B1) In the above first embodiment, an example has been shown in which CGAN is used as the first learning model of the restored image generation unit 113 and the second learning model of the restored differential image generation unit 117. In contrast, a learning model other than CGAN or GAN may be used as the learning model of at least one of the restored image generation unit 113 or the restored differential image generation unit 117, and various autoencoders such as AE (Autoencoder), VAE (Variational Autoencoder), and CVAE (Conditional Variational Autoencoder) may be used, and various GANs such as DCGAN (Deep Convolutional GAN), SRGAN, CycleGAN, and VAEGAN may be used.

[0039] The present disclosure is not limited to the above-mentioned embodiment, and can be realized in various configurations without departing from the spirit of the present disclosure. For example, the technical features of the embodiments corresponding to the technical features in each aspect described in the Summary of the Invention can be appropriately replaced or combined to solve some or all of the above-mentioned problems or to achieve some or all of the above-mentioned effects. Furthermore, if a technical feature is not described as essential in this specification, it can be appropriately deleted. [Explanation of symbols]

[0040] 100... anomaly detection device, 110... CPU, 111... acquisition unit, 113... restored image generation unit, 115... difference image generation unit, 117... restored difference image generation unit, 118... image generation unit for abnormality judgment, 119... identification unit, 120... transmission / reception unit, 130... storage unit, 140... display unit, 150... data bus, CP... captured image, DP... difference image, DRS... restored difference image, FDP... image for abnormality judgment, FFM... restored difference abnormal image, FM... foreign object image, LAN... wired, PDP... difference extracted image, PDR... captured error extracted image, PFM... difference abnormal image, PP... product image, PRS... restored product image, RS... restored image

Claims

1. 1. A method for detecting an anomaly, comprising: Acquire an image of the inspection object; inputting the captured image into a first learning model trained using a normal image obtained by capturing a normal test object, thereby generating a restored image; generating a difference image between the captured image and the restored image; The generated difference image is input to a second learning model trained using a normal difference image to generate a restored difference image; detecting an abnormality in the inspection object using the difference image and the restored difference image; The first learning model is a learning model using a generative adversarial network, The second learning model is a learning model using a generative adversarial network. Anomaly detection methods.

2. The anomaly detection method according to claim 1 , In detecting an abnormality in the inspection object, an image for determining an abnormality is generated using a difference between the difference image and the restored difference image, and an abnormality in the inspection object is determined using the image for determining an abnormality. Anomaly detection methods.

3. The abnormality detection method according to claim 1 or 2, The first learning model generates the restored image by removing a positional deviation of the object to be inspected in the captured image. Anomaly detection methods.

4. The anomaly detection method according to any one of claims 1 to 3, The first learning model and the second learning model are of the same type. Anomaly detection methods.

5. An abnormality detection device, comprising: an acquisition unit that acquires an image of an object to be inspected; a restored image generating unit that inputs a captured image and generates a restored image for a first learning model that has been trained using a normal image obtained by capturing a normal test object; a differential image generating unit that generates a differential image between the captured image and the restored image; a restored differential image generating unit that inputs the generated differential image to generate a restored differential image for a second learning model that has been trained using a normal differential image; a discrimination unit that detects an abnormality in the inspection object by using the difference image and the restored difference image, The first learning model is a learning model using a generative adversarial network, The second learning model is a learning model using a generative adversarial network. Anomaly detection device.

Citation Information

Patent Citations

  • Inspection system and inspection method

    JP2019178941A

  • Image processing device, image processing method, and program

    JP2020160997A

  • Image processing device, image processing method, and recording medium

    WO2019146538A1

  • Abnormality detection device, learning device, abnormality detection method, learning method, abnormality detection program, and learning program

    WO2020255224A1