Anomaly detection is a problem addressed to many fields. In general, given a reference set, the observations far from the majority ones are called anomalies. In recent years, the anomaly detection and its localization represent an interesting goal. Some areas, like industry, finance or medical field, use models that provide solutions to solve this problem: in the industrial sector these techniques help in quality product monitoring and mainteinance, about finance it permits to detect fraud cases, while in the medical sector they recognize cancer on mammogram images. Taking into considerations images, the anomaly detection takes part of the Computer Vision problems. Reconstruction methods leads to recognize anomalies, such as Autoencoders and generative models as GAN. Ganomaly is a GAN-based model, trained on normal images, which performs the anomaly detection task; in the test phase, the learned normality knowledge permits to identify whether an image is normal or anomalous. This thesis provides an’extension of the Ganomaly model, called Patch-Ganomaly. Given an image, it generates a 2D representation of anomaly scores (anomaly score map): it associates an anomaly score to each pixel of the image. This map permits both to recognize an anomalous image and to localize the pixels of the anomalous region. Moreover, we create a more precise model through the transfer learning technique, based on the VGG16 network: TL-Ganomaly. It is a model that localizes the anomalous region in a more precise way than Patch-Ganomaly. The post-processing phase is relevant for improving the segmentation of normal and anomalous regions. For this reason, we provide the Conv-Processing model, which learns the convolutional kernel used to filter the anomaly score map generated by the provided models. In this way, the segmentation produced by the models improves in terms of effectiveness. The proposed approach provides models for detecting anomalies on steel images. The dataset is composed by 256 1600 images and it is given by Kaggle platform. This platform created a competition based on the steel defect detection. The proposed models detect anomalies better than the reference models (CNN and convolutional autoencoder). Patch-Ganomaly model produces solutions better in terms of AUC, instead, TL-Ganomaly ensures a better precision. Basing on the prefixed target, it is possible to use one of the two models: if the target is having a good accuracy, then Patch-Ganomaly is the best one to use, otherwise, if the target consists on precision about detection, then TL-Ganomaly performs surely better.
Il riconoscimento di anomalie è un tematica sempre più popolare che viene affrontata su più fronti. In generale, fornito un insieme di riferimento, le osservazioni che differiscono dalla maggior parte dei campioni dell’insieme, sono considerate anomale. Il riconoscimento e la corretta localizzazione delle anomalie rappresentano uno degli obiettivi di particolare interesse negli ultimi anni. In contesti come per esempio nel settore industriale, finanziario o in ambito medico si cerca sempre più di sfruttare soluzioni adattabili per l’identificazione di anomalie. In ambito industriale queste tecniche permettono di monitorare e mantenere la qualità dei prodotti, nel settore finanziario riescono a identificare i casi di frode, mentre in ambito medico sono in grado rilevare la presenza di tumori su mammografie. In un contesto di immagini, il riconoscimento di anomalie rientra tra i problemi di Computer Vision. Esistono metodi di ricostruzione come gli Autoencoder o metodi generativi come le GAN che si occupano di risolvere tale problema. Tra i modelli che si basano sulle GAN, chiamati GAN-based, si distingue il modello Ganomaly: si tratta di un modello addestrato su un training set di immagini normali; sulla base della conoscenza di normalità appresa, in fase di test, riconosce se un’immagine siaz normale o anomala. Questa tesi propone un’estensione del modello Ganomaly, chiamata Patch-Ganomaly, la quale, a partire da un’immagine, genera una rappresentazione 2D di anomaly score (anomaly score map): essa associa ad ogni pixel dell’immagine un anomaly score. Attraverso questa mappa è possibile non solo riconoscere un’immagine anomala, ma anche localizzare i pixel che compongono la regione anomala al suo interno. Inoltre, mediante l’utilizzo di transfer learning basato sulla rete VGG16, abbiamo creato un modello più preciso: TLGanomaly. Esso localizza la regione anomala con maggior precisione rispetto a Patch-Ganomaly. La fase di post-processing è rilevante per il miglioramento della segmentazione in regione normale e anomala. Per questo motivo, abbiamo ideato il modello Conv-Processing, il quale apprende il kernel convoluzionale con cui filtrare l’anomaly score map generata dai modelli. In questo modo, il risultato ottenuto dai modelli proposti viene migliorato in termini di efficacia. L’approccio proposto fornisce modelli per identificare le anomalie presenti su immagini raffiguranti lamiere di acciaio. Il dataset è composto da immagini aventi dimensione 256 1600 e viene fornito dalla piattaforma Kaggle, la quale ha proposto una competizione con lo scopo di rilevarne i difetti. I modelli proposti hanno prodotto risultati migliori rispetto ai modelli di riferimento considerati (convolutional autoencoder e CNN). In particolare il modello Patch-Ganomaly genera soluzioni con AUC più elevate, mentre TL-Ganomaly garantisce una maggiore precisione. In relazione all’obiettivo prefissato, è possibile utilizzare uno dei due modelli: nel caso in cui si voglia assicurare una buona accuratezza allora si suggerisce Patch-Ganomaly, altrimenti, se l’obiettivo consiste nel garantire una maggior precisione, si consiglia l’utilizzo del modello TL-Ganomaly.
Riconoscimento di anomalie con Ganomaly : patch-wise analysis e transfer learning
MOLTISANTI, DANIELE
2018/2019
Abstract
Anomaly detection is a problem addressed to many fields. In general, given a reference set, the observations far from the majority ones are called anomalies. In recent years, the anomaly detection and its localization represent an interesting goal. Some areas, like industry, finance or medical field, use models that provide solutions to solve this problem: in the industrial sector these techniques help in quality product monitoring and mainteinance, about finance it permits to detect fraud cases, while in the medical sector they recognize cancer on mammogram images. Taking into considerations images, the anomaly detection takes part of the Computer Vision problems. Reconstruction methods leads to recognize anomalies, such as Autoencoders and generative models as GAN. Ganomaly is a GAN-based model, trained on normal images, which performs the anomaly detection task; in the test phase, the learned normality knowledge permits to identify whether an image is normal or anomalous. This thesis provides an’extension of the Ganomaly model, called Patch-Ganomaly. Given an image, it generates a 2D representation of anomaly scores (anomaly score map): it associates an anomaly score to each pixel of the image. This map permits both to recognize an anomalous image and to localize the pixels of the anomalous region. Moreover, we create a more precise model through the transfer learning technique, based on the VGG16 network: TL-Ganomaly. It is a model that localizes the anomalous region in a more precise way than Patch-Ganomaly. The post-processing phase is relevant for improving the segmentation of normal and anomalous regions. For this reason, we provide the Conv-Processing model, which learns the convolutional kernel used to filter the anomaly score map generated by the provided models. In this way, the segmentation produced by the models improves in terms of effectiveness. The proposed approach provides models for detecting anomalies on steel images. The dataset is composed by 256 1600 images and it is given by Kaggle platform. This platform created a competition based on the steel defect detection. The proposed models detect anomalies better than the reference models (CNN and convolutional autoencoder). Patch-Ganomaly model produces solutions better in terms of AUC, instead, TL-Ganomaly ensures a better precision. Basing on the prefixed target, it is possible to use one of the two models: if the target is having a good accuracy, then Patch-Ganomaly is the best one to use, otherwise, if the target consists on precision about detection, then TL-Ganomaly performs surely better.File | Dimensione | Formato | |
---|---|---|---|
Tesi_Daniele_Moltisanti.pdf
accessibile in internet solo dagli utenti autorizzati
Descrizione: Thesis text
Dimensione
34.13 MB
Formato
Adobe PDF
|
34.13 MB | Adobe PDF | Visualizza/Apri |
I documenti in POLITesi sono protetti da copyright e tutti i diritti sono riservati, salvo diversa indicazione.
https://hdl.handle.net/10589/153182