WO2022259661A1 - 学習装置、学習プログラム、異常検出装置、および異常検出プログラム - Google Patents

学習装置、学習プログラム、異常検出装置、および異常検出プログラム Download PDF

Info

Publication number
WO2022259661A1
WO2022259661A1 PCT/JP2022/010216 JP2022010216W WO2022259661A1 WO 2022259661 A1 WO2022259661 A1 WO 2022259661A1 JP 2022010216 W JP2022010216 W JP 2022010216W WO 2022259661 A1 WO2022259661 A1 WO 2022259661A1
Authority
WO
WIPO (PCT)
Prior art keywords
unit
data
learning
noise
restored
Prior art date
Application number
PCT/JP2022/010216
Other languages
English (en)
French (fr)
Inventor
貴一 奥野
智也 岡▲崎▼
Original Assignee
コニカミノルタ株式会社
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by コニカミノルタ株式会社 filed Critical コニカミノルタ株式会社
Priority to JP2023527512A priority Critical patent/JPWO2022259661A1/ja
Publication of WO2022259661A1 publication Critical patent/WO2022259661A1/ja

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N20/00Machine learning
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/08Learning methods
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T7/00Image analysis

Definitions

  • the present invention relates to a learning device, a learning program, an anomaly detection device, and an anomaly detection program.
  • an anomaly detector that has undergone standard learning and an anomaly detector that has been trained in the field environment are prepared, and an anomaly to be inspected is determined based on the detection results of both.
  • Anomaly detection systems are known.
  • the frequency of the inspection object including abnormality is often low, so it is difficult to sufficiently prepare the image data including the inspection object including the abnormality. Therefore, an image to be inspected is input to a trained model obtained by learning an image of a normal inspection object (hereinafter also referred to as a "normal image”) as training data, and the input and output data are compared.
  • a technique for detecting an abnormality in an inspection object has been proposed.
  • Patent Document 1 discloses a technique for designing a loss function on the premise that variations of normal images to be learned are generated based on a normal distribution, and for learning a joint probability model.
  • the present invention has been made to solve such problems, and is a learning device capable of preventing deterioration in image restoration accuracy even when image variations are based on distributions other than the normal distribution. , a learning program, an anomaly detection device, and an anomaly detection program.
  • a data acquisition unit that acquires training data composed of normal data to be inspected; an encoder unit that extracts a feature amount of the training data acquired by the data acquisition unit; a noise addition unit that adds noise; a decoder unit that restores the training data from the feature amount to which noise is added by the noise addition unit; and the training data and the restored data restored by the decoder unit. and a learning unit that updates parameters of the encoder unit and the decoder unit.
  • the learning unit updates the parameters of the encoder unit and the decoder unit so that the data restored by the decoder unit becomes normal data when the training data is input to the encoder unit,
  • the learning device according to (1) above, which learns the encoder section and the decoder section.
  • a data acquisition unit that acquires data to be inspected; an encoder unit and a decoder unit whose parameters have been updated in the learning device according to any one of (1) to (5) above; a score calculation unit for calculating an abnormality score of the inspection target data based on the input inspection target data and the restored data restored by the decoder unit; and an abnormality score calculated by the score calculation unit. and an abnormality determination unit that determines an abnormality of the inspection object based on the above.
  • the variation of the normal image is increased. Therefore, even if the variation of the normal image is based on a distribution other than the normal distribution, it is possible to prevent the restoration accuracy of the normal image from deteriorating.
  • FIG. 1 is a schematic block diagram illustrating the hardware configuration of a learning device according to one embodiment
  • FIG. 2 is a functional block diagram illustrating main functions of a control unit of the learning device shown in FIG. 1
  • FIG. 3 is a schematic diagram for explaining the structure of a generative model of the image processing unit shown in FIG. 2
  • FIG. 3 is a flowchart illustrating a processing procedure of a learning method of the learning device shown in FIG. 1
  • FIG. 8 is a listing showing an example of code for a noise creating function for the inspection process shown in FIG. 7; 4 is a functional block diagram illustrating main functions of a control unit of the abnormality detection device; FIG. 5 is a flowchart illustrating a processing procedure of an abnormality detection method for an abnormality detection device;
  • a learning device a learning program, an abnormality detection device, and an abnormality detection program according to embodiments of the present invention will be described below with reference to the drawings.
  • the same elements are denoted by the same reference numerals, and redundant description is omitted.
  • FIG. 1 is a schematic block diagram illustrating the hardware configuration of a learning device according to one embodiment
  • FIG. 2 is a functional block diagram illustrating main functions of the control section of the learning device shown in FIG.
  • FIG. 3 is a schematic diagram for explaining the structure of the generative model of the image processing unit shown in FIG.
  • the learning device 100 acquires training data consisting of normal images to be inspected (for example, images of non-defective industrial products), and uses the training data to learn a generative model configured by a neural network.
  • the abnormality detection device 200 which will be described later, uses the learned model learned by the learning device 100 to inspect the inspection target.
  • the inspection target is not particularly limited, but includes, for example, parts used in industrial products. Inspection includes detection of abnormalities such as folds, bends, chips, scratches, and stains.
  • the learning device 100 has a control unit 110, a communication unit 120, and an operation display unit . These components are connected to each other via bus 101 .
  • the learning device 100 can be, for example, a computer such as a personal computer or a server.
  • the control unit 110 has a CPU (Central Processing Unit) 111, a RAM (Random Access Memory) 112, a ROM (Read Only Memory) 113, and an auxiliary storage unit 114.
  • CPU Central Processing Unit
  • RAM Random Access Memory
  • ROM Read Only Memory
  • the CPU 111 executes programs such as an OS (Operating System) developed in the RAM 112 and a learning program, and controls the operation of the learning device 100 .
  • the learning program is stored in advance in ROM 113 or auxiliary storage unit 114 .
  • the RAM 112 stores data temporarily generated by the processing of the CPU 111 and the like.
  • the ROM 113 stores programs executed by the CPU 111, data, parameters, and the like used for executing the programs.
  • the auxiliary storage unit 114 has, for example, an HDD (Hard Disk Drive), an SSD (Solid State Drive), and the like.
  • the communication unit 120 is an interface circuit (for example, a LAN card, etc.) for communicating with an external device via a network.
  • an interface circuit for example, a LAN card, etc.
  • the operation display unit 130 has an input unit and an output unit.
  • the input unit includes, for example, a keyboard, mouse, etc., and is used by the user to input characters using the keyboard, mouse, etc., and to perform various instructions (inputs) such as various settings.
  • the output unit has a display, and displays training data, restored images, test results of the test object, and the like.
  • the output unit has a speaker, and can notify the user of the test result by voice.
  • the inspection target is photographed by an imaging device such as a camera, for example.
  • the imaging device transmits image data of the photographed normal inspection object to the learning device 100 .
  • the learning device 100 acquires image data as training data.
  • the normal image of the inspection target captured in advance by the imaging device is stored in a storage device outside the learning device 100 .
  • the learning device 100 sequentially acquires a predetermined number of normal images to be inspected stored in a storage device as training data.
  • the storage device desirably stores training data consisting of a plurality of (for example, several tens to tens of thousands) of normal images.
  • the imaging device is installed in the inspection process, photographs the imaging range that includes the object to be inspected, and outputs image data that includes the object to be inspected.
  • the imaging device outputs, for example, data of a black-and-white image or a color image of the inspection object of predetermined pixels (for example, 128 pixels ⁇ 128 pixels).
  • control unit 110 functions as an image acquiring unit 210, an image processing unit 220, a noise adding unit 230, and a learning unit 240 by the CPU 111 executing a learning program.
  • the image acquisition section 210 functions as a data acquisition section and acquires training data by cooperating with the communication section 120 .
  • the image acquisition unit 210 acquires the training data of the inspection target from, for example, an imaging device or a storage device external to the learning device 100 .
  • the image acquisition unit 210 transmits training data to the image processing unit 220 .
  • the image processing unit 220 has, for example, a neural network that functions as a generative model having an encoder/decoder structure.
  • a neural network extracts a feature amount from a normal image and generates a restored image of the normal image based on the extracted feature amount.
  • the encoder-decoder structure has an input layer, one or more hidden layers (hidden layers), and an output layer.
  • the number (for example, M) of neurons (arithmetic units (indicated by "O" in the figure)) in the input layer and the output layer is the same, and a specific intermediate layer (the layer described as "connection layer” in the figure)
  • the number of neurons in (eg, L) is less than the number of neurons in the input and output layers (ie, M>L). This reduces the number of neurons, ie, the number of dimensions, for representing features of normal images.
  • the encoder 221 is from the input layer to the connection layer
  • the decoder 223 is from the connection layer to the output layer.
  • the features of the normal image can be extracted as feature quantities 222 in the connection layer.
  • the feature quantity 222 can be represented by a vector, for example.
  • the noise addition unit 230 adds noise to the feature amount 222 of the normal image extracted by the encoder 221.
  • the noise adding section 230 has a noise creation function that creates noise following an arbitrary distribution.
  • the noise creation function adds, for example, noise following a predetermined probability distribution (eg, binomial distribution) to the vector of features 222 .
  • the distribution of each vector with added noise spreads out according to the distribution of the noise. This increases the variation of normal images.
  • the normal image variation follows the binomial distribution.
  • the normal image variation follows the normal distribution.
  • the probability distribution is not limited to the binomial distribution and the normal distribution, and may be other than these.
  • the feature amount 222 corresponding to the normal image can be increased in accordance with the noise distribution. Therefore, it is possible to effectively increase the variation of normal images in machine learning. As a result, as will be described later, it is possible to deal with variations in normal images due to differences in the attributes of inspection objects and imaging conditions, and the robustness of image restoration is improved. A specific example of the noise creation function will be described later.
  • the learning unit 240 uses the training data to learn the neural network of the image processing unit 220.
  • the learning unit 240 operates the encoder 221 and the decoder 223 so that the image (restored data) restored by the decoder 223 (decoder unit) becomes a normal image (normal data) when the training data is input to the encoder 221 (encoder unit). learn.
  • the learning unit 240 calculates an error function from the restored image and the normal image, and adjusts the weight parameters of the neural network and the like by back propagation so that the error function becomes small. Update. Learning proceeds by updating each parameter of the neural network for each normal image.
  • the noise creation function of the noise addition unit 230 adds noise that follows an arbitrary distribution to the feature quantity, and the learning unit 240 learns the distribution of the feature quantity as in Patent Document 1 described above. , is configured to learn only features. Therefore, the noise creating function does not participate in error backpropagation. (learning method)
  • FIG. 4 is a flowchart illustrating the processing procedure of the learning method of the learning device shown in FIG. The processing shown in the flowchart of FIG. 4 is implemented by the CPU 111 executing a learning program.
  • FIG. 5 is a schematic diagram illustrating manufacturing and inspection steps of a component.
  • training data is acquired (step S101).
  • the image acquisition unit 210 acquires training data made up of normal images from, for example, a storage device external to the learning device 100 .
  • the encoder 221 extracts the feature quantity of the training data acquired by the image acquisition section 210 .
  • noise is added to the feature amount (step S103).
  • the noise addition unit 230 adds noise generated by the noise creation function to the feature amount of the normal image extracted by the encoder 221 .
  • Noise has, for example, a predetermined probability distribution, and by adding noise, the feature amount of the normal image spreads according to the probability distribution. As a result, the variation of normal images can be increased.
  • step 1 is a step of processing a metal material using a processing tool such as a drill or a processing machine such as a milling cutter.
  • a processing tool such as a drill or a processing machine such as a milling cutter.
  • Mr. A and Mr. B are supposed to perform the cutting work on a daily basis (work shift).
  • Step 2 is a step of polishing the processed member processed in step 1 using a polishing tool such as a whetstone.
  • the worker is a specific worker (eg, Mr. C) who may use two types of polishing tools.
  • step 1 there may be slight differences in the finish of cutting depending on whether the worker is Mr. A or Mr. B, and the appearance may differ, but it is assumed that a good product (normal image) can be obtained in either case.
  • step 2 depending on whether the polishing tool used is C or D, there may be a slight difference in the finish of polishing and the appearance may differ, but in both cases a good product (normal image) can be obtained. shall be In this way, the difference in the execution conditions of each process before the appearance inspection becomes a disturbance, which causes variations in the normal image.
  • FIG. 6 is a list showing an example of the code of the noise creating function for the manufacturing and inspection process shown in FIG.
  • the random numbers in the range of 0 to 1 generated by the random function exceed the distribution range of "the probability that the worker is Mr. A” and the "probability that the polishing tool is C , add noise P(noise_p) to the current value of the feature (third line of the list).
  • noise Q noise Q (noise_q) is added to the current value of the feature amount.
  • the noise to be added can be appropriately changed by the judgment of the person in charge at the site.
  • the training data is restored from the feature amount (step S104).
  • the decoder 223 restores training data from the feature amount to which noise has been added by the noise adding section 230 .
  • step S105 update the parameters of the encoder 221 and decoder 223 (step S105).
  • the learning unit 240 learns the encoder 221 and the decoder 223 by updating the parameters of the encoder 221 and the decoder 223 so that the image restored by the decoder 223 is a normal image.
  • the image acquisition unit 210 acquires training data composed of normal images to be inspected, and the encoder 221 extracts the feature amount of the training data.
  • the noise addition unit 230 adds arbitrary noise to the feature amount of the normal image extracted by the encoder 221, and the decoder 223 restores the training data from the feature amount to which the noise is added.
  • Learning unit 240 updates the parameters of encoder 221 and decoder 223 based on the training data and the restored data. (Another example of a noise creating function)
  • a normal image of the human body can be a normal image of all or part of the human body.
  • FIG. 7 is a schematic diagram illustrating the human body examination process. Imaging of a human body is usually accompanied by various disturbances. For example, it is assumed that disturbance 1 and disturbance 2 occur in imaging of a patient.
  • the disturbance 1 is caused by, for example, the attributes of the person to be photographed, such as gender and age. That is, the normal image of the human body may differ depending on whether the subject is male or female. Also, the normal image may differ depending on the age of the subject.
  • disturbance 2 is caused by shooting conditions such as the person in charge of shooting and the shooting device manufacturer. That is, since there are differences in imaging methods and imaging techniques depending on the person in charge of imaging (Mr. D, Ms. F), variations within an allowable range may occur with respect to normal images. In addition, since the device configuration differs depending on the manufacturer (G company, H company) of the imaging device, variations within the allowable range may occur with respect to the normal image.
  • disturbances that occur before visual inspection cause variations in normal images (that is, variations).
  • the distribution of variations is considered to follow a binomial distribution depending on the ratio of men and women and the status of the person in charge of photography.
  • FIG. 8 is a list showing an example of the code of the noise creation function for the inspection process shown in FIG.
  • the random numbers in the range of 0 to 1 generated by the random function exceed the distribution range of ⁇ probability that the subject is male'' and ⁇ the imaging device manufacturer is company G. If the distribution range of "probability" is exceeded, noise R (noise_r) is added to the current value of the feature (third line of the list). On the other hand, if the 4th and 5th lines of the list satisfy the "probability that the imaging device manufacturer is Company H", noise S (noise_s) is added to the current value of the feature amount.
  • the learning device 100 of the present embodiment by adding arbitrary noise to the feature amount extracted from the normal image by the encoder 221, the variation of the normal image is increased. Therefore, even if the variation of the normal image is based on a distribution other than the normal distribution, it is possible to prevent the restoration accuracy of the normal image from deteriorating. (Abnormality detection device)
  • the hardware configuration of the anomaly detection device can be the same as the hardware configuration of the learning device 100 shown in FIG. 1 (for example, computers such as personal computers and servers). In order to avoid duplication of description, a detailed description of the hardware configuration of the abnormality detection device will be omitted.
  • FIG. 9 is a functional block diagram illustrating major functions of the control unit 300 of the abnormality detection device.
  • the control unit 300 has an image acquisition unit 310 , an image processing unit 320 , a score calculation unit 330 and an abnormality determination unit 340 .
  • the image acquisition unit 310 acquires an input image.
  • the input image is an image to be inspected whose normality/abnormality is unknown, and may be an image of an inspection object containing an abnormality (hereinafter referred to as an "abnormal image") or a normal image.
  • the image acquisition section 310 transmits the acquired input image to the image processing section 320 .
  • the image processing unit 320 has, for example, a neural network that functions as a generative model having an encoder/decoder structure.
  • the neural network of this embodiment has an encoder 321 and a decoder 323, and is pre-learned using training data by the learning device 100 shown in FIGS.
  • the neural network uses feature extraction to extract only the essential elements of the input image, and restores the image using the extracted feature values to generate and output a restored image in which unnecessary elements are removed from the input image. . That is, since the neural network learns without using abnormal images as training data, it is configured to be able to generate feature amounts corresponding to normal images, and to generate feature amounts corresponding to abnormal images. Quantities cannot be generated and are not reproducible.
  • the input image includes an image of the part M1 to be inspected. It is assumed that an abnormality (scratches S1 and S2) occurs in the part M1 during the manufacturing process.
  • T1 is the original texture of the normal part M1.
  • the restored image is an image in which only essential elements are left from the image of the component M1 of the input image and unnecessary elements are removed.
  • the texture T1 is originally included in the part M1, so it is restored, while the scratches S1 and S2 are not restored because they are abnormal.
  • the encoder 321 extracts feature quantities from the input image. That is, the encoder 321 compresses the input image and generates a feature quantity 322 with a dimension lower than the dimension of the feature quantity originally possessed by the input image.
  • a decoder 323 restores the input image based on the feature quantity 322 .
  • Encoder 321 preferably compresses the features of the input image to the extent that decoder 323 can reproduce the essence of the input image. That is, it is preferable that the feature quantity 322 has the minimum required dimension that can reproduce the essence of the input image.
  • the input image has too many features or the compression of the features of the input image is insufficient, or if the input image contains an abnormality to be inspected when restoring the input image, This anomaly can also be reproduced.
  • the input image has too few features or the features of the input image are compressed excessively, the reproducibility of the normal input image may deteriorate when restoring the input image. It may be the case that the pixel level of an image does not reach a detectable level.
  • the score calculation unit 330 calculates the abnormality score of the input image based on the input image (data to be inspected) input to the encoder 321 and the restored image (restored data) of the input image restored by the decoder 323. . More specifically, the score calculator 330 calculates the difference between the input image and the restored image as the abnormality score.
  • the abnormality determination section 340 determines abnormality of the inspection object based on the abnormality score calculated by the score calculation section 330 .
  • the abnormality determination unit 340 for example, compares the abnormality score with a predetermined threshold, and determines the abnormality of the inspection target based on the comparison result. (Abnormality detection method)
  • FIG. 10 is a flowchart illustrating the processing procedure of the abnormality detection method of the abnormality detection device. The processing of the flowchart shown in the figure is realized by the CPU 111 executing an abnormality detection program.
  • an input image is acquired (step S201).
  • the image acquisition unit 310 acquires, as an input image, for example, an image of an inspection object captured by an imaging device external to the abnormality detection device.
  • the input image can be an abnormal image or a normal image to be inspected.
  • the feature amount of the input image is extracted (step S202).
  • the encoder 321 extracts feature amounts of the input image. Encoder 321 is trained in advance by learning device 100 using training data.
  • a decoder 323 restores an input image from the feature amount extracted by the encoder 321 .
  • the decoder 323 is trained in advance by the learning device 100 using training data.
  • the score calculator 330 calculates the difference between the input image and the restored image of the input image restored by the decoder 323 as an abnormality score.
  • an abnormality of the inspection target is determined (step S205).
  • the abnormality determination section 340 determines abnormality of the inspection object based on the abnormality score calculated by the score calculation section 330 . More specifically, the abnormality determination unit 340 determines that the inspection object is abnormal when the abnormality score is higher than a predetermined threshold, and determines that the inspection object is normal when the score is lower than the threshold. For example, if the maximum value of the abnormality score map for the input image is higher than a predetermined threshold, the abnormality determination unit 340 determines that the inspection target is abnormal, and if it is lower than the threshold, determines that the inspection target is normal. judge.
  • the anomaly score map maps the anomaly score corresponding to each pixel of the input image.
  • the average value of the abnormality score map is higher than a predetermined threshold value, it may be determined that the test object is abnormal, and if it is lower than the threshold value, it may be determined that the test object is normal.
  • the determination result is transmitted to the operation display unit 130 as the inspection result of the inspection target, and the inspection result is displayed on the display.
  • learning algorithms so that neural networks (generative models) can be learned on the cloud.
  • the user can set/change learning-related settings (e.g., noise settings), set/change various algorithms, and instruct learning from a location (e.g., head office) away from the manufacturing site (manufacturing line or factory). can.
  • the learned generation model can be shared via the cloud.
  • a suitable trained generation model can be selected according to the inspection object (eg, parts, human body, etc.) at the site (eg, manufacturing line, factory, hospital, etc.).
  • inference-related algorithms are implemented in the cloud, and input images are sent to the cloud each time they are acquired using the 5th generation mobile communication system (hereinafter referred to as "5G") from the site. .
  • 5G 5th generation mobile communication system
  • learning and inference processing can be advanced and highly accurate.
  • multiple devices imaging devices
  • capture images of the inspection target send the group of images to the cloud
  • change the combination of algorithms by combining the images, etc. perform integrated processing in the cloud
  • feed back the inferred results to the site. can.
  • the cloud selects a generative model depending on the image to be inspected and sends the selected generative model to the edge.
  • the generative model is trained, and inference is processed using the trained generative model. This makes it possible to achieve central management of generative models, on-the-fly switching, edge processing to reduce the processing load on the cloud, and real-time inference at the same time.
  • the results of learning and inference processing are sent to the cloud, post-processing (e.g., template matching, post-process selection) is performed on the cloud, the final judgment result is calculated, and the calculation result is sent to the edge You can also send to This makes it possible to centrally manage post-processing setting changes and the like on the cloud.
  • post-processing e.g., template matching, post-process selection
  • the above-described learning device, learning program, abnormality detection device, and abnormality detection program have described the main configurations in describing the features of the above-described embodiments, and are not limited to the above-described configurations. , can be modified in various ways. Moreover, the configuration provided in a general abnormality detection device or the like is not excluded.
  • steps may be omitted from the above-described flowchart, and other steps may be added. Also, part of each step may be executed simultaneously, or one step may be divided into a plurality of steps and executed.
  • the present invention is not limited to such a case, and illustrations, figures, colors, etc. It can also be subject to inspection.
  • image data is used as training data
  • the present invention is not limited to such a case, and text data, voice data, etc. can also be used.
  • means and methods for performing various processes in the learning device and the abnormality detection device described above can be realized by either a dedicated hardware circuit or a programmed computer.
  • the program may be provided by a computer-readable recording medium such as a USB memory or a DVD (Digital Versatile Disc)-ROM, or may be provided online via a network such as the Internet.
  • the program recorded on the computer-readable recording medium is usually transferred to and stored in a storage unit such as a hard disk.
  • the above program may be provided as independent application software, or may be incorporated as one function into the software of the learning device and the abnormality detection device. This application is based on Japanese Patent Application No. 2021-096337 filed on June 9, 2021, the disclosure of which is incorporated by reference in its entirety.
  • 100 learning device 110 control unit, 111 CPUs, 112 RAM, 113 ROMs, 114 auxiliary storage unit, 120 communication unit, 130 operation display unit, 210 image acquisition unit; 220 image processing unit; 221 encoder, 222 features, 223 decoder, 230 noise adding unit, 240 learning department, 300 control unit, 310 image acquisition unit; 320 image processing unit, 321 encoder, 322 features, 323 decoder, 330 score calculator, 340 Abnormality determination unit.

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • Software Systems (AREA)
  • General Physics & Mathematics (AREA)
  • Computing Systems (AREA)
  • Mathematical Physics (AREA)
  • Evolutionary Computation (AREA)
  • Data Mining & Analysis (AREA)
  • Artificial Intelligence (AREA)
  • Computer Vision & Pattern Recognition (AREA)
  • General Engineering & Computer Science (AREA)
  • Life Sciences & Earth Sciences (AREA)
  • Health & Medical Sciences (AREA)
  • Medical Informatics (AREA)
  • Biomedical Technology (AREA)
  • Biophysics (AREA)
  • Computational Linguistics (AREA)
  • General Health & Medical Sciences (AREA)
  • Molecular Biology (AREA)
  • Image Analysis (AREA)
  • Image Processing (AREA)

Abstract

【課題】正常画像のバリエーションが正規分布以外の分布に基づく場合であっても、正常画像の復元精度が低下することを防止できる、学習装置、学習プログラム、異常検出装置、および異常検出プログラムを提供する。 【解決手段】学習装置は、データ取得部210、エンコーダー部221、ノイズ付加部230、デコーダー部223、および学習部240を有する。データ取得部210は、検査対象の正常データからなる訓練データを取得する。エンコーダー部221は、訓練データの特徴量を抽出する。ノイズ付加部230は、特徴量にノイズを付加する。デコーダー部223は、ノイズが付加された特徴量から訓練データを復元する。学習部240は、訓練データと、デコーダー部223によって復元された復元データとに基づいて、エンコーダー部221およびデコーダー部223のパラメーターを更新する。

Description

学習装置、学習プログラム、異常検出装置、および異常検出プログラム
 本発明は、学習装置、学習プログラム、異常検出装置、および異常検出プログラムに関する。
 近年、ニューラルネットワークに検査対象の画像の特徴量を学習させて学習済みモデルを生成し、この学習済みモデルを使用して検査対象の検査を行う、機械学習による検査方法が提案されている。
 例えば、このような検査方法として、標準的な学習を行った異常検出器と、現場環境で学習させた異常検出器とを用意し、両者の検出結果に基づいて、検査対象の異常を判定する異常検出システムが知られている。しかし、検査対象が正常である場合に比べて、検査対象に異常が含まれている頻度は低いことが多いので、検査対象に異常が含まれている画像データを十分に準備することは難しい。そこで、正常な検査対象の画像(以下、「正常画像」ともいう)を訓練データとして学習することで得られた学習済みモデルに、検査対象の画像を入力し、入出力のデータを比較することで検査対象の異常を検出する技術が提案されている。
 これに関連して、下記特許文献1には、学習対象の正常画像のバリエーションが正規分布に基づいて生成された前提で損失関数を設計し、同時確率モデルを学習する技術が開示されている。
特開2020-119605号公報
 しかし、この技術では、同時確率モデルにおいて特徴量の分布を学習する際に、既定分布と推測分布のカルバック・ライブラ・ダイバージェンス(KLD:Kullback-Leibler Divergence)を最大化するように損失を設計する必要があり、正規分布以外の分布の損失設計が困難である。そのため、正常画像のバリエーションが正規分布以外の分布に基づく場合、正常画像の復元精度が低下する可能性がある。
 本発明は、このような問題を解決するためになされたものであり、画像のバリエーションが正規分布以外の分布に基づく場合であっても、画像の復元精度が低下することを防止できる、学習装置、学習プログラム、異常検出装置、および異常検出プログラムを提供することを目的とする。
 本発明の上記課題は、以下の手段によって解決される。
 (1)検査対象の正常データからなる訓練データを取得するデータ取得部と、前記データ取得部によって取得された訓練データの特徴量を抽出するエンコーダー部と、前記エンコーダー部によって抽出された特徴量にノイズを付加するノイズ付加部と、前記ノイズ付加部によってノイズが付加された前記特徴量から前記訓練データを復元するデコーダー部と、前記訓練データと、前記デコーダー部によって復元された復元データとに基づいて、前記エンコーダー部および前記デコーダー部のパラメーターを更新する学習部と、を有する、学習装置。
 (2)前記学習部は、前記訓練データを前記エンコーダー部に入力した場合に、前記デコーダー部による復元データが正常データとなるように、前記エンコーダー部および前記デコーダー部のパラメーターを更新することにより、前記エンコーダー部および前記デコーダー部を学習する、上記(1)に記載の学習装置。
 (3)前記ノイズ付加部は、所定の確率分布に従うノイズを付加する、上記(1)または(2)に記載の学習装置。
 (4)前記確率分布は、二項分布である、上記(3)に記載の学習装置。
 (5)前記正常データは、正常画像である、上記(1)~(4)のいずれか1つに記載の学習装置。
 (6)検査対象の正常データからなる訓練データを取得する取得ステップと、エンコーダー部によって前記訓練データの特徴量を抽出する抽出ステップと、前記抽出ステップにおいて抽出された特徴量にノイズを付加する付加ステップと、前記付加ステップにおいてノイズが付加された前記特徴量から、デコーダー部によって前記訓練データを復元する復元ステップと、前記訓練データと、前記復元ステップにおいて復元された復元データとに基づいて、前記エンコーダー部および前記デコーダー部のパラメーターを更新する更新ステップと、を含む処理をコンピューターに実行させるための学習プログラム。
 (7)検査対象のデータを取得するデータ取得部と、上記(1)~(5)のいずれか1つに記載の学習装置においてパラメーターが更新されたエンコーダー部およびデコーダー部と、前記エンコーダー部に入力される前記検査対象のデータと、前記デコーダー部によって復元される復元データとに基づいて、前記検査対象のデータの異常スコアを算出するスコア算出部と、前記スコア算出部によって算出された異常スコアに基づいて、前記検査対象の異常を判定する異常判定部と、を有する、異常検出装置。
 (8)前記スコア算出部は、前記検査対象のデータと、前記復元データとの差分を異常スコアとして算出する、上記(7)に記載の異常検出装置。
 (9)検査対象のデータを取得する取得ステップと、上記(1)~(5)のいずれか1つに記載の学習装置においてパラメーターが更新されたエンコーダー部により、前記検査対象のデータの特徴量を抽出する抽出ステップと、前記学習装置によって学習されたデコーダー部により、前記特徴量から前記検査対象のデータの復元する復元ステップと、前記検査対象のデータと、前記デコーダー部によって復元された復元データとに基づいて、前記検査対象のデータの異常スコアを算出する算出ステップと、前記算出ステップにおいて算出された異常スコアに基づいて、前記検査対象の異常を判定する判定ステップと、を含む処理をコンピューターに実行させるための異常検出プログラム。
 本発明によれば、エンコーダー部によって正常画像から抽出された特徴量にノイズを付加することにより、正常画像のバリエーションを増加させる。したがって、正常画像のバリエーションが正規分布以外の分布に基づく場合であっても、正常画像の復元精度が低下することを防止できる。
一実施形態に係る学習装置のハードウェア構成を例示する概略ブロック図である。 図1に示す学習装置の制御部の主要な機能を例示する機能ブロック図である。 図2に示す画像処理部の生成モデルの構造を説明するための模式図である。 図1に示す学習装置の学習方法の処理手順を例示するフローチャートである。 部品の製造および検査工程を例示する模式図である。 図5に示す製造および検査工程について、ノイズ作成関数のコードの一例を示すリストである。 人体の検査工程を例示する模式図である。 図7に示す検査工程について、ノイズ作成関数のコードの一例を示すリストである。 異常検出装置の制御部の主要な機能を例示する機能ブロック図である 異常検出装置の異常検出方法の処理手順を例示するフローチャートである。
 以下、図面を参照して、本発明の実施形態に係る学習装置、学習プログラム、異常検出装置、および異常検出プログラムについて説明する。なお、図面において、同一の要素には同一の符号を付し、重複する説明を省略する。
 (学習装置)
 図1は一実施形態に係る学習装置のハードウェア構成を例示する概略ブロック図であり、図2は図1に示す学習装置の制御部の主要な機能を例示する機能ブロック図である。また、図3は、図2に示す画像処理部の生成モデルの構造を説明するための模式図である。
 学習装置100は、検査対象の正常画像(例えば、工業製品の良品の画像)からなる訓練データを取得し、訓練データを使用して、ニューラルネットワークによって構成される生成モデルを学習する。後述する異常検出装置200は、学習装置100によって学習された学習済みモデルを使用して、検査対象の検査を行う。検査対象は、特に限定されるものではないが、例えば、工業製品に使用される部品等が挙げられる。検査には、折れ、曲げ、欠け、傷、および汚れ等の異常の検出が含まれる。
 図1に示すように、学習装置100は、制御部110、通信部120、および操作表示部130を有する。これらの構成要素は、バス101を介して互いに接続される。学習装置100は、例えば、パーソナルコンピューター、サーバー等のコンピューターでありうる。
 制御部110は、CPU(Central Processing Unit)111、RAM(Random Access Memory)112、ROM(Read Only Memory)113、および補助記憶部114を有する。
 CPU111は、RAM112に展開されたOS(Operating System)、学習プログラム等のプログラムを実行し、学習装置100の動作制御を行う。学習プログラムは、ROM113または補助記憶部114に予め保存されている。また、RAM112は、CPU111の処理によって一時的に生じたデータ等を格納する。ROM113は、CPU111によって実行されるプログラムや、プログラムの実行に使用されるデータ、パラメーター等を記憶する。補助記憶部114は、例えばHDD(Hard Disk Drive)、SSD(Solid State Drive)等を有する。
 通信部120は、ネットワークを介して、外部の装置と通信するためのインターフェース回路(例えばLANカード等)である。
 操作表示部130は、入力部および出力部を有する。入力部は、例えば、キーボード、マウス等を備え、キーボード、マウス等による文字入力、各種設定等の各種指示(入力)をユーザーが行うために利用される。また、出力部は、ディスプレイを備え、訓練データ、復元画像、検査対象の検査結果等を表示する。また、出力部は、スピーカーを有し、検査結果を音声でユーザーに通知することもできる。
 また、図示を省略しているが、検査対象は、例えば、カメラ等の撮像装置によって撮影される。撮像装置は、撮影された正常な検査対象の画像データを学習装置100に送信する。学習装置100は、画像データを訓練データとして取得する。あるいは、撮像装置によって予め撮影された検査対象の正常画像は、学習装置100の外部にある記憶装置に保存される。学習装置100は、記憶装置に保存されている所定枚数の検査対象の正常画像を訓練データとして順次取得する。記憶装置には、複数(例えば、数十~数万枚)の正常画像からなる訓練データが保存されていることが望ましい。
 撮像装置は、例えば、検査対象が工業製品の部品である場合、検査工程に設置され、検査対象を包含する撮影範囲を撮影し、検査対象が含まれる画像のデータを出力する。撮像装置は、例えば、所定ピクセル(例えば、128ピクセル×128ピクセル)の検査対象の白黒画像またはカラー画像のデータを出力する。
 図2に示すように、制御部110は、CPU111が学習プログラムを実行することにより、画像取得部210、画像処理部220、ノイズ付加部230、および学習部240として機能する。
 画像取得部210は、データ取得部として機能し、通信部120と協働することにより、訓練データを取得する。画像取得部210は、例えば、学習装置100の外部の撮像装置または記憶装置から検査対象の訓練データを取得する。画像取得部210は、画像処理部220に訓練データを送信する。
 画像処理部220は、例えば、エンコーダー・デコーダー構造を有する生成モデルとして機能するニューラルネットワークを有する。ニューラルネットワークは、正常画像から特徴量を抽出し、抽出された特徴量に基づいて、正常画像の復元画像を生成する。
 より具体的には、図3に示すように、エンコーダー・デコーダー構造は、入力層、1層以上の中間層(隠れ層)、および出力層を有する。入力層および出力層におけるニューロン(演算ユニット(図中「〇」で示す))の個数(例えば、M個)は等しく、特定の中間層(同図では「接続層」と記載されている層)のニューロンの個数(例えば、L個)は入力層および出力層のニューロンの個数よりも少ない(すなわち、M>L)。これにより、正常画像の特徴を表すためのニューロンの個数、すなわち次元数が削減される。入力層から接続層まではエンコーダー221であり、接続層から出力層まではデコーダー223である。正常画像の特徴は、接続層において、特徴量222として取り出すことができる。特徴量222は、例えば、ベクトルで表されうる。
 ノイズ付加部230は、エンコーダー221によって抽出された正常画像の特徴量222に対してノイズを付加する。本実施形態では、ノイズ付加部230は、任意の分布に従うノイズを作成するノイズ作成関数を有する。ノイズ作成関数は、例えば、所定の確率分布(例えば、二項分布)に従うノイズを、特徴量222のベクトルに付加する。ノイズが付加された各々のベクトルの分布は、ノイズの分布に応じて広がる。これにより、正常画像のバリエーションが増加する。二項分布に従うノイズが特徴量222に付加された場合、正常画像のバリエーションは、二項分布に従う。一方、特徴量222に正規分布に従うノイズが付加された場合、正常画像のバリエーションは、正規分布に従う。なお、確率分布は、二項分布、正規分布に限定されず、これら以外であってよい。
 このように、正常画像の特徴量222に対してノイズを付加することにより、ノイズの分布に応じて、正常画像に対応する特徴量222を増加させることができる。したがって、機械学習における正常画像のバリエーションを有効に増加させることができる。その結果、後述するように検査対象の属性や撮影条件の違いによる正常画像のばらつきにも対応でき、画像復元のロバスト性が向上する。なお、ノイズ作成関数の具体例については後述する。
 学習部240は、訓練データを使用して、画像処理部220のニューラルネットワークを学習する。学習部240は、訓練データをエンコーダー221(エンコーダー部)に入力した場合に、デコーダー223(デコーダー部)による復元画像(復元データ)が正常画像(正常データ)となるようにエンコーダー221およびデコーダー223を学習する。
 より具体的には、学習部240は、復元画像、および正常画像から誤差関数を算出し、誤差関数が小さくなるように、誤差逆伝播法(バックプロパゲーション)により、ニューラルネットワークの重みパラメーター等を更新する。そして、各々の正常画像について、ニューラルネットワークの各パラメーターの更新が行われることにより、学習が進められる。
 本実施形態では、ノイズ付加部230のノイズ作成関数により、任意の分布に従うノイズを特徴量に付加し、学習部240は、上述した特許文献1のように特徴量の分布を学習するのではなく、特徴量のみを学習するように構成されている。したがって、ノイズ作成関数は、誤差逆伝搬に関与しない。
 (学習方法)
 図4は、図1に示す学習装置の学習方法の処理手順を例示するフローチャートである。図4のフローチャートに示す処理は、CPU111が学習プログラムを実行することにより実現される。図5は、部品の製造および検査工程を例示する模式図である。
 まず、訓練データを取得する(ステップS101)。画像取得部210は、例えば、学習装置100の外部の記憶装置から、正常画像からなる訓練データを取得する。
 次に、訓練データの特徴量を抽出する(ステップS102)。エンコーダー221は、画像取得部210によって取得された訓練データの特徴量を抽出する。
 次に、特徴量にノイズを付加する(ステップS103)。ノイズ付加部230は、エンコーダー221によって抽出された、正常画像の特徴量に、ノイズ作成関数によって生成されたノイズを付加する。ノイズは、例えば、所定の確率分布を有しており、ノイズが付加されることにより、正常画像の特徴量は確率分布に応じて広がる。これにより、正常画像のバリエーションを増加させることができる。
 例えば、図5に示すように、ある部品の製造および検査工程が、工程1、工程2、および外観検査工程を含む場合について説明する。例えば、工程1は、金属材料をドリル等の加工器具や、フライス等の加工機械を用いて加工する工程である。工程1については、Aさん、およびBさんが、切削作業を日替わり(勤務シフト)で行うことになっている。また、工程2は、工程1において加工された加工済みの部材を、砥石等の研磨工具を用いて研磨する工程である。工程2については、作業者は、特定の一人の作業者(例えば、Cさん)であるが、2種類の研磨工具を使用する可能性がある。
 工程1においては、作業者がAさんか、あるいはBさんかによって切削の仕上がりに微妙な違いが生じ、外観が異なる可能性があるが、いずれも良品(正常画像)が得られるものとする。また、工程2においては、使用される研磨工具がCか、あるいはDかによって、研磨の仕上がりに微妙な違いが生じ、外観が異なる可能性があるが、いずれも良品(正常画像)が得られるものとする。このように、外観検査前の各工程の実施条件の違いが外乱となって正常画像のバリエーションが生じる。この例の場合、正常画像は、2×2=4パターンのバリエーションがあり、バリエーションの分布は、勤務シフトの状況や、研磨工具の使用頻度に応じて二項分布に従うと考えられる。
 図6は、図5に示す製造および検査工程について、ノイズ作成関数のコードの一例を示すリストである。リストの1~2行目において、各々random関数により発生させた0~1の範囲の乱数が、「作業者がAさんである確率」の分布範囲を超え、かつ「研磨工具がCである確率」の分布範囲を超えている場合、特徴量(feature)の現在の値にノイズP(noise_p)を加算する(リストの3行目)。一方、リストの4~5行目において、「研磨工具がDである確率」を満たす場合、特徴量の現在の値にノイズQ(noise_q)を加算する。このように、正常画像のバリエーションが二項分布に従う場合であっても、ノイズ作成関数により二項分布に従うノイズを付加することにより、画像の復元精度が低下することを防止できる。
 一方、正常画像のバリエーションが正規分布や他の確率分布に従う場合は、ノイズ作成関数により正規分布や他の確率分布に従うノイズを付加する。これにより、画像の復元精度が低下することを防止できる。また、例えば、部品の製造ラインの環境に変更が生じた場合、現場の責任者の判断により、付加するノイズを適宜変更することもできる。
 次に、特徴量から訓練データを復元する(ステップS104)。デコーダー223は、ノイズ付加部230によってノイズが付加された特徴量から訓練データを復元する。
 次に、エンコーダー221およびデコーダー223のパラメーターを更新する(ステップS105)。学習部240は、デコーダー223による復元画像が正常画像となるように、エンコーダー221およびデコーダー223のパラメーターを更新することにより、エンコーダー221およびデコーダー223を学習する。
 このように、図4に示すフローチャートの処理では、画像取得部210は、検査対象の正常画像からなる訓練データを取得し、エンコーダー221は訓練データの特徴量を抽出する。ノイズ付加部230は、エンコーダー221によって抽出された、正常画像の特徴量に任意のノイズを付加し、デコーダー223は、ノイズが付加された特徴量から訓練データを復元する。学習部240は、訓練データと復元データとに基づいて、エンコーダー221およびデコーダー223のパラメーターを更新する。
 (ノイズ作成関数の他の例)
 以上では、部品の外観を撮影した正常画像の特徴量に対してノイズを付加することにより、バリエーションを増加させる場合を例示して説明したが、部品の正常画像に限らず、例えば、人体に関する正常画像の特徴量に対してノイズを付加してバリエーションを増加させることもできる。人体に関する正常画像は、人体の全てまたは一部の正常画像でありうる。
 図7は、人体の検査工程を例示する模式図である。通常、人体の撮影には種々の外乱が伴う。例えば、患者を撮影対象とする撮影において、外乱1、および外乱2が生じる場合を想定する。外乱1は、例えば、男女、年齢等の撮影対象者の属性に起因する。すなわち、撮影対象者が男性か、あるいは女性かによって、人体に関する正常画像は異なりうる。また、撮影対象者の年齢によっても正常画像は異なりうる。
 また、外乱2は、撮影担当者、撮影装置メーカー等の撮影条件に起因する。すなわち、撮影担当者(Dさん、Fさん)によって撮影方法や撮影技術に差があるため、正常画像に対して、許容される範囲内のばらつきが生じうる。また、撮影装置のメーカー(G社、H社)によって装置構成が異なるため、正常画像に対して、許容される範囲内のばらつきが生じうる。
 このように、外観検査前に生じる外乱により正常画像のばらつき(すなわち、バリエーション)が生じる。例えば、外乱1として撮影対象者の属性のうち男女のみが変化し、外乱2として撮影条件のうち撮影担当者のみが変化する場合、正常画像は、2×2=4パターンのバリエーションが生じる。また、バリエーションの分布は、男女の割合や、撮影担当者の担当状況に応じて二項分布に従うと考えられる。
 図8は、図7に示す検査工程について、ノイズ作成関数のコードの一例を示すリストである。リストの1~2行目において、各々random関数により発生させた0~1の範囲の乱数が、「対象者が男性である確率」の分布範囲を超え、かつ「撮影装置メーカーがG社である確率」の分布範囲を超えている場合、特徴量(feature)の現在の値にノイズR(noise_r)を加算する(リストの3行目)。一方、リストの4~5行目において、「撮影装置メーカーがH社である確率」を満たす場合、特徴量の現在の値にノイズS(noise_s)を加算する。
 このように、本実施形態の学習装置100によれば、エンコーダー221によって正常画像から抽出された特徴量に任意のノイズを付加することにより、正常画像のバリエーションを増加させる。したがって、正常画像のバリエーションが正規分布以外の分布に基づく場合であっても、正常画像の復元精度が低下することを防止できる。
 (異常検出装置)
 本実施形態に係る異常検出装置のハードウェア構成は、図1に示す学習装置100のハードウェア構成(例えば、パーソナルコンピューター、サーバー等のコンピューター)と同じでありうる。説明の重複を避けるため、異常検出装置のハードウェア構成については、詳細な説明を省略する。
 図9は、異常検出装置の制御部300の主要な機能を例示する機能ブロック図である。制御部300は、画像取得部310、画像処理部320、スコア算出部330、および異常判定部340を有する。
 画像取得部310は、入力画像を取得する。入力画像は、検査対象である正常/異常が未知の画像であり、異常を含む検査対象の画像(以下、「異常画像」という)、または正常画像でありうる。画像取得部310は、取得した入力画像を画像処理部320に送信する。
 画像処理部320は、例えば、エンコーダー・デコーダー構造を有する生成モデルとして機能するニューラルネットワークを有する。本実施形態のニューラルネットワークは、エンコーダー321、およびデコーダー323を有し、図1、図2に示す学習装置100により、訓練データを用いて予め学習されている。ニューラルネットワークは、特徴抽出により入力画像が有する本質的な要素のみを抜き出し、抽出された特徴量を用いて復元することにより、入力画像における不要な要素が除外された復元画像を生成して出力する。すなわち、ニューラルネットワークは、異常画像を訓練データとして用いずに学習するため、正常画像に対して、対応する特徴量が生成可能なように構成されており、異常画像に対しては、対応する特徴量を生成できず、再現性を有しない。
 図9に示す例では、入力画像は、検査対象としての部品M1の画像を含んでいる。部品M1には、製造工程の途中で異常(傷S1,S2)が発生している場合を想定している。なお、T1は、正常な部品M1が元々備えるテクスチャーである。復元画像は、入力画像の部品M1の画像から本質的な要素のみが残され、不要な要素が除去された画像となっている。テクスチャーT1は、部品M1が元々備えているものなので復元される一方で、傷S1,S2は、異常であるので復元されていない。
 より具体的には、エンコーダー321は、入力画像から特徴量を抽出する。すなわち、エンコーダー321は、入力画像を圧縮し、入力画像が元々有している特徴量の次元よりも低い次元の特徴量322を生成する。デコーダー323は、特徴量322に基づいて入力画像を復元する。エンコーダー321は、デコーダー323が入力画像の本質を再現できる程度に入力画像の特徴を圧縮することが好ましい。すなわち、特徴量322は、入力画像の本質を再現できる必要最小限の次元であることが好ましい。また、入力画像が有する特徴が多過ぎたり、入力画像の特徴の圧縮が不十分であったりした場合、入力画像を復元する際に、検査対象の異常が入力画像に含まれている場合に、この異常についても再現される可能性がある。一方で、入力画像が有する特徴が少な過ぎたり、入力画像の特徴が過度に圧縮されたりした場合、入力画像を復元する際に、正常な入力画像の再現度が低下する可能性があり、復元画像の画素レベルが検出可能なレベルに達しない場合がありうる。
 スコア算出部330は、エンコーダー321に入力される入力画像(検査対象のデータ)と、デコーダー323によって復元された入力画像の復元画像(復元データ)とに基づいて、入力画像の異常スコアを算出する。より具体的には、スコア算出部330は、入力画像と、復元画像との差分を異常スコアとして算出する。
 異常判定部340は、スコア算出部330によって算出された異常スコアに基づいて、検査対象の異常を判定する。異常判定部340は、例えば、異常スコアと所定の閾値とを比較し、比較結果に基づいて、検査対象の異常を判定する。
 (異常検出方法)
 図10は、異常検出装置の異常検出方法の処理手順を例示するフローチャートである。同図に示すフローチャートの処理は、CPU111が異常検出プログラムを実行することにより実現される。
 まず、入力画像を取得する(ステップS201)。画像取得部310は、例えば、異常検出装置の外部の撮像装置が撮影した、検査対象が写っている画像を入力画像として取得する。入力画像は、検査対象の異常画像、または正常画像でありうる。
 次に、入力画像の特徴量を抽出する(ステップS202)。エンコーダー321は、入力画像の特徴量を抽出する。エンコーダー321は、学習装置100により、訓練データを用いて予め学習されている。
 次に、入力画像を復元する(ステップS203)。デコーダー323は、エンコーダー321によって抽出された特徴量から入力画像を復元する。デコーダー323は、学習装置100により、訓練データを用いて予め学習されている。
 次に、検査対象のデータの異常スコアを算出する(ステップS204)。スコア算出部330は、入力画像と、デコーダー323によって復元された、入力画像の復元画像との差分を異常スコアとして算出する。
 次に、検査対象の異常を判定する(ステップS205)。異常判定部340は、スコア算出部330によって算出された異常スコアに基づいて、検査対象の異常を判定する。より具体的には、異常判定部340は、異常スコアが所定の閾値よりも高い場合、検査対象が異常であると判定し、閾値よりも低い場合、検査対象が正常であると判定する。異常判定部340は、例えば、入力画像についての異常スコアマップの最大値が所定の閾値よりも高い場合、検査対象が異常であると判定し、閾値よりも低い場合、検査対象が正常であると判定する。異常スコアマップは、入力画像の各画素に対応する異常スコアをマップ化したものである。あるいは、異常スコアマップの平均値が所定の閾値よりも高い場合、検査対象が異常であると判定し、閾値よりも低い場合、検査対象が正常であると判定するように構成してもよい。判定結果は、検査対象の検査結果として操作表示部130に送信され、ディスプレイに検査結果が表示される。
 (変形例)
 以上では、パーソナルコンピューター、サーバー上で学習、および推論(異常検出)の処理を行う場合について例示したが、クラウド上やエッジで学習、および推論の処理を行うように構成することもできる。
 (a)クラウド上において学習、および推論の処理を行う場合
 クラウド上においてニューラルネットワーク(生成モデル)を学習できるように、学習に関するアルゴリズム(学習プログラム)を保存し、実行する。ユーザーは、製造現場(製造ラインや工場)から離れた場所(例えば、本社)から、学習に関する設定・変更(例えば、ノイズ設定)や、各種アルゴリズムに関する設定・変更、学習の指示等を行うことができる。
 また、複数の現場(例えば、製造ラインA~C)における検査対象の異常検出を行う場合、クラウドにより、学習済み生成モデルを共有できる。また、クラウド上において、現場(例えば、製造ライン、工場、病院等)の検査対象(例えば、部品、人体等)に応じて、適した学習済み生成モデルを選択できる。
 また、推論に関するアルゴリズム(異常検出プログラム等)をクラウドに実装し、現場から第5世代移動通信システム(以下、「5G」という)を使用して、入力画像が取得される度にクラウドに送信する。これにより、クラウドにおいて学習および推論の処理を一元的に管理しつつ、リアルタイムで推論を進めることができる。
 さらに、学習、および推論の処理を高度化、高精度化できる。例えば、複数のデバイス(撮像装置)により検査対象を撮像し、画像群をクラウドに送信し、画像の組み合わせによって、アルゴリズムの組み合わせを変更する等、クラウドで統合処理し、推論した結果を現場にフィードバックできる。
 (b)エッジ(現場におけるネットワーク端末)において学習、および推論の処理を行う場合
 エッジから、5Gを使用して、検査対象の画像をクラウドに送信する。クラウドは、検査対象の画像に応じて、生成モデルを選択し、選択した生成モデルをエッジに送信する。エッジにおいて、生成モデルの学習を行い、学習済み生成モデルを使用して推論の処理を行う。これにより、生成モデルの中央管理、都度切り替え、エッジ処理によるクラウドの処理負荷の低減、リアルタイム推論を同時に達成できる。
 また、エッジ側で特徴量抽出まで行い、特徴量を5Gでクラウドに送信し、クラウドにおいて推論を行う等、役割分担することもできる。これにより、処理負荷が分散され、全体としてのスループットが向上する。
 さらに、エッジにおいて、学習、および推論の処理を行った結果をクラウドに送信し、クラウド上において後処理(例えば、テンプレートマッチング、後工程選定)を行い、最終判定結果を算出し、算出結果をエッジに送信することもできる。これにより、クラウド上における後処理の設定変更等を一元的に管理できる。
 上述した学習装置、学習プログラム、異常検出装置、および異常検出プログラムは、上述の実施形態の特徴を説明するにあたって主要構成を説明したのであって、上述の構成に限られず、特許請求の範囲内において、種々改変することができる。また、一般的な異常検出装置等が備える構成を排除するものではない。
 例えば、上述したフローチャートは、一部のステップを省略してもよく、他のステップが追加されてもよい。また各ステップの一部は同時に実行されてもよく、一つのステップが複数のステップに分割されて実行されてもよい。
 また、上述の例では、検査対象として部品、および人体の正常画像を用いて生成モデルを学習する場合について例示したが、本発明はこのような場合に限定されず、図版、図形、色彩等を検査対象とすることもできる。また、訓練データとして画像データを用いる場合について例示したが、本発明はこのような場合に限定されず、テキストデータ、音声データ等を用いることもできる。
 また、上述した学習装置および異常検出装置における各種処理を行う手段および方法は、専用のハードウェア回路、またはプログラムされたコンピューターのいずれによっても実現することが可能である。上記プログラムは、例えば、USBメモリやDVD(Digital Versatile Disc)-ROM等のコンピューター読み取り可能な記録媒体によって提供されてもよいし、インターネット等のネットワークを介してオンラインで提供されてもよい。この場合、コンピューター読み取り可能な記録媒体に記録されたプログラムは、通常、ハードディスク等の記憶部に転送され記憶される。また、上記プログラムは、単独のアプリケーションソフトとして提供されてもよいし、一機能としてその学習装置および異常検出装置のソフトウエアに組み込まれてもよい。
 本出願は、2021年6月9日に出願された日本国特許出願番号2021-096337号に基づいており、その開示内容は、参照により全体として組み入れられている。
100 学習装置、
110 制御部、
111 CPU、
112 RAM、
113 ROM、
114 補助記憶部、
120 通信部、
130 操作表示部、
210 画像取得部、
220 画像処理部、
221 エンコーダー、
222 特徴量、
223 デコーダー、
230 ノイズ付加部、
240 学習部、
300 制御部、
310 画像取得部、
320 画像処理部、
321 エンコーダー、
322 特徴量、
323 デコーダー、
330 スコア算出部、
340 異常判定部。

Claims (9)

  1.  検査対象の正常データからなる訓練データを取得するデータ取得部と、
     前記データ取得部によって取得された訓練データの特徴量を抽出するエンコーダー部と、
     前記エンコーダー部によって抽出された特徴量にノイズを付加するノイズ付加部と、
     前記ノイズ付加部によってノイズが付加された前記特徴量から前記訓練データを復元するデコーダー部と、
     前記訓練データと、前記デコーダー部によって復元された復元データとに基づいて、前記エンコーダー部および前記デコーダー部のパラメーターを更新する学習部と、を有する、学習装置。
  2.  前記学習部は、前記訓練データを前記エンコーダー部に入力した場合に、前記デコーダー部による復元データが正常データとなるように、前記エンコーダー部および前記デコーダー部のパラメーターを更新することにより、前記エンコーダー部および前記デコーダー部を学習する、請求項1に記載の学習装置。
  3.  前記ノイズ付加部は、所定の確率分布に従うノイズを付加する、請求項1または2に記載の学習装置。
  4.  前記確率分布は、二項分布である、請求項3に記載の学習装置。
  5.  前記正常データは、正常画像である、請求項1~4のいずれか1項に記載の学習装置。
  6.  検査対象の正常データからなる訓練データを取得する取得ステップと、
     エンコーダー部によって前記訓練データの特徴量を抽出する抽出ステップと、
     前記抽出ステップにおいて抽出された特徴量にノイズを付加する付加ステップと、
     前記付加ステップにおいてノイズが付加された前記特徴量から、デコーダー部によって前記訓練データを復元する復元ステップと、
     前記訓練データと、前記復元ステップにおいて復元された復元データとに基づいて、前記エンコーダー部および前記デコーダー部のパラメーターを更新する更新ステップと、
     を含む処理をコンピューターに実行させるための学習プログラム。
  7.  検査対象のデータを取得するデータ取得部と、
     請求項1~5のいずれか1項に記載の学習装置においてパラメーターが更新されたエンコーダー部およびデコーダー部と、
     前記エンコーダー部に入力される前記検査対象のデータと、前記デコーダー部によって復元される復元データとに基づいて、前記検査対象のデータの異常スコアを算出するスコア算出部と、
     前記スコア算出部によって算出された異常スコアに基づいて、前記検査対象の異常を判定する異常判定部と、を有する、異常検出装置。
  8.  前記スコア算出部は、前記検査対象のデータと、前記復元データとの差分を異常スコアとして算出する、請求項7に記載の異常検出装置。
  9.  検査対象のデータを取得する取得ステップと、
     請求項1~5のいずれか1項に記載の学習装置においてパラメーターが更新されたエンコーダー部により、前記検査対象のデータの特徴量を抽出する抽出ステップと、
     前記学習装置においてパラメーターが更新されたデコーダー部により、前記特徴量から前記検査対象のデータの復元する復元ステップと、
     前記検査対象のデータと、前記デコーダー部によって復元された復元データとに基づいて、前記検査対象のデータの異常スコアを算出する算出ステップと、
     前記算出ステップにおいて算出された異常スコアに基づいて、前記検査対象の異常を判定する判定ステップと、を含む処理をコンピューターに実行させるための異常検出プログラム。
PCT/JP2022/010216 2021-06-09 2022-03-09 学習装置、学習プログラム、異常検出装置、および異常検出プログラム WO2022259661A1 (ja)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2023527512A JPWO2022259661A1 (ja) 2021-06-09 2022-03-09

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
JP2021096337 2021-06-09
JP2021-096337 2021-06-09

Publications (1)

Publication Number Publication Date
WO2022259661A1 true WO2022259661A1 (ja) 2022-12-15

Family

ID=84426042

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/JP2022/010216 WO2022259661A1 (ja) 2021-06-09 2022-03-09 学習装置、学習プログラム、異常検出装置、および異常検出プログラム

Country Status (2)

Country Link
JP (1) JPWO2022259661A1 (ja)
WO (1) WO2022259661A1 (ja)

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2017094267A1 (ja) * 2015-12-01 2017-06-08 株式会社Preferred Networks 異常検出システム、異常検出方法、異常検出プログラム及び学習済モデル生成方法
JP2021157451A (ja) * 2020-03-26 2021-10-07 富士通株式会社 画像処理装置、画像認識システム及び画像処理プログラム

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2017094267A1 (ja) * 2015-12-01 2017-06-08 株式会社Preferred Networks 異常検出システム、異常検出方法、異常検出プログラム及び学習済モデル生成方法
JP2021157451A (ja) * 2020-03-26 2021-10-07 富士通株式会社 画像処理装置、画像認識システム及び画像処理プログラム

Non-Patent Citations (2)

* Cited by examiner, † Cited by third party
Title
DEJA KAMIL; DUBINSKI JAN; NOWAK PIOTR; WENZEL SANDRO; SPUREK PRZEMSYSAW; TRZCINSKI TOMASZ: "End-to-End Sinkhorn Autoencoder With Noise Generator", IEEE ACCESS, IEEE, USA, vol. 9, 31 December 2020 (2020-12-31), USA , pages 7211 - 7219, XP011831269, DOI: 10.1109/ACCESS.2020.3048622 *
KEIZO KATO; JING ZHOU; TOMOTAKE SASAKI; AKIRA NAKAGAWA: "Rate-Distortion Optimization Guided Autoencoder for Isometric Embedding in Euclidean Latent Space", ARXIV.ORG, CORNELL UNIVERSITY LIBRARY, 201 OLIN LIBRARY CORNELL UNIVERSITY ITHACA, NY 14853, 14 July 2020 (2020-07-14), 201 Olin Library Cornell University Ithaca, NY 14853 , XP081704007 *

Also Published As

Publication number Publication date
JPWO2022259661A1 (ja) 2022-12-15

Similar Documents

Publication Publication Date Title
US10997711B2 (en) Appearance inspection device
JP2019087181A (ja) 画像検査装置および方法
JP2016085704A (ja) 情報処理システム、情報処理装置、情報処理方法、及びプログラム
KR101992970B1 (ko) 딥러닝과 노이즈 제거 기술을 이용한 표면 결함 검출 장치 및 방법
US10282614B2 (en) Real-time detection of object scanability
WO2019176990A1 (ja) 検査装置、画像識別装置、識別装置、検査方法、及び検査プログラム
JP2017167624A (ja) 画像処理装置、画像処理方法、およびプログラム
KR20210141060A (ko) 머신러닝 기반의 이미지 이상 탐지 시스템
JP2021174456A (ja) 異常判定方法及び異常判定装置
WO2019176988A1 (ja) 検査システム、識別システム、及び識別器評価装置
JP7459697B2 (ja) 異常検知システム、学習装置、異常検知プログラム、学習プログラム、異常検知方法、および学習方法
CN112233161B (zh) 手部图像深度确定方法、装置、电子设备及存储介质
WO2022259661A1 (ja) 学習装置、学習プログラム、異常検出装置、および異常検出プログラム
KR20210018114A (ko) 교차 도메인 메트릭 학습 시스템 및 방법
JP2020064364A (ja) 学習装置、画像生成装置、学習方法、及び学習プログラム
JP2022029262A (ja) 画像処理装置、画像処理方法、画像処理プログラム、および学習装置
JP2018116672A (ja) 情報処理装置、情報処理方法およびプログラム
CN113167568B (zh) 坐标计算装置、坐标计算方法和计算机可读记录介质
JP7070308B2 (ja) 推定器生成装置、検査装置、推定器生成方法、及び推定器生成プログラム
JP7459696B2 (ja) 異常検知システム、学習装置、異常検知プログラム、学習プログラム、異常検知方法、および学習方法演算装置の学習方法
JP2021002270A (ja) 画像認識学習装置、画像認識学習方法、画像認識学習プログラム及び端末装置
WO2024024263A1 (ja) 検査装置及び方法
WO2022130814A1 (ja) 指標選択装置、情報処理装置、情報処理システム、検査装置、検査システム、指標選択方法、および指標選択プログラム
WO2021229901A1 (ja) 画像検査装置、画像検査方法及び学習済みモデル生成装置
WO2021229905A1 (ja) 画像検査装置、画像検査方法及び学習済みモデル生成装置

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 22819851

Country of ref document: EP

Kind code of ref document: A1

WWE Wipo information: entry into national phase

Ref document number: 2023527512

Country of ref document: JP

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 22819851

Country of ref document: EP

Kind code of ref document: A1