skip to main content
research-article

Out-of-distribution Detection in Dependent Data for Cyber-physical Systems with Conformal Guarantees

Published: 26 October 2024 Publication History

Abstract

Uncertainty in the predictions of learning-enabled components hinders their deployment in safety-critical cyber-physical systems (CPS). A shift from the training distribution of a learning-enabled component (LEC) is one source of uncertainty in the LEC’s predictions. Detection of this shift or out-of-distribution (OOD) detection on individual datapoints has therefore gained attention recently. But in many applications, inputs to CPS form a temporal sequence. Existing techniques for OOD detection in time-series data for CPS either do not exploit temporal relationships in the sequence or do not provide any guarantees on detection. We propose using deviation from the in-distribution temporal equivariance as the non-conformity measure in conformal anomaly detection framework for OOD detection in time-series data for CPS. Computing independent predictions from multiple conformal detectors based on the proposed measure and combining these predictions by Fisher’s method leads to the proposed detector CODiT with bounded false alarms.
CODiT performs OOD detection on fixed-length windows of consecutive time-series datapoints by using Fisher value of the input window. We further propose performing OOD detection on real-time time-series traces of variable lengths with bounded false alarms. This can be done by using CODiT to compute Fisher values of the sliding windows in the input trace and combining these values by a merging function. Merging functions such as Harmonic Mean, Arithmetic Mean, Geometric Mean, Bonferroni Method, and so on, can be used to combine Fisher values of the sliding windows in the input trace, and the combined value can be used for OOD detection on the trace with bounded false alarm rate guarantees.
We illustrate the efficacy of CODiT by achieving state-of-the-art results in two case studies for OOD detection on fixed-length windows. The first one is on an autonomous driving system with perception (or vision) LEC. The second case study is on a medical CPS for walking pattern or GAIT analysis where physiological (non-vision) data is collected with force-sensitive resistors attached to the subject’s body. For OOD detection on variable length traces, we consider the same case studies on the autonomous driving system and medical CPS for GAIT analysis. We report our results with four merging functions on the Fisher values computed by CODiT on the sliding windows of the input trace. We also compare the false alarm rate guarantees by these four merging functions in the autonomous driving system case study. Code, data, and trained models are available at https://github.com/kaustubhsridhar/time-series-OOD.

References

[1]
Vineeth Balasubramanian, Shen-Shyang Ho, and Vladimir Vovk. 2014. Conformal Prediction for Reliable Machine Learning: Theory, Adaptations and Applications. Newnes.
[2]
Michele Basseville and Igor V. Nikiforov. 1993. Detection of Abrupt Changes: Theory and Application. Vol. 104. Prentice Hall, Englewood Cliffs, NJ.
[3]
Rezaul Begg and Joarder Kamruzzaman. 2006. Neural networks for detection and classification of walking pattern changes due to ageing. Australas. Phys. Eng. Sci. Medic. 29, 2 (2006), 188–195.
[4]
Mariusz Bojarski, Davide Del Testa, Daniel Dworakowski, Bernhard Firner, Beat Flepp, Prasoon Goyal, Lawrence D. Jackel, Mathew Monfort, Urs Muller, Jiakai Zhang, Xin Zhang, and Jake Zhao. 2016. End to end learning for self-driving cars. arXiv preprint arXiv:1604.07316 (2016).
[5]
Feiyang Cai and Xenofon Koutsoukos. 2020. Real-time out-of-distribution detection in learning-enabled cyber-physical systems. In ACM/IEEE 11th International Conference on Cyber-Physical Systems (ICCPS’20). IEEE, 174–183.
[6]
Evangelos Chatzipantazis, Stefanos Pertigkiozoglou, Kostas Daniilidis, and Edgar Dobriban. 2021. Learning augmentation distributions using transformed risk minimization. arXiv preprint arXiv:2111.08190 (2021).
[7]
Shuxiao Chen, Edgar Dobriban, and Jane H. Lee. 2020. A group-theoretic framework for data augmentation. J. Mach. Learn. Res. 21, 245 (2020), 1–71.
[8]
Jeffrey De Fauw, Joseph R Ledsam, Bernardino Romera-Paredes, Stanislav Nikolov, Nenad Tomasev, Sam Blackwell, Harry Askham, Xavier Glorot, Brendan O’Donoghue, Daniel Visentin, George van den Driessche, Balaji Lakshminarayanan, Clemens Meyer, Faith Mackinder, Simon Bouton, Kareem Ayoub, Reena Chopra, Dominic King, Alan Karthikesalingam, Cían O Hughes, Rosalind Raine, Julian Hughes, Dawn A Sim, Catherine Egan, Adnan Tufail, Hugh Montgomery, Demis Hassabis, Geraint Rees, Trevor Back, Peng T. Khaw, Mustafa Suleyman, Julien Cornebise, Pearse A. Keane, and Olaf Ronneberger. 2018. Clinically applicable deep learning for diagnosis and referral in retinal disease. Nat. Medic. 24, 9 (2018), 1342–1350.
[9]
Alexey Dosovitskiy, German Ros, Felipe Codevilla, Antonio Lopez, and Vladlen Koltun. 2017. CARLA: An open urban driving simulator. In Conference on Robot learning. PMLR, 1–16.
[10]
Yeli Feng, Daniel Jun Xian Ng, and Arvind Easwaran. 2021. Improving variational autoencoder based out-of-distribution detection for embedded real-time applications. ACM Trans. Embed. Comput. Syst. 20, 5s (2021), 1–26.
[11]
R. A. Fisher. 1932. Statistical Methods for Research Workers. (4th ed.) Oliver & Boyd.
[12]
Jingkun Gao, Xiaomin Song, Qingsong Wen, Pichao Wang, Liang Sun, and Huan Xu. 2020. RobustTAD: Robust time series anomaly detection via decomposition and convolutional neural networks. arXiv preprint arXiv:2002.09545 (2020).
[13]
Georgia Gkioxari, Ross Girshick, and Jitendra Malik. 2015. Contextual action recognition with R*CNN. In IEEE International Conference on Computer Vision. 1080–1088.
[14]
Matan Haroush, Tzviel Frostig, Ruth Heller, and Daniel Soudry. 2021. A statistical framework for efficient out of distribution detection in deep neural networks. In International Conference on Learning Representations.
[15]
Jeffrey M. Hausdorff, Apinya Lertratanakul, Merit E. Cudkowicz, Amie L. Peterson, David Kaliton, and Ary L. Goldberger. 2000. Dynamic markers of altered gait rhythm in amyotrophic lateral sclerosis. J. Appl. Physiol. 88 (2000), 2045–2053.
[16]
Dan Hendrycks and Kevin Gimpel. 2017. A baseline for detecting misclassified and out-of-distribution examples in neural networks. In International Conference on Learning Representations.
[17]
Simon Jenni and Hailin Jin. 2021. Time-equivariant contrastive video representation learning. In IEEE/CVF International Conference on Computer Vision. 9970–9980.
[18]
Xiayan Ji, Hyonyoung Choi, Oleg Sokolsky, and Insup Lee. 2023. Incremental anomaly detection with guarantee in the internet of medical things. In 8th ACM/IEEE Conference on Internet of Things Design and Implementation. 327–339.
[19]
Xiayan Ji, Xian Li, Ahhyun Yuh, Amanda Watson, Claire Kendell, James Weimer, Hajime Nagahara, Teruo Higashino, Teruhiro Mizumoto, Viktor Erdélyi, George Demiris, Oleg Sokolsky, and Insup Lee. 2023. Short: Integrated sensing platform for detecting social isolation and loneliness in the elderly community. In IEEE/ACM Conference on Connected Health: Applications, Systems and Engineering Technologies (CHASE’23). IEEE, 148–152.
[20]
Yiannis Kantaros, Taylor Carpenter, Kaustubh Sridhar, Yahan Yang, Insup Lee, and James Weimer. 2021. Real-time detectors for digital and physical adversarial inputs to perception systems. In ACM/IEEE 12th International Conference on Cyber-Physical Systems (ICCPS’21). 67–76.
[21]
Ramneet Kaur, Radoslav Ivanov, Matthew Cleaveland, Oleg Sokolsky, and Insup Lee. 2020. Assurance case patterns for cyber-physical systems with deep neural networks. In International Conference on Computer Safety, Reliability, and Security. Springer, 82–97.
[22]
Ramneet Kaur, Susmit Jha, Anirban Roy, Sangdon Park, Edgar Dobriban, Oleg Sokolsky, and Insup Lee. 2022. iDECODe: In-distribution Equivariance for Conformal Out-of-distribution Detection, Association for the Advancement of Artificial Intelligence. arxiv:2201.02331 [cs.LG]
[23]
Ramneet Kaur, Susmit Jha, Anirban Roy, Sangdon Park, Oleg Sokolsky, and Insup Lee. 2021. Detecting oods as datapoints with high uncertainty. arXiv preprint arXiv:2108.06380 (2021).
[24]
Ramneet Kaur, Susmit Jha, Anirban Roy, Oleg Sokolsky, and Insup Lee. 2021. Are all outliers alike? On understanding the diversity of outliers for detecting OODs. arXiv preprint arXiv:2103.12628 (2021).
[25]
Ramneet Kaur, Susmit Jha, Anirban Roy, Oleg Sokolsky, and Insup Lee. 2023. Predicting out-of-distribution performance of deep neural networks using model conformance. In IEEE International Conference on Assured Autonomy (ICAA’23). IEEE, 19–28.
[26]
Ramneet Kaur, Xiayan Ji, Souradeep Dutta, Michele Caprio, Yahan Yang, Elena Bernardis, Oleg Sokolsky, and Insup Lee. 2023. Using semantic information for defining and detecting OOD inputs. arXiv preprint arXiv:2302.11019 (2023).
[27]
Ramneet Kaur, Yiannis Kantaros, Wenwen Si, James Weimer, and Insup Lee. 2023. Detection of adversarial physical attacks in time-series image data. arXiv preprint arXiv:2304.13919 (2023).
[28]
Ramneet Kaur, Kaustubh Sridhar, Sangdon Park, Yahan Yang, Susmit Jha, Anirban Roy, Oleg Sokolsky, and Insup Lee. 2023. CODiT: Conformal out-of-distribution detection in time-series data for cyber-physical systems. In ACM/IEEE 14th International Conference on Cyber-Physical Systems (with CPS-IoT Week’23). 120–131.
[29]
Rikard Laxhammar and Göran Falkman. 2015. Inductive conformal anomaly detection for sequential detection of anomalous sub-trajectories. Ann. Math. Artif. Intell. 74, 1 (2015), 67–94.
[30]
Yann LeCun, Léon Bottou, Yoshua Bengio, and Patrick Haffner. 1998. Gradient-based learning applied to document recognition. Proc. IEEE 86, 11 (1998), 2278–2324.
[31]
Shuo Li, Xiayan Ji, Edgar Dobriban, Oleg Sokolsky, and Insup Lee. 2022. PAC-wrap: Semi-supervised PAC anomaly detection. In 28th ACM SIGKDD Conference on Knowledge Discovery and Data Mining. 945–955.
[32]
Navonil Majumder, Soujanya Poria, Alexander Gelbukh, and Erik Cambria. 2017. Deep learning-based document modeling for personality detection from text. IEEE Intelli. Syst. 32, 2 (2017), 74–79.
[33]
Alam Noor, Bilel Benjdira, Adel Ammar, and Anis Koubaa. 2020. DriftNet: Aggressive driving behavior classification using 3D EfficientNet architecture. arXiv preprint arXiv:2004.11970 (2020).
[34]
Guo-Jun Qi, Liheng Zhang, Chang Wen Chen, and Qi Tian. 2019. AVT: Unsupervised learning of transformation equivariant representations by autoencoding variational transformations. In IEEE International Conference on Computer Vision. 8130–8139.
[35]
Shreyas Ramakrishna, Zahra Rahiminasab, Gabor Karsai, Arvind Easwaran, and Abhishek Dubey. 2021. Efficient out-of-distribution detection using latent space of \(\beta\)-VAE for cyber-physical systems. arXiv preprint:2108.11800 (2021).
[37]
Uwe Schmidt and Stefan Roth. 2012. Learning rotation-aware features: From invariant priors to equivariant descriptors. In IEEE Conference on Computer Vision and Pattern Recognition. IEEE, 2050–2057.
[38]
Kaustubh Sridhar, Souradeep Dutta, Ramneet Kaur, James Weimer, Oleg Sokolsky, and Insup Lee. 2022. Towards alternative techniques for improving adversarial robustness: Analysis of adversarial training at a spectrum of perturbations. arXiv preprint arXiv:2206.06496 (2022).
[39]
Johannes Stallkamp, Marc Schlipsing, Jan Salmen, and Christian Igel. 2012. Man vs. computer: Benchmarking machine learning algorithms for traffic sign recognition. Neural Netw. 32 (2012), 323–332.
[40]
Jihoon Tack, Sangwoo Mo, Jongheon Jeong, and Jinwoo Shin. 2020. CSI: Novelty detection via contrastive learning on distributionally shifted instances. Adv. Neural Inf. Process. Syst. 33 (2020).
[41]
Ashish Tiwari, Bruno Dutertre, Dejan Jovanović, Thomas de Candia, Patrick D. Lincoln, John Rushby, Dorsa Sadigh, and Sanjit Seshia. 2014. Safety envelope for security. In 3rd International Conference on High Confidence Networked Systems. 85–94.
[42]
Paolo Toccaceli and Alexander Gammerman. 2017. Combination of conformal predictors for classification. In Conformal and Probabilistic Prediction and Applications. PMLR, 39–61.
[43]
Du Tran, Heng Wang, Lorenzo Torresani, Jamie Ray, Yann LeCun, and Manohar Paluri. 2018. A closer look at spatiotemporal convolutions for action recognition. In IEEE Conference on Computer Vision and Pattern Recognition. 6450–6459.
[44]
Vladimir Vovk, Ilia Nouretdinov, and Alexander Gammerman. 2003. Testing exchangeability on-line. In 20th International Conference on Machine Learning (ICML’03). 768–775.
[45]
Vladimir Vovk and Ruodu Wang. 2020. Combining p-values via averaging. Biometrika 107, 4 (2020), 791–808.
[46]
Yahan Yang, Ramneet Kaur, Souradeep Dutta, and Insup Lee. 2022. Interpretable detection of distribution shifts in learning enabled cyber-physical systems. In ACM/IEEE International Conference on CyberPhysical Systems.

Index Terms

  1. Out-of-distribution Detection in Dependent Data for Cyber-physical Systems with Conformal Guarantees

    Recommendations

    Comments

    Information & Contributors

    Information

    Published In

    cover image ACM Transactions on Cyber-Physical Systems
    ACM Transactions on Cyber-Physical Systems  Volume 8, Issue 4
    October 2024
    248 pages
    EISSN:2378-9638
    DOI:10.1145/3613678
    • Editor:
    • Chenyang Lu
    Issue’s Table of Contents

    Publisher

    Association for Computing Machinery

    New York, NY, United States

    Journal Family

    Publication History

    Published: 26 October 2024
    Online AM: 13 February 2024
    Accepted: 24 January 2024
    Revised: 16 November 2023
    Received: 07 July 2023
    Published in TCPS Volume 8, Issue 4

    Check for updates

    Author Tags

    1. Learning-enabled components
    2. cyber-physical systems
    3. time-series
    4. out-of-distribution
    5. dependent data
    6. conformal detection
    7. false alarms guarantees

    Qualifiers

    • Research-article

    Funding Sources

    • Army Research Office and was accomplished

    Contributors

    Other Metrics

    Bibliometrics & Citations

    Bibliometrics

    Article Metrics

    • 0
      Total Citations
    • 302
      Total Downloads
    • Downloads (Last 12 months)302
    • Downloads (Last 6 weeks)24
    Reflects downloads up to 20 Feb 2025

    Other Metrics

    Citations

    View Options

    Login options

    Full Access

    View options

    PDF

    View or Download as a PDF file.

    PDF

    eReader

    View online with eReader.

    eReader

    Full Text

    View this article in Full Text.

    Full Text

    Figures

    Tables

    Media

    Share

    Share

    Share this Publication link

    Share on social media