Publications-Theses

Article View/Open

Publication Export

Google ScholarTM

NCCU Library

Citation Infomation

Related Publications in TAIR

題名 基於生成對抗網路之時間序列異常偵測
Time Series Anomaly Detection based on Generative Adversarial Network
作者 林柏辰
Lin, Po-Chen
貢獻者 周珮婷<br>張志浩
林柏辰
Lin, Po-Chen
關鍵詞 生成對抗網路
時間序列
異常偵測
深度學習
Generative Adversarial Network
Time Series
Anomaly Detection
Deep Learning
日期 2024
上傳時間 1-Sep-2025 14:48:27 (UTC+8)
摘要 隨著物聯網系統的快速發展,人們愈來愈依賴使用傳感器獲取各種時間序列資料以執行自動化任務,因此辨識其中的異常狀況成為一個重要議題。然而由於時間序列特有的時間依賴性,異常偵測是項充滿挑戰且複雜的任務。本研究以深度學習方式,提出一種基於生成對抗網路之單變量時間序列異常偵測模型架構 CLAWGANdiv。透過訓練完成之生成網路重構出正常子序列,並計算出測試集中滑動窗口子序列之異常分數,藉此判定其是否異常。此外,為了能有效地捕捉資料中的時間依賴性,模型採用雙向長短期記憶網路做為主要架構,並結合注意力機制與卷積層以捕捉資料特徵。為驗證所提出模型之有效性,本研究使用 Numenta Anomaly Benchmark 資料集與 Yahoo Webscope 資料集中的部分資料,進行後續參數調整與其他模型之比較,從中取得優異的結果並針對實驗結果進行討論。
With the development of Internet of Things (IoT) systems, humankind has become increasingly dependent on sensor devices to acquire various time series data for task automation, making anomaly detection an extremely important issue. However, due to the highly complex temporal correlations of time series data, detecting anomalies might be particularly challenging. This research proposes CLAWGANdiv, a univariate time series anomaly detection approach based on Generative Adversarial Networks (GANs). The model reconstructs normal time series through a trained Generator and calculates anomaly scores for subsequences extracted with a sliding window in the test set to determine whether they are anomalous or not. To capture the temporal correlations of time series, we use Bidirectional Long Short-Term Memory network (BiLSTM) as the main architecture, complemented by an attention mechanism and convolutional layers to capture data features. To validate the effectiveness of the proposed method, we adjusted parameters and compared results with other models using a partial Yahoo Webscope dataset and Numenta Anomaly Benchmark (NAB) dataset. The results show that our approach can effectively detect anomalies, and further discussion will be based on these experimental results.
參考文獻 Arjovsky, M., Chintala, S., and Bottou, L. (2017). Wasserstein gan. Bashar, M. A. and Nayak, R. (2020). Tanogan: Time series anomaly detection with generative adversarial networks. CoRR, abs/2008.09567. Cuturi, M. and Blondel, M. (2018). Soft-dtw: a differentiable loss function for time-series. Elman, J. L. (1990). Finding structure in time. Cognitive science, 14(2):179–211. Endres, D. and Schindelin, J. (2003). A new metric for probability distributions. IEEE Transactions on Information Theory, 49(7):1858–1860. Geiger, A., Liu, D., Alnegheimish, S., Cuesta-Infante, A., and Veeramachaneni, K. (2020). Tadgan: Time series anomaly detection using generative adversarial networks. Goodfellow, I., Pouget-Abadie, J., Mirza, M., Xu, B., Warde-Farley, D., Ozair, S., Courville, A., and Bengio, Y. (2014). Generative adversarial nets. Advances in neural information processing systems, 27. Gulrajani, I., Ahmed, F., Arjovsky, M., Dumoulin, V., and Courville, A. (2017). Improved training of wasserstein gans. Heusel, M., Ramsauer, H., Unterthiner, T., Nessler, B., and Hochreiter, S. (2017). Gans trained by a two time-scale update rule converge to a local nash equilibrium. Advances in neural information processing systems, 30. Hochreiter, S. and Schmidhuber, J. (1997). Long short-term memory. Neural computation, 9(8):1735–1780. Kullback, S. and Leibler, R. A. (1951). On information and sufficiency. The Annals of Mathematical Statistics, 22(1):79–86. Laptev, N. and Amizadeh, S. (2019). A labeled anomaly detection dataset s5 yahoo research, v1. https://webscope.sandbox.yahoo.com/catalog.php?datatype=s&did=70. Lavin, A. and Ahmad, S. (2017). The numenta anomaly benchmark (white paper). The Numenta Anomaly Benchmark [White paper]. LeCun, Y., Bottou, L., Bengio, Y., and Haffner, P. (1998). Gradient-based learning applied to document recognition. Proceedings of the IEEE, 86(11):2278–2324. Li, D., Chen, D., Shi, L., Jin, B., Goh, J., and Ng, S.-K. (2019). Mad-gan: Multivariate anomaly detection for time series data with generative adversarial networks. Mallasto, A., Montúfar, G., and Gerolin, A. (2019). How well do wgans estimate the Wasserstein metric? Mirza, M. and Osindero, S. (2014). Conditional generative adversarial nets. arXiv preprint arXiv:1411.1784. Miyato, T., Kataoka, T., Koyama, M., and Yoshida, Y. (2018). Spectral normalization for generative adversarial networks. Radford, A., Metz, L., and Chintala, S. (2015). Unsupervised representation learning with deep convolutional generative adversarial networks. arXiv preprint arXiv:1511.06434. Salimans, T., Goodfellow, I., Zaremba, W., Cheung, V., Radford, A., Chen, X., and Chen, X. (2016). Improved techniques for training gans. In Lee, D., Sugiyama, M., Luxburg, U., Guyon, I., and Garnett, R., editors, Advances in Neural Information Processing Systems, volume 29. Curran Associates, Inc. Schlegl, T., Seeböck, P., Waldstein, S. M., Schmidt-Erfurth, U., and Langs, G. (2017). Unsupervised anomaly detection with generative adversarial networks to guide marker discovery. CoRR, abs/1703.05921. Stanczuk, J., Etmann, C., Kreusser, L. M., and Schönlieb, C.-B. (2021). Wasserstein gans work because they fail (to approximate the wasserstein distance). Vaswani, A., Shazeer, N., Parmar, N., Uszkoreit, J., Jones, L., Gomez, A. N., Kaiser, L., and Polosukhin, I. (2023). Attention is all you need. Wu, J., Huang, Z., Thoma, J., Acharya, D., and Gool, L. V. (2018). Wasserstein divergence for gans. Zhu, J.-Y., Park, T., Isola, P., and Efros, A. A. (2017). Unpaired image-to-image translation using cycleconsistent adversarial networks. Proceedings of the IEEE international conference on computer vision.
描述 碩士
國立政治大學
統計學系
111354012
資料來源 http://thesis.lib.nccu.edu.tw/record/#G0111354012
資料類型 thesis
dc.contributor.advisor 周珮婷<br>張志浩zh_TW
dc.contributor.author (Authors) 林柏辰zh_TW
dc.contributor.author (Authors) Lin, Po-Chenen_US
dc.creator (作者) 林柏辰zh_TW
dc.creator (作者) Lin, Po-Chenen_US
dc.date (日期) 2024en_US
dc.date.accessioned 1-Sep-2025 14:48:27 (UTC+8)-
dc.date.available 1-Sep-2025 14:48:27 (UTC+8)-
dc.date.issued (上傳時間) 1-Sep-2025 14:48:27 (UTC+8)-
dc.identifier (Other Identifiers) G0111354012en_US
dc.identifier.uri (URI) https://nccur.lib.nccu.edu.tw/handle/140.119/159034-
dc.description (描述) 碩士zh_TW
dc.description (描述) 國立政治大學zh_TW
dc.description (描述) 統計學系zh_TW
dc.description (描述) 111354012zh_TW
dc.description.abstract (摘要) 隨著物聯網系統的快速發展,人們愈來愈依賴使用傳感器獲取各種時間序列資料以執行自動化任務,因此辨識其中的異常狀況成為一個重要議題。然而由於時間序列特有的時間依賴性,異常偵測是項充滿挑戰且複雜的任務。本研究以深度學習方式,提出一種基於生成對抗網路之單變量時間序列異常偵測模型架構 CLAWGANdiv。透過訓練完成之生成網路重構出正常子序列,並計算出測試集中滑動窗口子序列之異常分數,藉此判定其是否異常。此外,為了能有效地捕捉資料中的時間依賴性,模型採用雙向長短期記憶網路做為主要架構,並結合注意力機制與卷積層以捕捉資料特徵。為驗證所提出模型之有效性,本研究使用 Numenta Anomaly Benchmark 資料集與 Yahoo Webscope 資料集中的部分資料,進行後續參數調整與其他模型之比較,從中取得優異的結果並針對實驗結果進行討論。zh_TW
dc.description.abstract (摘要) With the development of Internet of Things (IoT) systems, humankind has become increasingly dependent on sensor devices to acquire various time series data for task automation, making anomaly detection an extremely important issue. However, due to the highly complex temporal correlations of time series data, detecting anomalies might be particularly challenging. This research proposes CLAWGANdiv, a univariate time series anomaly detection approach based on Generative Adversarial Networks (GANs). The model reconstructs normal time series through a trained Generator and calculates anomaly scores for subsequences extracted with a sliding window in the test set to determine whether they are anomalous or not. To capture the temporal correlations of time series, we use Bidirectional Long Short-Term Memory network (BiLSTM) as the main architecture, complemented by an attention mechanism and convolutional layers to capture data features. To validate the effectiveness of the proposed method, we adjusted parameters and compared results with other models using a partial Yahoo Webscope dataset and Numenta Anomaly Benchmark (NAB) dataset. The results show that our approach can effectively detect anomalies, and further discussion will be based on these experimental results.en_US
dc.description.tableofcontents 誌謝 i 摘要 ii Abstract iii 目錄 iv 表目錄 vi 圖目錄 vii 第一章 緒論 1 第二章 相關研究 3 2.1 KL散度與JS散度 3 2.1.1 KL散度 3 2.1.2 JS散度 3 2.2 GenerativeAdversarialNetworks 4 2.2.1 GAN模型之訓練面臨狀況 5 2.2.2 GAN模型訓練不穩定性之解決方法 5 2.3 WassersteinGAN 6 2.4 WGAN-div 8 2.5時間序列資料異常偵測 8 2.5.1 MAD-GAN 9 2.5.2 TAnoGAN 9 2.5.3 TadGAN 9 第三章 研究方法 10 3.1資料正規化 10 3.2時間序列滑動窗口 10 3.3深度學習模型 11 3.3.1損失函數 11 3.3.2超參數 11 3.3.3優化器 12 3.3.4激勵函數 13 3.4卷積神經網路 14 3.5長短期時間記憶模型 14 3.5.1 RNN 15 3.5.2 LSTM 15 3.5.3雙向LSTM 16 3.6注意力機制 17 3.6.1 Self-attention 17 3.6.2 MultiheadAttention 18 3.7 CLAWGANdiv 19 3.8動態時間規整 20 3.9模型評估指標 21 第四章 實驗過程 22 4.1資料集 22 4.2實驗環境與流程簡介 22 4.3資料預處理 24 4.4異常判定 25 4.5實驗過程與結果 26 4.5.1實驗過程簡介 26 4.5.2模型訓練過程 27 4.5.3模型比較 38 4.5.4實驗總結 39 第五章 結論 40 參考文獻42zh_TW
dc.format.extent 5252327 bytes-
dc.format.mimetype application/pdf-
dc.source.uri (資料來源) http://thesis.lib.nccu.edu.tw/record/#G0111354012en_US
dc.subject (關鍵詞) 生成對抗網路zh_TW
dc.subject (關鍵詞) 時間序列zh_TW
dc.subject (關鍵詞) 異常偵測zh_TW
dc.subject (關鍵詞) 深度學習zh_TW
dc.subject (關鍵詞) Generative Adversarial Networken_US
dc.subject (關鍵詞) Time Seriesen_US
dc.subject (關鍵詞) Anomaly Detectionen_US
dc.subject (關鍵詞) Deep Learningen_US
dc.title (題名) 基於生成對抗網路之時間序列異常偵測zh_TW
dc.title (題名) Time Series Anomaly Detection based on Generative Adversarial Networken_US
dc.type (資料類型) thesisen_US
dc.relation.reference (參考文獻) Arjovsky, M., Chintala, S., and Bottou, L. (2017). Wasserstein gan. Bashar, M. A. and Nayak, R. (2020). Tanogan: Time series anomaly detection with generative adversarial networks. CoRR, abs/2008.09567. Cuturi, M. and Blondel, M. (2018). Soft-dtw: a differentiable loss function for time-series. Elman, J. L. (1990). Finding structure in time. Cognitive science, 14(2):179–211. Endres, D. and Schindelin, J. (2003). A new metric for probability distributions. IEEE Transactions on Information Theory, 49(7):1858–1860. Geiger, A., Liu, D., Alnegheimish, S., Cuesta-Infante, A., and Veeramachaneni, K. (2020). Tadgan: Time series anomaly detection using generative adversarial networks. Goodfellow, I., Pouget-Abadie, J., Mirza, M., Xu, B., Warde-Farley, D., Ozair, S., Courville, A., and Bengio, Y. (2014). Generative adversarial nets. Advances in neural information processing systems, 27. Gulrajani, I., Ahmed, F., Arjovsky, M., Dumoulin, V., and Courville, A. (2017). Improved training of wasserstein gans. Heusel, M., Ramsauer, H., Unterthiner, T., Nessler, B., and Hochreiter, S. (2017). Gans trained by a two time-scale update rule converge to a local nash equilibrium. Advances in neural information processing systems, 30. Hochreiter, S. and Schmidhuber, J. (1997). Long short-term memory. Neural computation, 9(8):1735–1780. Kullback, S. and Leibler, R. A. (1951). On information and sufficiency. The Annals of Mathematical Statistics, 22(1):79–86. Laptev, N. and Amizadeh, S. (2019). A labeled anomaly detection dataset s5 yahoo research, v1. https://webscope.sandbox.yahoo.com/catalog.php?datatype=s&did=70. Lavin, A. and Ahmad, S. (2017). The numenta anomaly benchmark (white paper). The Numenta Anomaly Benchmark [White paper]. LeCun, Y., Bottou, L., Bengio, Y., and Haffner, P. (1998). Gradient-based learning applied to document recognition. Proceedings of the IEEE, 86(11):2278–2324. Li, D., Chen, D., Shi, L., Jin, B., Goh, J., and Ng, S.-K. (2019). Mad-gan: Multivariate anomaly detection for time series data with generative adversarial networks. Mallasto, A., Montúfar, G., and Gerolin, A. (2019). How well do wgans estimate the Wasserstein metric? Mirza, M. and Osindero, S. (2014). Conditional generative adversarial nets. arXiv preprint arXiv:1411.1784. Miyato, T., Kataoka, T., Koyama, M., and Yoshida, Y. (2018). Spectral normalization for generative adversarial networks. Radford, A., Metz, L., and Chintala, S. (2015). Unsupervised representation learning with deep convolutional generative adversarial networks. arXiv preprint arXiv:1511.06434. Salimans, T., Goodfellow, I., Zaremba, W., Cheung, V., Radford, A., Chen, X., and Chen, X. (2016). Improved techniques for training gans. In Lee, D., Sugiyama, M., Luxburg, U., Guyon, I., and Garnett, R., editors, Advances in Neural Information Processing Systems, volume 29. Curran Associates, Inc. Schlegl, T., Seeböck, P., Waldstein, S. M., Schmidt-Erfurth, U., and Langs, G. (2017). Unsupervised anomaly detection with generative adversarial networks to guide marker discovery. CoRR, abs/1703.05921. Stanczuk, J., Etmann, C., Kreusser, L. M., and Schönlieb, C.-B. (2021). Wasserstein gans work because they fail (to approximate the wasserstein distance). Vaswani, A., Shazeer, N., Parmar, N., Uszkoreit, J., Jones, L., Gomez, A. N., Kaiser, L., and Polosukhin, I. (2023). Attention is all you need. Wu, J., Huang, Z., Thoma, J., Acharya, D., and Gool, L. V. (2018). Wasserstein divergence for gans. Zhu, J.-Y., Park, T., Isola, P., and Efros, A. A. (2017). Unpaired image-to-image translation using cycleconsistent adversarial networks. Proceedings of the IEEE international conference on computer vision.zh_TW