The 6th International Conference on Wireless, Intelligent and Distributed Environment for Communication: WIDECOM 2023 (Lecture Notes on Data Engineering and Communications Technologies, 185) 3031471253, 9783031471254

This book presents the proceedings of the 6th International Conference on Wireless Intelligent and Distributed Environme

123 82 9MB

English Pages 238 [229] Year 2023

Report DMCA / Copyright

DOWNLOAD FILE

Polecaj historie

The 6th International Conference on Wireless, Intelligent and Distributed Environment for Communication: WIDECOM 2023 (Lecture Notes on Data Engineering and Communications Technologies, 185)
 3031471253, 9783031471254

Table of contents :
Welcome Message from WIDECOM 2023 General Chair
Welcome Message from the WIDECOM 2023 Program Chair
WIDECOM 2023 Organizing Committee
WIDECOM 2023 Keynote Talks
Privacy, Security, and Safety Concerns for Consumer-Based Small-Scale Internet of Things
Intent Based Networking and Intelligent Network Assurance in Next Generation Networks
Contents
An AI-Enabled Vehicle Surveillance System to Tracking Entrance, Exit, and Parking of Vehicles on the University of Technology –Jamaica, Papine Campus
1 Introduction
2 Related Work
3 Methodology
4 Results
5 Conclusion
References
Differential Evolution-Based Weighted Voting Stacking Ensemble Classifier for Highly Skewed Binary Data Distribution
1 Introduction and Background
1.1 Differential Evolution Algorithm
1.1.1 Initial Population
1.1.2 Mutation
1.1.3 Recombination
1.1.4 Selection
1.1.5 Termination
2 Research Questions and Objectives
2.1 Research Questions
2.2 Research Objectives
3 Research Design
3.1 Stacking Ensemble Method
3.2 Differential Evolution Optimization Method
4 Performance Evaluation
5 Conclusion
References
Toward a Lightweight Cryptographic Key Management System in IoT Sensor Networks
1 Introduction
2 Related Works
3 A-Star Algorithm
3.1 Preliminaries
3.2 Description
4 Network Model
4.1 Assumption
4.2 Energy Model
5 Protocol Design
5.1 Discovery Phase
5.2 Operational Phase and Security Analysis
6 Simulation and Discussion
7 Conclusion
References
Edge Clustering and Communication Efficiency with GNNs in Internet of Vehicles
1 Introduction
2 Related Work
2.1 Traditional Intelligent Vehicular Networks
2.2 Graph Neural Networks-Based Intelligent Vehicular Networks
3 Problem Statement
4 GNN-Based Vehicular Edge Clustering
4.1 VANET Graphs
4.2 GNN Architecture
4.3 Clustering
5 Experiments
5.1 Data
5.2 Settings
5.3 Results
5.3.1 Model Training Results
5.3.2 Average Distance to Centroid
5.3.3 Mean Squared Error and Sum of Squared Error
5.3.4 Silhouette Score
5.3.5 Davies–Bouldin Index
5.3.6 Area Under the Curve and Average Precision
6 Conclusion
References
Discrete Planar Two-Watchtower Problem for k-Visibility
1 Introduction
1.1 Preliminaries
1.2 Problem Definition
1.3 Related Work
2 Main Result
2.1 Algorithm
3 A Terrain Guarded by Two Watchtowers with 2-Visibility
4 Conclusion and Future Work
References
Towards Intra-cluster Data Prediction in IoT for Efficient Energy Consumption
1 Introduction
2 Related Work
3 Energy Prediction Model for Data Aggregation
3.1 Problem Statement
3.2 Network Model
3.3 Prediction and Data Transmission Approach
3.3.1 Cluster Formation
3.3.2 Election of the Cluster Head
3.3.3 Predicting the Data to Be Sent
3.3.4 Energy Model
3.3.5 Intra-cluster Prediction
4 Experimental Results
4.1 Comparative Analysis
5 Conclusion
References
Location-Based Clustering Approach for Next-Hop Selection in Opportunistic Networks
1 Introduction
2 Related Works
3 System Model
3.1 Methods Used and Their Roles
4 Simulation and Evaluation
5 Conclusion
References
Dungeons, Dragons, and Data Breaches: Analyzing AI Attacks on Various Network Configurations
1 Introduction
2 Background
2.1 Reinforcement Learning
2.2 Q-Learning
2.3 Deep-Q-Learning
2.4 Related Work
3 Methodology
3.1 Environments
3.1.1 Chain Network
3.1.2 Toy Network
3.1.3 Custom Network
4 Performance Evaluation Results
4.1 Cumulative Reward per Epoch Generated by the Chain Network
4.2 Cumulative Reward per Epoch Generated by the Toy Network
4.3 Cumulative Reward per Epoch Generated by the Custom Network
4.4 Average Time Generated by the Chain Network
4.5 Average Time Generated by the Toy Network
4.6 Average Time Generated by the Custom Network
5 Conclusion
References
Q-Learning-Based Underwater Sensor Networks Routing Protocol for Pollution Monitoring
1 Introduction
1.1 Organization
2 Background
2.1 Reinforcement Learning
2.2 Q-LEARNING Technique
2.3 Acoustic Communication
2.4 Magnetic Induction Communication
3 Proposed Q-Learning for UWSNs
4 Performance Evaluation
5 Conclusion
References
Flood Forecasting in the Far-North Region of Cameroon: A Comparative Study of Machine Learning and Deep Learning Methods
1 Introduction
1.1 Background
1.2 Contribution of the Authors
1.3 Organization of the Paper
2 Related Works
3 ML and DL Models
3.1 1D-CNN
3.2 LSTM
3.3 MLP
4 Study Area and Data
4.1 Study Area
4.2 Data
5 Design and Comparison of Models
5.1 Methods
5.2 Model Performance Evaluation
5.3 Comparison of Models for Short-Term Flood Forecasting
5.4 Comparison of Models for Long-Term Flood Forecasting
6 Results and Discussion
7 Conclusion
References
A Multifactorial Approach to Explain Risk Features for Predicting Survival Rate of Heart Failure
1 Introduction
2 Related Works
3 Descriptive Statistics on Clinical Heart Failure Dataset
4 Feature Selection
5 Conclusion
References
Performance Evaluation of Data Stream Clustering Algorithm on Parameter Specification
1 Introduction
2 Clustering Techniques
2.1 Partitioning-Based
2.2 Hierarchical-Based Clustering
2.3 Grid-Based Clustering
2.4 Density-Based Clustering
2.5 Model-Based Clustering
3 Clustering Performance Metrics
4 Massive Online Analysis Framework for Clustering
4.1 Massive Online Analysis Graphical User Interface
4.2 Massive Online Analysis Clustering
4.3 Datasets
4.4 Evaluation Platform Setup
4.5 Experimental Approach
5 Experimental Results
5.1 DenStream with Ticked EvaluateMicroClustering on Synthetic Data
5.2 DenStream with Ticked EvaluateMicroClustering on Real-World Datasets
5.3 Discussion
6 Conclusion
References
Detecting DDoS Attacks in the Internet of Medical Things Through Machine Learning-Based Classification
1 Introduction
2 Related Works
3 Descriptive Analysis on MedibotDDoS Dataset
4 Experimental Evaluation
5 Conclusion
References
SmishShield: A Machine Learning-Based Smishing Detection System
1 Introduction
2 Related Works
3 Methodology
3.1 Data Collection
3.2 Text Processing and Encoding
3.3 Feature Extraction and Vectorizaton
3.4 Model Training
3.4.1 Test and Training Size
3.5 Evaluation
3.5.1 Accuracy
3.5.2 Precision
3.5.3 AUC
4 Results and Discussion
4.1 Message Length Analysis
4.2 Relevant Features
4.3 Model Performance
5 Conclusion
References
Index

Citation preview

Lecture Notes on Data Engineering and Communications Technologies 185

Isaac Woungang Sanjay Kumar Dhurandher   Editors

The 6th International Conference on Wireless, Intelligent and Distributed Environment for Communication WIDECOM 2023

Lecture Notes on Data Engineering and Communications Technologies Volume 185

Series Editor Fatos Xhafa, Technical University of Catalonia, Barcelona, Spain

The aim of the book series is to present cutting edge engineering approaches to data technologies and communications. It will publish latest advances on the engineering task of building and deploying distributed, scalable and reliable data infrastructures and communication systems. The series will have a prominent applied focus on data technologies and communications with aim to promote the bridging from fundamental research on data science and networking to data engineering and communications that lead to industry products, business knowledge and standardisation. Indexed by SCOPUS, INSPEC, EI Compendex. All books published in the series are submitted for consideration in Web of Science.

Isaac Woungang • Sanjay Kumar Dhurandher Editors

The 6th International Conference on Wireless, Intelligent and Distributed Environment for Communication WIDECOM 2023 International Conference on Wireless Intelligent and Distributed Environment for Communication, St. Catharines, ON, Canada 11 October–13 October 2023

Editors Isaac Woungang Department of Computer Science Ryerson University Toronto, ON, Canada

Sanjay Kumar Dhurandher Department of Information Technology Netaji Subhas University of Technology New Delhi, Delhi, India

ISSN 2367-4512 ISSN 2367-4520 (electronic) Lecture Notes on Data Engineering and Communications Technologies ISBN 978-3-031-47125-4 ISBN 978-3-031-47126-1 (eBook) https://doi.org/10.1007/978-3-031-47126-1 © The Editor(s) (if applicable) and The Author(s), under exclusive license to Springer Nature Switzerland AG 2024 This work is subject to copyright. All rights are solely and exclusively licensed by the Publisher, whether the whole or part of the material is concerned, specifically the rights of translation, reprinting, reuse of illustrations, recitation, broadcasting, reproduction on microfilms or in any other physical way, and transmission or information storage and retrieval, electronic adaptation, computer software, or by similar or dissimilar methodology now known or hereafter developed. The use of general descriptive names, registered names, trademarks, service marks, etc. in this publication does not imply, even in the absence of a specific statement, that such names are exempt from the relevant protective laws and regulations and therefore free for general use. The publisher, the authors, and the editors are safe to assume that the advice and information in this book are believed to be true and accurate at the date of publication. Neither the publisher nor the authors or the editors give a warranty, expressed or implied, with respect to the material contained herein or for any errors or omissions that may have been made. The publisher remains neutral with regard to jurisdictional claims in published maps and institutional affiliations. This Springer imprint is published by the registered company Springer Nature Switzerland AG The registered company address is: Gewerbestrasse 11, 6330 Cham, Switzerland Paper in this product is recyclable.

Welcome Message from WIDECOM 2023 General Chair

Welcome to the 6th International Conference on Wireless, Intelligent, and Distributed Environment for Communication (WIDECOM 2023). The last decade has witnessed tremendous advances in computing and networking technologies, with the appearance of new paradigms such as Internet of Things (IoT) and cloud computing, which have led to advances in wireless and intelligent systems for communications. Undoubtedly, these technological advances help improve many facets of human lives, for instance, through better healthcare delivery, faster and more reliable communications, significant gains in productivity, and so on. At the same time, the associated increasing demand for a flexible and cheap infrastructure for collecting and monitoring real-world data nearly everywhere, coupled with the aforementioned integration of wireless mobile systems and network computing, raises new challenges with respect to the dependability of integrated applications and the intelligence-driven security threats against the platforms supporting these applications. The WIDECOM conference is a conference series that provides a venue for researchers and practitioners to present, learn, and discuss recent advances in new dependability paradigms, design, and performance of dependable network computing and mobile systems, as well as issues related to the security of these systems. Every year, WIDECOM receives several dozens of submissions from around the world. Building on the success from last year, WIDECOM 2023 presents an exciting technical program that is the work of many volunteers. The program consists of a combination technical papers, keynotes, and tutorials. The technical papers are peer reviewed by program committee members who are all experts and researchers, through a blind process. We received a total of 33 papers this year, and accepted 13 papers for inclusion in the proceedings and presentation at the conference, which corresponds to an acceptance rate of about 39.4%. Papers were reviewed by three Technical Program Committee members, in a single round of review. WIDECOM 2023 is privileged to have select guest speakers to provide stimulating presentations on topics of wide interest. This year’s Distinguished Speakers are: v

vi

Welcome Message from WIDECOM 2023 General Chair

• Dr. Benjamin Yankson, Department of Cybersecurity at the College of Emergency Preparedness, Homeland Security, and Cybersecurity (CEHC) at the University at Albany, SUNY, USA. • Professor Aris Leivadeas, Department of Software and IT Engineering, École de Technologie Supérieure (ÉTS), Montreal, Canada. We would like to thank all of the volunteers for their contributions to WIDECOM 2023. Our thanks go to the authors, and our sincere gratitude goes to the Program Committee, who gave much extra time to carefully review the submissions. We are pleased to announce that selected papers will be invited to submit extended versions for publication in the Internet of Things: Engineering Cyber Physical Human Systems, Elsevier. We would like also to thank the local organizing committee team, for their support and hard work in making this event a success. We also thank our sponsors: • Computer Science Department, Brock University, for hosting WIDECOM 2023. • Springer, for publishing the Conference Proceedings. Finally, we thank all the attendees and the WIDECOM 2023 community for their continuing support, by submitting papers and by volunteering their time and talent in other ways. We hope you will find the papers presented interesting and enjoy the conference. Dr Glaucio H. S. Carvalho WIDECOM 2023 Conference Chair

Welcome Message from the WIDECOM 2023 Program Chair

Welcome to the 6th International Conference on Wireless, Intelligent, and Distributed Environment for Communication (WIDECOM 2023), which was held on October 11–13, 2023, Brock University, St. Catharines, Ontario, Canada. WIDECOM 2023 provides a forum for researchers and practitioners from industry and government to present, learn, and discuss recent advances in new dependability paradigms, design, and performance of dependable network computing and mobile systems, as well as issues related to the security of these systems. The papers selected for publication in the proceedings of WIDECOM 2023 span many research issues related to the aforementioned research areas, covering aspects such as algorithms, architectures, protocols dealing with network computing, ubiquitous and cloud systems and Internet of Things systems, integration of wireless mobile systems and network computing, and security. We hope the participants of this conference will benefit from this coverage of a wide range of current topics. In this edition, 38 papers were submitted, and peer-reviewed by the Program Committee members and external reviewers who are experts in the topical areas covered by the papers. The Program Committee accepted 17 papers out of 33 (about 39.39% acceptance ratio). The conference program also includes two distinguished keynote speeches and three tutorials. Our thanks go to the many volunteers who have contributed to the organization of WIDECOM 2023. We would like to thank all authors for submitting their papers. We also like to thank the Program Committee members for thoroughly reviewing the submissions and making valuable recommendations. We would like to thank the WIDECOM 2023 Local Arrangement team for their excellent organization of the conference, and for their effective coordination creating the recipe for a very successful conference. We hope you will enjoy the conference and have a great time in St. Catharines, Ontario, Canada. WIDECOM 2023 Program Committee Chair Sanjay Kumar Dhurandher, University of Delhi, India

vii

WIDECOM 2023 Organizing Committee

General Co-chairs Glaucio H.S. de Carvalho, Brock University, Canada Naser Ezzati-Jivan, Brock University, Canada Robson De Grande, Brock University, Canada Program Co-Chairs Sanjay Kumar Dhurandher, University of Delhi, India Glaucio H.S. de Carvalho, Brock University, Canada Tutorials/Posters Chairs Patrice Kisanga, Toronto Metropolitan University, Canada Amir Mohammadi Bhaga, Toronto Metropolitan University, Canada Local Arrangements Chair Braden Saunders, Brock University, Canada Technical Program Committee Amita Malik, DCRUST, India Ahmed Ibrahim, University of Pittsburgh, USA Saqib Hakak, UNB, Canada Haytham Elmiligi, TRU, Canada Isaac Woungang, Toronto Metropolitan University, Canada Soltan Alharbi, University of Jeddah, Saudi Arabia Farid Ahmed, University of Texas Rio Grande Valley, USA Saleh Almowuena, King Saud University, Saudi Arabia Hisham Kholidy, State University of New York, USA Andrea Visconti, Milan University, Italy Jagdeep Singh, Sant Longowal Institute of Engineering and Technology, India Alessandro De Piccoli, University of Milan, Italy Bharat K. Bhargava, Purdue University, USA Chin-Feng Lai, National Ilan Univ., Taiwan Changyu Dong, Newcastle University, UK Chii Chang, University of Tartu, Estonia Cui Baojiang, Beijing University of Post and Telecommunications, China ChamseddineTalhi, École de Technologie Supérieure, Canada ix

x

WIDECOM 2023 Organizing Committee

Chen Ding, Ryerson University, Canada Danda B. Rawat, Howard University, USA Glaucio Silva de Carvalho, Brock University, Canada Hamed Aly, Acadia University, Canada Hamid Mcheick, Université du Quebec, Chicoutimi, Canada Hwang-Cheng Wang, National Ilan University, Taiwan Ilsun You, Soonchunhyang University, Republic of Korea Jose Luis Sevillano, University of Sevilla, Spain Joel Rodrigues, University of Beira Interior, Portugal Lu Wei, Keene State College, USA Luca Caviglione, National Research Council of Italy (CNR), Italy Marcelo Luis Brocardo, University of Santa Catarina, Brazil Michela Ceria, University of Milan, Italy Neeraj Kumar, Thapar Institute of Engineering and Technology, India Nitin Gupta, University of Delhi, India Petros Nicopolitidis, Aristotle University of Thessaloniki, Greece Rohit Ranchal, IBM Watson Health Cloud, USA Ruppa K. Thulasiram, University of Manitoba, Canada Sherif Saad Ahmed, University of Windsor, Canada Telex Magloire N. Ngatched, Memorial University of Newfoundland, Canada Udai Pratap Rao, S. V. National Institute of Technology, India Vinesh Kumar, University of Delhi, India Wahab Hamou-Lhadj, Concordia University, Canada Zelalem Shibeshi, University of Fort Hare, South Africa Zeadally Sherali, University of Kentucky, USA

WIDECOM 2023 Keynote Talks

Privacy, Security, and Safety Concerns for Consumer-Based Small-Scale Internet of Things Dr. Benjamin Yankson Department of Cybersecurity at the College of Emergency Preparedness, Homeland Security, and Cybersecurity (CEHC) at the University at Albany, SUNY, USA Abstract The rapid proliferation of Small-Scale Internet of Things (SSIoT) devices has revolutionized how we interact with technology, bringing unprecedented connectivity, convenience, and productivity. SSIoT can collect terabytes of sensitive information from physical context, interactive to personally identifiable information. The widespread adoption and benefits of SSIoT devices have also given rise to significant concerns regarding user privacy, safety, and security of personal information, resulting from dramatic increases in cyber-attacks, data breaches, and privacy violations. Although privacy problems are common to all IoT devices, SSIoT devices (i.e., AI-enabled children’s toys) are unique, vital, and urgent as the privacy breach can have harmful financial and reputation impact, with dire safety consequences for users. The problem is amplified by the ongoing production growth and use of SSIoT devices, the increasing vulnerability and threats landscape within the IoT sectors, and the growth in cyber-attacks with resulting privacy breaches. Addressing this problem is critical as it impacts families, policymakers, and companies. This talk will take the audience through a journey of privacy, security, and safety concerns for consumer-based SSIoT (such as AI-enabled children’s toys), discuss SSIoT research progress and gaps, and present experiential learning research involving Undergraduate students at the HackIoT lab within College of Emergency Preparedness, Homeland Security and Cybersecurity at the University at Albany (SUNY). The talk will also explore the proposed comprehensive privacy-preserving framework (PPF), which integrates a context data model, a privacy requirement and systematic privacy impact compliance model, an abstract theoretical privacy

xi

xii

WIDECOM 2023 Keynote Talks

protection model with technical architecture, and a malicious dialogue detection and data flow model using Petri net.

Intent Based Networking and Intelligent Network Assurance in Next Generation Networks Professor Aris Leivadeas Department of Software and IT Engineering, École de Technologie Supérieure (ÉTS), Montreal, Canada Abstract Current and future network services and applications are expected to revolutionize our society and lifestyle. At the same time, the abundant possibilities that new network technologies offer to end users, network operators, and administrators have created a cumbersome network configuration process to accommodate all different stakeholders and applications. Thus, lately, there is a need to simplify the management and configuration of the network, through possibly an autonomic and automatic way. Intent Based Networking (IBN) is such a paradigm that envisions flexible, agile, and simplified network configuration with minimal external intervention. This keynote will provide details of how the IBN concept works and what are the main components to guarantee a fully autonomous IBN system (IBNS). Particular emphasis will be given in network assurance, which has as a goal to autonomously trigger corrective actions, whenever the conditions of the network do not allow to fulfill the performance requirements of its users. Finally, light will be shed on the open challenges and future directions of this novel but unexplored research area.

Contents

An AI-Enabled Vehicle Surveillance System to Tracking Entrance, Exit, and Parking of Vehicles on the University of Technology–Jamaica, Papine Campus . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Dinito Thompson, Andrew Giscombe, Khadesha Armstrong, Nicholai Witter, Jordan Murray, David W. White, Christopher Panther, and Shaula Edwards-Braham Differential Evolution-Based Weighted Voting Stacking Ensemble Classifier for Highly Skewed Binary Data Distribution . . . . . . . . . Kgaugelo Moses Dolo and Ernest Mnkandla Toward a Lightweight Cryptographic Key Management System in IoT Sensor Networks . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Ado Adamou Abba Ari, Mounirah Djam-Doudou, Arouna Ndam Njoya, Hortense Boudjou Tchapgnouo, Nabila Labraoui, Ousmane Thiare, Wahabou Abdou, and Abdelhak Mourad Gueroui Edge Clustering and Communication Efficiency with GNNs in Internet of Vehicles. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Jessica Graham, Anthony Medico, Renata Dividino, and Robson E. De Grande Discrete Planar Two-Watchtower Problem for k-Visibility . . . . . . . . . . . . . . . . . Yeganeh Bahoo, Somnath Kundu, and Rudaba Syed Towards Intra-cluster Data Prediction in IoT for Efficient Energy Consumption . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Arouna Ndam Njoya, Innocent Emmanuel Batouri Maidadi, Ado Adamou Abba Ari, Wahabou Abdou, Sondes Khemiri Kallel, Ousmane Thiare, Abdelhak Mourad Gueroui, and Emmanuel Tonye Location-Based Clustering Approach for Next-Hop Selection in Opportunistic Networks . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Amit Dutta, Satya Jyoti Borah, and Jagdeep Singh

1

13

29

47

65

75

91

xiii

xiv

Contents

Dungeons, Dragons, and Data Breaches: Analyzing AI Attacks on Various Network Configurations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 111 Kevin Olenic and Sheridan Houghten Q-Learning-Based Underwater Sensor Networks Routing Protocol for Pollution Monitoring . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 127 Simon Chege and Tom Walingo Flood Forecasting in the Far-North Region of Cameroon: A Comparative Study of Machine Learning and Deep Learning Methods . . 143 Ado Adamou Abba Ari, Francis Yongwa Dtissibe, Arouna Ndam Njoya, Hamadjam Abboubakar, Abdelhak Mourad Gueroui, Ousmane Thiare, and Alidou Mohamadou A Multifactorial Approach to Explain Risk Features for Predicting Survival Rate of Heart Failure. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 159 Ling Xue and Wei Lu Performance Evaluation of Data Stream Clustering Algorithm on Parameter Specification. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 173 Tajudeen Akanbi Akinosho, Elias Tabane, and Wang Zenghui Detecting DDoS Attacks in the Internet of Medical Things Through Machine Learning-Based Classification . . . . . . . . . . . . . . . . . . . . . . . . . . . . 191 Brandon Peddle, Wei Lu, and Qiaoyan Yu SmishShield: A Machine Learning-Based Smishing Detection System . . . . 205 Gabriel Selorm Awumee, Justice Owusu Agyemang, Sarafina Serwaa Boakye, and Daniel Bempong Index . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 223

An AI-Enabled Vehicle Surveillance System to Tracking Entrance, Exit, and Parking of Vehicles on the University of Technology–Jamaica, Papine Campus Dinito Thompson, Andrew Giscombe, Khadesha Armstrong, Nicholai Witter, Jordan Murray, David W. White, Christopher Panther, and Shaula Edwards-Braham

1 Introduction According to [1], the majority of the local businesses in India, if not all, currently have a parking lot to accommodate customers who desire to park nearby. In recent years, the number of vehicles owned have increased significantly [2]. stated that in many cities in China, it has been reported that the average vehicle ownership has reached the world average level, with approximately 185 million vehicles being sold. In an interview [3], revealed that the University of Technology–Jamaica has recently developed a need for proper vehicle management on campus as it relates to tracking vehicles entering and exiting the compound, preventing parking lot violations, and alerting security about unwanted vehicles. As such, AI-enabled surveillance can assist the university in achieving these goals. In the past years, several different Automatic License Plate Recognition (ALPR) AI-based surveillance systems have been successfully developed in order to aid in vehicle parking management [4]. These systems tend to use other forms of technology, such as radio-frequency identification (RFID) and sensors to aid the surveillance system in managing vehicle parking [4, 5]. However, while these surveillance systems can aid in the management of vehicle parking, they lack features to aid in other security issues associated with parking, such as vehicle theft and unwanted vehicles entering the compound, and the experiments being

D. Thompson · A. Giscombe · K. Armstrong · N. Witter · J. Murray · D. W. White () C. Panther · S. Edwards-Braham University of Technology, Kingston, Jamaica e-mail: [email protected]; [email protected]; [email protected] © The Author(s), under exclusive license to Springer Nature Switzerland AG 2024 I. Woungang, S. K. Dhurandher (eds.), The 6th International Conference on Wireless, Intelligent and Distributed Environment for Communication, Lecture Notes on Data Engineering and Communications Technologies 185, https://doi.org/10.1007/978-3-031-47126-1_1

1

2

D. Thompson et al.

conducted to test the accuracy and speed of these systems not always being applicable to real-life situations due to how the experiments were conducted. Consequently, this presents a unique technological gap that artificial intelligence may be able to solve. Discussions surrounding the use of AI has been increasingly optimistic rather than pessimistic since 2009. However, specific concerns about AI losing control, ethical concerns, and its negative impact on work has grown in recent years [6]. AI that is applied to a specific use case has a more positive reception from the public. Compared with previous studies on medical doctors, the general public has a more positive attitude toward medical AI [7]. Equally as important, people with negative emotions toward AI may perceive fewer benefits and advise against its development. As such, the greater negative emotions related to AI decrease the respondents’ intention to support policies regulating its development [8]. As such, this project was initiated to analyze the extent to which AI-enabled surveillance systems could be used to assist UTech’s Security Department in the detection and subsequent tracking of vehicles on the University of Technology– Jamaica, Kingston main campus located in Papine. With the use of AI-enabled surveillance, we hoped to establish surveillance zones to help the security department in tracking vehicles entering and exiting the compound, preventing parking lot violations, and alerting security about unwanted vehicles. This study researches on the effectiveness of our surveillance system, Campus Vision, aided by deep learning technology, in detecting and tracking vehicles traversing the University of Technology–Jamaica campus, preventing parking lot violations, and alerting security about blacklisted vehicles. Additionally, the study examined the reception of security managers toward the use of such technology. The rest of this chapter is organized as follows: In Sect. 2, some related work are presented. In Sect. 3, the methodology is outlined. In Sect. 4, we present the results of our experiments. In Sect. 5, we conclude the chapter.

2 Related Work The global human population reached 8.0 billion in mid-November 2022 from an estimated 2.5 billion people in 1950, adding 1 billion people since 2010 and 2 billion since 1998 [9]. In a country like Jamaica, registered vehicles per 1000 inhabitants increased from 22 per 1000 inhabitants in the year 2000 to 131 per 1000 inhabitants in the year 2014, growing at an average annual rate of 119.16% [10]. With the increase of the population came an increase in the number of vehicles on the road, necessitating parking spaces when they are driven to specific locations such as organizations, etc. In these parking spaces, organizations such as educational institutions may face a variety of problems [11]. These include issues such as drivers disregarding reserved parking spaces, drivers forgetting where they parked in large parking lots or on large campuses, and finding culprits in the case of theft or criminal damage to vehicles [11].

An AI-Enabled Vehicle Surveillance System to-Tracking Entrance, Exit. . .

3

Due to the COVID-19 pandemic, the University of Technology–Jamaica implemented a blended approach to teaching, and vehicle traffic in the school was significantly decreased compared to before COVID-19. However, in recent times, classes and final exams for an increasing number of modules have been held inperson on campus, and there has been an ongoing discussion on having all classes on campus. Although vehicle traffic is not as high on the UTech Campus as it was before the COVID-19 pandemic, issues such as drivers parking in reserved spaces and security personnel not being fully aware of all cars passing through the campus still exist [3]. In parking lots without cameras or a parking management system, there is a reliance on security guards to mitigate these issues and distribute tickets to keep track of vehicles that enter. Even with cameras, without a parking management system in place, someone has to be constantly watching them or browsing their footage afterward to gain any information. These methods of managing parking lots limit easy access to information that could be used to prevent the issues listed earlier, in comparison to using a parking management system [12]. An AI- or IoTbased parking management system could help solve parking management problems faced by organizations and efficiently gain information [13]. The growth of urban populations and advancements in the automotive industry has led to an increase in the number of cars, creating complex parking challenges for both drivers and security. Intelligent Parking Management Systems (PMS) offer an optimal solution by helping drivers find available spaces [14]. One such implementation of a Parking Management System is via the use of radio-frequency identification (RFID) systems, which is a non-touching automatic identification technique that uses radio frequency for communication [15]. For a particular implementation of a PMS that used RFID technology, a modular approach was taken to a PMS, which aimed to integrate existing gate control systems and business management systems such as databases. The system provides APIs that correspond to existing systems and enables them to function as modules of the proposed system. The main management system communicates with the RFID system and other business management systems to control the lane gate fence through the middleware [16]. Additionally, a smart car parking system, using RFID, was developed to address the issue of parking in big cities, which causes traffic congestion and air pollution. The system monitors the availability of idle parking spaces and guides vehicles to the nearest slot. It also features pre-reservation of parking slots, which helps alleviate parking search congestion by allowing drivers to reserve parking slots in advance. Furthermore, the system detects the presence of vehicles using infrared (IR) sensors to manage the number of vehicles moving in and out of parking structures. The system is fully automated and simple to implement [17]. The ability to automatically identify and detect license plates is a crucial task for both traffic surveillance and parking management systems and for maintaining the flow of modern society. There have been numerous methods proposed for ALP detection and recognition [18]. A proposed system included two key modules, a license plate location module utilizing fuzzy disciplines to extract license plates from an image, and a license number identification module utilizing neural subjects

4

D. Thompson et al.

to recognize the numbers on the license plate. Experiments were conducted on the license plate location and number identification modules using 1088 images taken from various scenes and under different conditions. The license plate location module had a success rate of 97.9%, with 23 images failing to locate the license plates. The license number identification module had a success rate of 95.6%, with 47 images failing to identify the numbers on the license plates. The overall success rate for the LPR algorithm was 93.7% [19]. An Automatic License Plate Recognition (ALPR) system was developed using deep convolutional neural network (CNN) to tackle the challenge of recognizing license plates in real-time traffic videos. The system extracts license plate candidates from each frame by analyzing edge information and geometrical properties, ensuring high recall. These candidates are then processed by a CNN classifier for license plate detection, resulting in high precision. Additionally, the system utilizes a CNN classifier that is trained to recognize individual characters and a spatial transformer network (STN) to recognize characters in the license plate. The system shows impressive performance, even in the presence of variations such as tilt, distance, color, illumination, character size, and thickness. The system’s dataset is available for further research on this topic [20]. Furthermore, a Real-time Vehicle Management Framework (RtVMF) has a unique application in a PMS, which uses vehicle tracking and license plate recognition (LPR) to keep track of and improve the performance of a fleet of vehicles in real time as they enter and exit a compound. It allows for real-time monitoring and interaction with smart vehicles or a fleet of smart vehicles using metrics related to security, privacy, and dependability by monitoring various operational parameters [21]. By combining an RtVMF with a vehicle license plate recognition system and utilizing a condensation algorithm, which is a method used to group similar things in a set of data, often used for image or video processing, a real-time automatic vehicle management system was constructed, with a recognition rate of 99.3% and the average recognition time for one license plate being about 1.5 seconds [22]. On the contrary, these various technologies are not without their drawbacks and limitations. Full-scale adoption of RFID has several impediments, including but not limited to cost for RFID tags and setup, accuracy due to technological limitations of the tags and readers themselves, the evolution of standards, and supply chain issues [23]. Additionally, while the condensation algorithm is a widely used algorithm for tracking multiple objects in real time, it has some drawbacks. One of the main drawbacks is the requirement for proper initialization. The algorithm requires a good estimate of the initial position and state of the objects to be tracked, which can be difficult to obtain in practice [24]. Furthermore, in a real-time vehicle management system, the condensation algorithm is not as effective at tracking vehicles in heavy traffic. Additionally, in similar conditions with slightly tough weather conditions and a complex dataset, the efficiency was slightly low, to around 90% from 95% [25].

An AI-Enabled Vehicle Surveillance System to-Tracking Entrance, Exit. . .

5

When looking at implementing parking management systems, the use of AI poses some advantages in contrast to previously mentioned systems. Multiple studies have been conducted that yielded promising results. Firstly, an edge artificial intelligence-based parking surveillance system was developed for parking occupancy detection [26]. To reduce data transmission volume, the system was designed to perform computing tasks at the edge using Internet of things (IoT) devices such as the Raspberry PI 3b. TensorFlow Lite and transfer learning on the MIO-TCD (Multiple Instance Object Tracking in Crowded Scenes) traffic surveillance dataset were used to implement the system. The SORT (Simple Online and Realtime Tracking) algorithm was modified and utilized to track vehicles entering a parking lot. The study’s results showed that the system achieved an overall 95.6% detection accuracy in various conditions, including low lighting at night, high lighting during sunny daytime, indoor and outdoor environments, and in cloudy and rainy weather. Convolutional neural networks (CNNs), a subset of machine learning and a type of artificial neural network, are utilized for various applications and to handle different types of data. They are a type of network architecture for deep learning, particularly suited for image recognition and other tasks that involve pixel data processing [27]. Another application of artificial intelligence in the field of parking management was explored and utilizes such technology. Specifically, the research aimed to investigate the feasibility of using AI to automatically count the number of vehicles present in a parking lot, utilizing images captured by smart cameras [28]. Said smart cameras also utilize edge AI like the previously mentioned system [26]. The cameras are equipped with the CNN deep learning algorithm running alongside the CNRPark-EXT dataset, which is a collection of images taken from the parking lot on the campus of the National Research Council (CNR) in Pisa, Italy. Cameras were set up on poles adjacent to each other overlooking the parking lot with an even distance between each; with that there was the problem of overlapping fields of view (FOV). As for the counting, each camera communicates with the rest and counts the number of cars locally by combining a CNN-based counting technique with a geometric-based approach that estimates the number of vehicles present in the overlapping fields of view, the latter of which solves the FOV problem. This technology has the potential to significantly aid in the tracking aspect of vehicle management by providing administrative users with real-time information on the number of vehicles present on a given campus or property. The study’s findings indicate that AI-based vehicle counting systems have the potential to be highly accurate and efficient and could potentially be implemented in a wide range of settings to improve the overall efficiency and effectiveness of vehicle management. A more relevant study in the field of AI-assisted parking management is that of a system that utilizes embedded cameras to record the license plate numbers of vehicles entering a parking lot by implementing optical character recognition (OCR) and object identification techniques to track vehicles’ license plate numbers [29]. Furthermore, this system is also equipped with advanced deep learning algorithms, such as YOLO and CNN, to detect and respond to vehicle collisions in real-time. YOLO (You Only Look Once) is a real-time object detection algorithm that uses

6

D. Thompson et al.

CNNs to identify objects within an image [30]. A Raspberry Pi system equipped with a camera at the entrance of a parking lot is used to identify vehicles by their license plate numbers. The system uses YOLO v3 algorithm, where the license plate number of the vehicle is identified at the entrance and sent to the tracking system. The tracking system then uses that number as an object ID and applies the image captured by the CCTV camera through the YOLO algorithm to track the vehicle in the parking lot. The system also includes applications for tracking vehicles and managing parking spaces. To make this information available to drivers, the data is sent to a cloud system provided by Amazon Web Services (AWS) and made accessible through a smartphone app. This allows drivers to access realtime information such as the location of parked cars and the number of available spaces in the parking lot. As for accident detection, the system is designed to detect collisions that may occur while vehicles are moving inside the parking lot. It uses deep learning techniques to detect these collisions. To train the system, more than 500 images of both collision and non-collision cases were used. The system provides a comprehensive solution for managing vehicles in a parking lot, by tracking the location of each vehicle and ensuring the safety of all vehicles and individuals in the area. In the conducting of experiments with the system, a detection accuracy of greater than 95% was observed for both accident and parking detections.

3 Methodology We conducted a quasi-experiment on a prototype of Campus Vision that we constructed. We also conducted an interview with the university’s security manager. An invitation was sent to the security manager who was given two weeks to consider participating in the interview. The interview was held via the Google Meet platform. To protect the participant’s privacy, the meeting was not recorded. The interview consisted of ten open-ended questions aimed at obtaining the participant’s insight and opinions on the parking management issues on the university’s campus at that time, as well as the potential implementation of the Campus Vision prototype. After the completion of the proposed prototype, a quasi-experiment was conducted at the University of Technology main campus in Kingston, Jamaica. The quasi-experiment was utilized for this study due to the fact that we were not able to alter camera positions and angles. The purpose of this quasi-experiment was to test the effectiveness of Campus Vision in accurately tracking vehicles entering and exiting the university’s campus and detecting parking lot violations, such as the misuse of reserved parking spots, ultimately determining if the system could assist in the proper management of vehicles and parking on the compound. Figure 1 shows the data flow for the prototype of our system. The quasi-experiment involved pre-recorded footage of vehicles entering and exiting the campus, while the prototype monitored the reserved parking spots. The accuracy of the system in performing its tasks was evaluated by calculating the

An AI-Enabled Vehicle Surveillance System to-Tracking Entrance, Exit. . .

7

Fig. 1 Campus Vision prototype data pipeline

average accuracy of detection and identification of vehicles, license plates, and their numbers. This application was designed for Windows 10 and 11 computers. It used the Python programming language and relied on the YOLO framework, specifically the YOLO-NAS and YOLO-V3 models. The application’s graphical user interface (GUI) was developed using Qt-Designer, providing a visually appealing and interactive interface. The GUI, initially in .UI file format, was converted to Python code (.PY file) to incorporate advanced functionalities such as license plate/vehicle display, live feed visualization, and blacklist management. The application used a localized database to store and manage various data elements, including detected vehicles, license plates, and live feeds. Users were able to specify a date range to retrieve information on vehicles and license plates that entered or exited the campus during that period. It was also possible to search for a specific license plate. The application allowed users to verify the correct vehicle occupancy in reserved parking lots and offered CRUD operations on the blacklist, including viewing, deleting, creating, or modifying blacklisted license plates. For surveillance purposes, strategically placed cameras captured license plates of vehicles entering and exiting and in parking areas. These details were logged into a database and could be queried later. The application included a search feature to locate specific vehicles recorded on campus and obtain information on their capture location. In incidents like missing vehicles, unauthorized parking in reserved spaces,

8

D. Thompson et al.

or entry of blacklisted license plates, the application provided relevant information, including the time and location of the occurrence.

4 Results The evaluation of the Campus Vision AI-Powered prototype was conducted using pre-recorded live footage provided by the university’s security department, as well as photographs of lecturers’ vehicles. The purpose was to determine the accuracy of each prototype feature. The results of monitoring this footage and the images, as if they were actual live feeds, using the prototype, were documented in tables and represented graphically (Table 1 and Figs. 2, 3, and 4). The overall aim of this study was to determine the effectiveness of the Campus Vision prototype in detecting and tracking vehicles entering and exiting the University of Technology–Jamaica Kingston main campus and detecting parking violations, as well as to determine the willingness to adopt AI-enabled surveillance systems like Campus Vision at the university.

Table 1 Table showing the recorded number of successful vehicles, license plate, and character detection and recognition Number of vehicles Successful vehicle detection Successful license plate detection Accurate license plate character recognition

Entrance 54 42 41 19

Exit 55 39 38 5

Overall Vehicle Detection

29 24%

91 76%

Successful Detection

Unsuccessful Detection

Fig. 2 Pie chart depicting the overall percentage of vehicles detected

Parking 11 10 10 6

An AI-Enabled Vehicle Surveillance System to-Tracking Entrance, Exit. . .

9

Overall Licence Plate Detection 2 2%

89 98% Successful Detection

Unsuccessful Detection

Fig. 3 Pie chart depicting the overall percentage of license plates detected

Overall Licence Plate Character Recognition Accuracy

30 34% 59 66%

Accurate Character Recognition

Inaccurate Character Recognition

Fig. 4 Pie chart depicting the overall license plate character recognition accuracy

In determining the effectiveness of the Campus Vision prototype at the university, footage recorded from the cameras already on the campus as well as pictures taken of parked vehicles was used in the experiment. From the results of the experiment, it can be seen that the prototype was able to properly detect 81 (74.3%) of the 109 vehicles entering and exiting the campus, 79 (97.5%) of detected vehicles license plates were also detected, and only 24 (30.4%) of those plates had their license plate number accurately identified and recorded. During the experiment, factors such as the cameras’ view being obstructed by environmental factors, vehicles being too large for the prototype to fully capture in its detection area, and certain vehicles

10

D. Thompson et al.

and license plates being undetectable due to modification or features on the vehicle or just not being present in the detection data set have been identified as causes of reduced detection rates. Images were used for the testing of the prototype in regard to parking lot violations instead of footage. This resulted in the prototype being able to detect a vehicle in 10 (90.9%) out of the 11 images, detect the license plate on all ten detected vehicles, and accurately identify 6 (60%) of the license plate number from the detected plates. Due to inaccuracy in the identification of license plate numbers, the prototype was determined not to be reliable in detecting parking lot violations. In answering the research question on the willingness of the university security manager in accepting the use of an AI-enabled surveillance system, an interview was conducted with the university’s head security manager. The results of that interview were highly positive toward the use of the technology on the university campus. The participants had provided various issues they believed an AI-enabled surveillance systems like Campus Vision could help address, benefits they believe it could provide and features that they would like to see implemented on a potential completed version of the Campus Vision prototype. Notably, the issues and benefits highlighted by the participant are not exclusive to just the University of Technology– Jamaica, giving the indications of the implementation of similar systems at other institutions and businesses, though due to only having a single participant in the interview; this may not reflect the opinions of other institutions seeing the benefits in adopting such technology. In conclusion, it was determined that Campus Vision has an overall high accuracy in detecting vehicles, 76%, and license plates, 98%, while having below-average accuracy in license plate character recognition, 34%, when tested on 120 vehicles entering, exiting, and parked on the university’s campus. This study had also highlighted that there is a positive willingness to accept AI-enabled surveillance systems as they can provide a significant improvement to an institution’s security. This study also adds more information to the literature on the implementation of AI-enabled surveillance in vehicle parking management especially in terms of the use of such technology in Jamaica as well as in real-life scenarios.

5 Conclusion In this chapter, we discussed the need for combating parking lot violations and ensuring effective vehicle management on campus, and the proposal for implementing Campus Vision, an AI-powered surveillance system, was put forth. The findings of the conducted research indicate a significant interest from the security department in adopting this system. The obtained experimental results strongly support the conclusion that the integration of Campus Vision would enable the system to achieve a remarkable accuracy rate of over 95% in terms of detecting and storing vehicles and license plates upon entry and exit from the campus. Moreover, it would successfully identify parking lot violations with an accuracy rate exceeding

An AI-Enabled Vehicle Surveillance System to-Tracking Entrance, Exit. . .

11

95%, conduct a blacklist check for every detected vehicle, and accurately read characters from license plates. To improve the AI system and enhance future studies, we provided a few recommendations: • To enhance the performance and capabilities of the AI system, several recommendations can be implemented. • Incorporating a dedicated GPU would greatly enhance the processing abilities of various AI models, resulting in more accurate results. • Isolating different computational tasks would make it easier to implement improvements and add extra features to the system. • Improving camera placement is crucial, taking into account factors such as the angle, location, and quality of the cameras. • Accounting for different types of vehicles, including those with custom license plates and those that do not fit into predefined criteria, such as bikes, trucks, and buses. • By implementing these recommendations, the AI system can achieve higher processing power, efficient task management, improved camera coverage, and better recognition of diverse vehicles. • Further studies with the usage of AI to automate tasks should be done on a wider scale, with more test data.

References 1. Kaur, P., Kumar, Y., Gupta, S.: Artificial intelligence techniques for the recognition of multiplate multi-vehicle tracking systems: a systematic review. Arch. Comput. Methods Eng. 29(7), 4897–4914 (2022) 2. Ni, F., Wei, J., Shen, J.: An Internet of Things (IoTs) based intelligent life monitoring system for vehicles. In: 2018 IEEE 3rd Advanced Information Technology, Electronic and Automation Control Conference (IAEAC) (pp. 532–535) (October 2018) 3. Kelly, D.: Personal Interview (14 November, 2022) 4. Chandra, H., Hadisaputra, K.R., Santoso, H., Anggadjaja, E.: Smart parking management system: An integration of RFID, ALPR, and WSN. In: 2017 IEEE 3rd International Conference on Engineering Technologies and Social Sciences (ICETSS) (pp. 1–6). IEEE (August 2017) 5. Buhus, E.R., Timis, D., Apatean, A.: Automatic parking access using openalpr on raspberry pi3. Acta Technica Napocensis. 57(3), 10 (2016) 6. Fast, E., & Horvitz, E.: Long-term trends in the public perception of artificial intelligence. In: Proceedings of the AAAI Conference on Artificial Intelligence (Vol. 31, No. 1) (2017) 7. Gao, S., He, L., Chen, Y., Li, D., Lai, K.: Public perception of artificial intelligence in medical care: content analysis of social media. J. Med. Internet Res. 22(7), e16649 (2020) 8. Cui, D., Wu, F.: The influence of media use on public perceptions of artificial intelligence in China: evidence from an online survey. Inf. Dev. 37(1), 45–57 (2021) 9. United Nations: Population. United Nations. Retrieved January 8, 2023, from https:// www.un.org/en/global-issues/population#:~:text=Our%20growing%20population&text= The%20world%27s%20population%20is%20expected,billion%20in%20the%20mid-2080s (2022)

12

D. Thompson et al.

10. Jamaica registered vehicles per 1,000 inhabitants, 1970–2022. Knoema. (n.d.). Retrieved January 19, 2023, from https://knoema.com/atlas/Jamaica/topics/Transportation/Road-transport/ Registered-vehicles-per-1000-inhabitants 11. Aalsalem, M.Y., Khan, W.Z.: CampusSense—A smart vehicle parking monitoring and management system using ANPR cameras and android phones. In: 2017 19th International Conference on Advanced Communication Technology (ICACT) (pp. 809–815). IEEE (2017) 12. Wang, Q., Li, H.: Design of Parking Space Management System Based on Internet of Things Technology. In: 2022 IEEE Asia-Pacific Conference on Image Processing, Electronics and Computers (IPEC) (pp. 1366–1370). IEEE (April 2022) 13. Rane, S., Dubey, A., Parida, T.: Design of IoT based intelligent parking system using image processing algorithms. In: 2017 International Conference on Computing Methodologies and Communication (ICCMC) (pp. 1049–1053). IEEE (2017) 14. Shimi, A., Ebrahimi Dishabi, M.R., Abdollahi Azgomi, M.: An intelligent parking management system using RFID technology based on user preferences. Soft. Comput. 26(24), 13869–13884 (2022) 15. Lin-Ying, J., Shuai, W., Heng, Z., Han-qing, T.: Improved design of vehicle management system based on RFID. In: 2010 International Conference on Intelligent System Design and Engineering Application (Vol. 1, pp. 844–847). IEEE (October 2010) 16. Jian, M.S., Yang, K.S., Lee, C.L.: Modular RFID parking management system based on existed gate system integration. WSEAS Trans. Syst. 7(6), 706–716 (2008) 17. Tsiropoulou, E.E., Baras, J.S., Papavassiliou, S., Sinha, S.: RFID-based smart parking management system. Cyber-Phys. Syst. 3(1–4), 22–41 (2017) 18. Omar, N., Sengur, A., Al-Ali, S.G.S.: Cascaded deep learning-based efficient approach for license plate detection and recognition. Expert Syst. Appl. 149, 113280 (2020) 19. Chang, S.L., Chen, L.S., Chung, Y.C., Chen, S.W.: Automatic license plate recognition. IEEE Trans. Intell. Transp. Syst. 5(1), 42–53 (2004) 20. Jain, V., Sasindran, Z., Rajagopal, A., Biswas, S., Bharadwaj, H.S., Ramakrishnan, K.R.: Deep automatic license plate recognition system. In: Proceedings of the Tenth Indian Conference on Computer Vision, Graphics and Image Processing, pp. 1–8 (December 2016) 21. Fysarakis, K., Hatzivasilis, G., Manifavas, C., Papaefstathiou, I.: RtVMF: a secure real-time vehicle management framework. IEEE Pervas. Comput. 15(1), 22–30 (2016) 22. Lee, H., Kim, D., Kim, D., Bang, S.Y.: Real-time automatic vehicle management system using vehicle tracking and car plate number identification. In: 2003 International Conference on Multimedia and Expo. ICME’03. Proceedings (Cat. No. 03TH8698) (Vol. 2, pp. II-353). IEEE (July 2003) 23. Curtis, M.B., Krueger, A.: Benefits and Drawbacks of RFID in a Post-Sarbanes Oxley World (2021) 24. Isard, M., Blake, A.: Condensation—conditional density propagation for visual tracking. Int. J. Comput. Vis. 29(1), 5–28 (1998) 25. Kaimkhani, N.A.K., Noman, M., Rahim, S., Liaqat, H.B.: UAV with vision to recognise vehicle number plates. Mob. Inf. Syst. (2022) 26. Ke, R., Zhuang, Y., Pu, Z., Wang, Y.: A smart, efficient, and reliable parking surveillance system with edge artificial intelligence on IoT devices. IEEE Trans. Intell. Transp. Syst. 22(8), 4962–4974 (2021) 27. Awati, R.: What are convolutional neural networks? Enterprise AI (2022, September 29). Retrieved February 3, 2023, from https://www.techtarget.com/searchenterpriseai/definition/ convolutional-neural-network 28. Ciampi, L., Gennaro, C., Carrara, F., Falchi, F., Vairo, C., Amato, G.: Multi-camera vehicle counting using edge-AI. Expert Syst. Appl. 207, 117929 (2022) 29. Hwang, K., Jung, I.H., Lee, J.: Advanced smart parking management system development using AI. J. Syst. Manage. Sci. 12, 53–62 (2022) 30. Karimi, G.: Introduction to yolo algorithm for object detection. Section (2021, April 15). Retrieved February 3, 2023, from https://www.section.io/engineeringeducation/introduction-to-yolo-algorithm-for-object-detection/#:~:text=YOLO%20 algorithm%20employs%20convolutional%20neural,in%20a%20single%20algorithm%20run

Differential Evolution-Based Weighted Voting Stacking Ensemble Classifier for Highly Skewed Binary Data Distribution Kgaugelo Moses Dolo and Ernest Mnkandla

1 Introduction and Background Credit card frauds have caused serious damage to both service providers and credit card users in South Africa, and it was predicted to get worse in future [3]. According to [1], there are less credit card fraudulent activities performed than non-fraudulent activities, and in the context of big data, this would result in a highly skewed distribution. Thus, more complex and efficient analytical tasks to handle highly skewed distributions are required. The no-free-lunch (NFL) theory suggests that no machine learning method can perform well for all measures in every application [2]. That said, a technique that combines various classifier models to perform data insights and to reveal fraudulent data patterns in order to prevent future fraudulent transactions was viewed as a solution that overcomes the issue of weak classifiers for credit card fraud detection problems. The stacking ensemble method is an important data mining technique that combines various classifier models such that a weak classifier model for a particular instance is assisted by strong classifier models through weighted voting of a class value [4–6]. Manual and random selection of weights for voting credit card transactions has previously been carried out. However, a large number of fraudulent transactions were not detected by the classifier models, which means that a technique to overcome the weaknesses of the classifier models is required. For the weighted stacking ensemble method, the weights for classifier models per transaction are required to be high for a class that performs well and low for a class that does not perform well. Reasoning from this fact, the selecting of the

K. M. Dolo () · E. Mnkandla University of South Africa, Pretoria, South Africa e-mail: [email protected]; [email protected] © The Author(s), under exclusive license to Springer Nature Switzerland AG 2024 I. Woungang, S. K. Dhurandher (eds.), The 6th International Conference on Wireless, Intelligent and Distributed Environment for Communication, Lecture Notes on Data Engineering and Communications Technologies 185, https://doi.org/10.1007/978-3-031-47126-1_2

13

14

K. M. Dolo and E. Mnkandla

appropriate weights of votes for each class per classifier is very important. On this basis, the problem of selecting the appropriate weights for voting the correct output class of each transaction is viewed as the problem of weights optimization in this research study. Differential evolution algorithm is a subset of evolution programming designed for continuous domain optimization problems [8–10]. Since it is normal for the base models of the stacking ensemble method to have weak classifiers, differential evolution is used in this study to learn the weak classifiers in each evolution stage and correct the weights [10]. Differential evolution has an advantage over genetic algorithms because it is fast, robust, easy to use, and simple in structure [8–10]. Genetic algorithms use selection mechanisms to produce a sequence of population, and thereafter use mutation and crossover as search mechanisms. Unlike Genetic algorithms, the only search mechanism of differential evolution is mutation, and the search is guided toward the prospective regions inside a feasible region through the use of selection [11]. The main difference between differential evolution and genetic algorithms is that whereas genetic algorithms are more dependent on a mechanism of probabilistic, a crossover, and an exchange of information in solutions to better locate solutions, differential evolution strategies are dependent more on mutation as a mechanism for the primary search. Differential evolution was therefore selected as the most appropriate optimization algorithm for this problem because of its advantages over the genetic algorithms, its ability to learn the weak classifiers in each evolution stage, and its ability to correct weights in each evolution stage. Differential evolution model is discussed in detail in Sect. 1.1. This chapter is organized as follows: In Sect. 1.1, the background of the differential evolution model is presented. In Sect. 2, some research questions are presented, along with the research objectives. In Sect. 3, the research design is presented. In Sect. 4, the performances of the data models are evaluated. Lastly, the conclusion is presented in Sect. 5.

1.1 Differential Evolution Algorithm This is an optimization technique of stochastic search for a population-based vector, and it is powerful and efficient over a continuous space for solving differentiable and nonlinear problems. This algorithm was introduced in 1996 by Storn and Price. The algorithm is an evolutionary method composed of five sequential stages, namely, population initialization, mutation, recombination, selection, and termination criteria. If the data observation does not meet the termination criteria, the data observation evolves to the next generation where the weight is readjusted. If the data observation meets the termination criteria, the data observation is an optimal solution. Consider the optimization problem f (x) where X = [x1 , x2 , x3 , . . . , xD ], and D is the number of variables. For the population size N and a generation G, the pop-

Differential Evolution-Based Weighted Voting Stacking Ensemble Classifier for. . .

15

G = x G , x G , x G , . . . , x G . The five sequential ulation matrix is defined as .xn,i n,D n,1 n,2 n,3 stages of the evolutionary method are discussed in the following subsections.

1.1.1

Initial Population

The random generation of the initial population between lower bound and upper bound is defined by the following equation:   L U L xn,i = xn,i + rand () ∗ xn,i − xn,i , i = 1, 2, 3, . . . , D and n = 1, 2, 3, . . . , N

.

(1) where .xiL is the lower bound of the variable xi , and .xiU is the upper bound of the variable xi .

1.1.2

Mutation

G , x G and x G are selected For each parameter vector, three other vectors .xr1n r2n r3n randomly, and the weighted difference of two of the vectors is added to the third

  G G G xnG+1 = xr1n + F xr2n − xr3n

.

(2)

where n = 1,2,3, . . . , N. .xnG+1 is called a donor vector and F is a user supplied value that is taken between 0 and 1.

1.1.3

Recombination

G+1 G+1 The trial vector .Un,i is derived from the donor vector .Vn,i and the target vector G .x in accordance with the following equation. n,i

 G+1 .U n,i

=

G+1 if rand ( ) ≤ Cp or i = Irand Un,i G xn,i if rand ( ) > Cp and i = Irand

(3)

i = 1, 2, 3, . . . , D and n = 1, 2, 3, . . . , N

.

where Irand is an integer random number between I and D and Cp is the recombination probability that is chosen randomly between the value of 0 and 1.

16

1.1.4

K. M. Dolo and E. Mnkandla

Selection

G+1 G , and the one The trial vector .Un,i in Eq. 4 is compared with the target vector .xn,i with the lowest function value is selected for next generation.

 G+1 .xn

=

    G+1 Un,i if f UnG+1 > f xnG xnG otherwise

(4)

n = 1, 2, 3, . . . , N

.

1.1.5

Termination

Equation 1 up until Eq. 4 will be repeated in while loop function until the target vector is reached; then the while loop function will terminate. Differential evolution is an optimization technique of stochastic search for a population-based vector that is used to learn the weak classifiers in each evolution stage and correct weights. When the differential evolution model terminates, the final set of the weights are the optimum weights of the classifiers and are used to determine the global optimum point of the search space. The global optimum point of the search space is associated with a vector that produces lesser error rate than vectors in local optimum points. Thus, voting classifiers that are weighted with optimum weights have a higher likelihood of classifying credit card transactions correctly in a binary class distribution. Given this claim, the study would therefore propose that weighted voting stacking ensemble method used in combination with the differential evolution stochastic optimization method would be an optimum solution for classifying fraudulent credit card transactions and for preventing future credit card fraudulent transactions. This proposed solution leads to the exploration of the research questions in Sect. 2.

2 Research Questions and Objectives 2.1 Research Questions This research study intends to explore the following main research question: Is the differential evolution optimization method a good approach for defining the weighting function to predict the outcome of future credit card fraudulent transactions?

Differential Evolution-Based Weighted Voting Stacking Ensemble Classifier for. . .

17

The sub-research question that supports the main research question of this study is as follows: Will the proposed data model for fraud detection efficiently detect credit card fraudulent activities? This study therefore sought to answer these questions by carrying out the objectives presented in the next section.

2.2 Research Objectives The main research objective is to obtain optimum data analytics algorithms that perform data insights to reveal fraudulent data patterns in order to prevent future fraudulent transactions. The sub-objective is as follows: To determine the efficiency of the proposed data model for fraud detection in the detection of activities relating to credit card fraud, this objective will be implemented by running both the differential evolution optimization and the stacking ensemble algorithm on the classifier models. The next section discusses the research design followed to achieve the research objectives of this study.

3 Research Design The weighted stacking ensemble base models’ performance optimized by a grid search method will be compared with the weighted stacking ensemble base models optimized by a grid search method and a differential evolution stochastic optimization on the voting weights. The optimization methods were used to search for the optimum weights that represent both fraudulent and non-fraudulent of the credit card classes so well. The proposed method for fraud detection in this study is the weighted voting stacking ensemble method used in combination with the differential evolution stochastic optimization method. Figure 1 shows the flow of the proposed method. The proposed data model was tested and evaluated with the credit card dataset that contained transactions effected in September 2013 by the European cardholders. The dataset was downloaded from the Kaggle competition data repository (Kaggle, 2018). This publicly available Kaggle repository data contained credit card dataset transactions made during September 2013 by European cardholders and consisted of a total of 284,807 transactions, of which 0.172% (492) were illegal. The credit card fraud dataset was collected, pre-processed, and normalized. To solve the issue of class imbalance, the modified Safe-Level-SMOTE defined in

18

K. M. Dolo and E. Mnkandla

Fig. 1 Credit card fraud model

[7, 17] was used to oversample the data observation of the minority class of the dataset. The oversampling was done together with the down-sampling method that removes duplicates and randomly chooses non-duplicate data samples from the majority class in order to control the best fit line to an optimum place that represents fraudulent transactions and non-fraudulent transactions equally [7, 17].

3.1 Stacking Ensemble Method To obtain the true accuracy of base models and thus achieve a classification problem of equal representation of class values, the hyper-parameters of the base models were optimized by a grid search method. The grid search method was used to search for the optimal parameters of the base models. Furthermore, a classification problem of equal representation of class values was optimized to maintain the higher overall accuracy of base models. Once all the base models were optimized, the class objects were used in combination with the class properties to re-run the accuracy code and print the true accuracies of the base models. The true accuracies of the base models were obtained.

Differential Evolution-Based Weighted Voting Stacking Ensemble Classifier for. . .

19

3.2 Differential Evolution Optimization Method The weight voting of the stacking ensemble method is optimized using the differential evolution technique. Differential evolution is a stochastic technique that is powerful and efficient over a continuous space for solving differentiable and nonlinear optimization problems. The differential evolution algorithm defined in this subsection is a population-based vector that is used to learn the weak classifiers and correct weights in each evolution stage until it reaches the target vector of the credit card binary class distribution. The final set of the weights is the optimum set of weights of the classifiers and is used to determine the global optimum point of the search space that produces lesser error rate. The differential evolution algorithm is defined as follows:

Algorithm 1: Differential Evolution Optimization Method Input: TrainDataX, population_size, Scaling_Factor, Max_Iterator, Crossover_Probability, random_seed Output: Predicted Output Begin 1. Function to define the bounding of the search space (Bounds) Input: TrainDataX Bounds = [] min = minimum values of all input features max = maximum values of all input features Append min and max into Bounds Return Bounds 2. Function to ensure the bounds of the search space Input: vector, bound New_vector = [] For ind = 0 to length of vector If lower bound[ind] >= vector[ind] Append lower bound[ind] into New_vector If upper bound[ind] = 0.838 Append 1 into List Else Append 0 into List Return List 12. Function to get model Accuracy Input: TestDataY, predictions Correct = 0 For y = 0 to length of TestDataY If TestDataY[y] = predictions[y] Correct += 1 Return (Correct / length of TestDataY) * 100 End of the Class

The differential evolution method searches the search space that is defined by the lower- and the upper-bound values of each feature of the dataset and thereafter generates new members of the population. A For-loop was created to loop through the algorithm and find the best performing number of population members. Another loop was created for learning the search space. The mutation method used was (X1 + Scaling factor * (X2 – X3)), where X1, X2, and X3 are the population members, and scaling factor is a random number between 0 and 2. The crossover method was performed on a mutation vector and the given population vector, and the cost was calculated. A vector that achieves minimum cost was chosen as an optimum solution for the problem. An optimum solution vector is a set of weights. A set of weights was

22

K. M. Dolo and E. Mnkandla

multiplied with predicted class probabilities, and a logistic function was used. The results of all algorithms defined in this chapter are analyzed in detail in the next section.

4 Performance Evaluation The confusion matrix method was used to evaluate and compare the performance of differential evolution method and stacking ensemble method. The confusion matrix is a classification model evaluation method that shows the total number of true negatives, true positives, false negatives, and false positives. The number of truepositive (TP) transactions is the number of output transactions that the base classifier has predicted as being fraudulent when they were in fact fraudulent. Similarly, the count of true-negative (TN) transactions is the count of output transactions that the base classifier has predicted as being non-fraudulent when they were in fact non-fraudulent, the count of false-positive (FP) transactions is the count of output transactions that the base classifier has predicted as being fraudulent when they are non-fraudulent, and the count of false-negative (FN) transactions is the count of output transactions that the base classifier has predicted as being non-fraudulent when they are in fact fraudulent. Figure 2 shows the true-negative and true-positive transactions of the stacking ensemble method and the classification problem of the differential evolution optimization of stacking ensemble method.

Fig. 2 True positives/true negatives of stacking ensemble vs differential evolution methods

Differential Evolution-Based Weighted Voting Stacking Ensemble Classifier for. . .

23

Fig. 3 False positives/false negatives of stacking ensemble vs differential evolution methods

It is clear from Fig. 2 that the number of true-positive transactions (fraudulent transactions) generated from the stacking ensemble method is exceeded (0.7% vs 85.4%) by that of the true positives generated using the differential evolution optimization of stacking ensemble method. Put differently, the number of fraudulent transactions detected by the differential evolution optimization of stacking ensemble classifier is substantially higher than those of stacking ensemble model on its own. The number of true-negative transactions (non-fraudulent transactions) of the stacking ensemble method is lower than that of the true negatives of the differential evolution optimization of stacking ensemble method. This suggests that the number of non-fraudulent transaction detected using the differential evolution optimization of stacking ensemble classifier is greater than those detected by the stacking ensemble method. A comparative analysis of the misclassified transactions using the differential evolution optimization of stacking ensemble classifier and the stacking ensemble classifier is displayed in Fig. 3. According to Fig. 3, the number of false-positive transactions (misclassified fraudulent transactions) generated using the stacking ensemble method is slightly higher than the false positives associated with the differential evolution optimization of stacking ensemble method. Relative to the false-positive transactions, the percentage of negative transactions (misclassified non-fraudulent transactions) is significantly low and therefore not visible. Figure 4 shows the number of false-negative transactions (misclassified nonfraudulent transactions) for the two methods. The number of false-negative trans-

24

K. M. Dolo and E. Mnkandla

Fig. 4 False negatives of stacking ensemble vs differential evolution methods

actions generated through the stacking ensemble method is greater than that of the differential evolution optimization of stacking ensemble method. In this section, the presentation of the analysis and interpretation of the results of the research study were put forward. It was found that the differential evolution optimization of stacking ensemble classifier outperforms the stacking ensemble classifier in terms of classification and misclassification of credit card fraudulent transactions. The Main Research Question was: Is the differential evolution optimization method a good approach for defining the weighting function to predict the outcome of future credit card fraudulent transactions?

As indicated in the previous section, the differential evolution stochastic optimization method shows that the weighted voting stacking ensemble method, when used in combination with a differential evolution stochastic optimization method performed better than the base models. When used in combination with the differential evolution stochastic optimization method, the weighted voting stacking ensemble method was able to achieve higher accuracy for confusion matrix true-negative (TN) and true-positive (TP) transactions. The confusion matrix false-negative (FN) and false-positive (FP) transactions of the credit card fraud data were, on the other hand, extremely low. This means that when used in combination with the differential evolution stochastic optimization method, the weighted voting stacking ensemble method performed very well without any biasness of the class distribution. Thus, the differential evolution optimization method is a good approach for defining the weighting function to predict the outcome of future fraudulent credit card transactions.

Differential Evolution-Based Weighted Voting Stacking Ensemble Classifier for. . .

25

With regard to the sub-research question: Will the proposed data model for fraud detection efficiently detect credit card fraudulent activities?

The study developed the weighted voting stacking ensemble method and used it for the credit card dataset. Finding the relevant weights for the base models proved to be a challenging task. Therefore, the differential evolution method was employed on weighted voting stacking ensemble method to search the optimum weights. The application of differential evolution method was able to find the optimum weights for the weighted voting stacking ensemble method. Hence, when used in combination with differential evolution stochastic optimization method, the weighted voting stacking ensemble method performed far much better than the base models (machine learning methods) and the weighted voting stacking ensemble method. The true-negative (TN) and the true-positive (TP) transactions of the confusion matrix were high, while the false-negative (FN) and the false-positive (FP) transactions were low. This means that the weighted voting stacking ensemble method with differential evolution method was able to generalize the data distribution by correctly classifying fraudulent and non-fraudulent transactions, and the model is not biased. It can therefore be concluded that the weighted voting stacking ensemble method in combination with differential evolution stochastic optimization method was able to classify illegal and legal transactions correctly and efficiently. Some researchers have managed to create machine learning methods for addressing the detection of credit card fraud [13–16]. However, their approaches involve the individual use of the machine learning methods and a comparison of the output accuracies. It is argued in this research study that one machine learning method cannot, regardless of its computational power, be used in all the cases. This argument is supported by the No-Free-Lunch (NFL) theorem, which states that there is no machine learning method that can achieve the best performance for all measures in every given application [2]. The approach adopted in this research study for combating credit card fraud was different. Various machine learning algorithms that perform differently were chosen. Various machine learning methods were chosen with the aim of covering the search space of the problem. However, the method to guide the researchers in terms of the machine learning methods being various enough to cover the search space of the problem is unknown and was not designed in this study.

5 Conclusion In conclusion, it can be said that the proposed weighted stacking ensemble method with differential evolution stochastic optimization model is suitable for the issue of analyzing illegal activities associated with credit card fraud. The proposed model, which was evaluated using the confusion matrix, was found to perform

26

K. M. Dolo and E. Mnkandla

better than the weighted stacking ensemble base models in terms of accuracy. Furthermore, the model was found to cover almost the entire search space of the credit card transactions. However, it is noteworthy that the proposed model has its own limitations. Specifically, the framework for guiding the study in terms of the selection for stacking ensemble method of the base models covering the entire search space of the credit card data observations was not addressed. It is recommended that future works should include the implementation of the framework to guide the financial institutions in terms of selection for stacking ensemble method of the base models that covers the entire search space of the credit card data observations. The framework should be flexible enough to cater for all types of credit card datasets. Acknowledgments I would like thank Prof Ernest Mnkandla for providing insight, expertise, and comments that greatly assisted the research. I would also like to thank my family, Joyce Dolo, Mahlatse Dolo, Kamogelo Dolo, Tshegofatso Atlegang Kgoele, etc., for their support.

References 1. Altayar, M., Almoqren, N.: The Motivations for Big Data Mining Technologies Adoption in Saudi Banks, pp. 1–8. 4th Saudi International Conference on Information Technology (Big Data Analysis) (KACSTIT) (2016) 2. Macready, W., Wolpert, D.: No free lunch theorems for optimization. IEEE Trans. Evol. Comput. 1, 67–82 (1996) 3. Pushpa, M., Malini, N.: Analysis on Credit Card Fraud Identification Techniques based on KNN and Outlier Detection, pp. 255–258. 3rd International Conference on Advances in Electrical, Electronics, Information, Communication and Bio-Informatics (AEEEICB17) (2017) 4. Zirpe, S., Joglekar, B.: Negation Handling using Stacking Ensemble Method, pp. 1–5. 2017 International Conference on Computing, Communication, Control and Automation (ICCUBEA) (2017) 5. Verma, A., Mehta, S.: A comparative study of ensemble learning methods for classification in bioinformatics, pp. 155–158. 2017 7th International Conference on Cloud Computing, Data Science & Engineering – Confluence (2017) 6. Cheng, C., Xu, W., Wang, J.: A comparison of ensemble methods in financial market prediction, pp. 755–759. 2012 Fifth International Joint Conference on Computational Sciences and Optimization (2012) 7. Dolo, K.M., Mnkandla, E.: Weighted Voting Stacking Ensemble Method for Highly Skewed Binary Data Distribution, pp. 107–120. 5th International Conference on Wireless, Intelligent, and Distributed Environment for Communication (WIDECOM 2022) (2022) 8. Brest, J., et al.: Self-Adapting Control Parameters in Differential Evolution: A Comparative Study on Numerical Benchmark Problems, pp. 646–657. IEEE Transactions on Evolutionary Computation (2006) 9. Srinivas, V.S., Srikrishna, A., Reddy, B.E.: Automatic Feature Subset Selection for Clustering Images using Differential Evolution, pp. 216–217. 2018 IEEE Conference on Multimedia Information Processing and Retrieval (MIPR) (2018) 10. Madathil, D., Pandi, V.R., Ilango, K., Nair, M.G.: Differential Evolution Based Energy Management System for Zero Net Energy Building, pp. 1–5. 2017 International Conference on Technological Advancements in Power and Energy (TAP Energy) (2017)

Differential Evolution-Based Weighted Voting Stacking Ensemble Classifier for. . .

27

11. Kalajac, E., Karabegovi´c, A., Ponjavi´c, M.: Optimization of the Structures Locations Using a Genetic Algorithm in the Transmission Line Design, pp. 883–886. 2018 41st International Convention on Information and Communication Technology, Electronics and Microelectronics (MIPRO) (2018) 12. Macready, W., Wolpert, D.: No free lunch theorems for optimization. IEEE transactions on evolutionary computation, pp., 67–82 (1996) 13. Malini, N., Pushpa, M.: Analysis on Credit Card Fraud Identification Techniques based on KNN and Outlier Detection, pp. 1–4. 3rd International Conference on Advances in Electrical, Electronics, Information, Communication and Bio-Informatics (2017) 14. Ganji, V.: Credit card fraud detection using anti-k nearest neighbor algorithm. Int. J. Comput. Sci. Eng. 4, 1–5 (2012) 15. Das, T., Tripathy, A., Mishra, A.: Optical Character Recognition using Artificial Neural Network, pp. 1–4. International Conference on Computer Communication and Informatic (2017) 16. Manjaramkar, A., Kokare, M.: Decision Trees for Microaneurysms Detection In Color Fundus Images, pp. 1–4. IEEE International Conference on Innovations in Green Energy and Healthcare Technologies (2017) 17. Kgaugelo Moses Dolo, E.M.: Modifying the SMOTE and Safe-Level SMOTE Oversampling Method to Improve Performance, pp. 47–59. 4th International Conference on Wireless, Intelligent and Distributed Environment for Communication (2022)

Toward a Lightweight Cryptographic Key Management System in IoT Sensor Networks Ado Adamou Abba Ari, Mounirah Djam-Doudou, Arouna Ndam Njoya, Hortense Boudjou Tchapgnouo, Nabila Labraoui, Ousmane Thiare, Wahabou Abdou, and Abdelhak Mourad Gueroui

1 Introduction The emergence of wireless networks has led to the development of a new generation of networks including wireless sensor networks (WSNs). These networks use a large number of devices called nodes. These nodes are designed to be autonomous and able to communicate with each other to perform various tasks. They are small in size and therefore have very limited resources (computing power, memory, etc.) [1, 2]. Very used in many sensitive areas such as industrial complexes, surveillance of the territory, or health, the devices constrained in resources can be subject to disruptive and malicious actions that could compromise their operation [3]. This is A. A. A. Ari () DAVID Lab, Université Paris-Saclay, University of Versailles Saint-Quentin-en-Yvelines, Versailles, France CREATIVE, Institute of Fine Arts and Innovation, University of Garoua, Garoua, Cameroon LaRI Lab, University of Maroua, Maroua, Cameroon e-mail: [email protected]; [email protected] M. Djam-Doudou · H. B. Tchapgnouo LaRI Lab, University of Maroua, Maroua, Cameroon e-mail: [email protected]; [email protected] A. N. Njoya Department of Computer Engineering, University Institute of Technology, University of Ngaoundéré, Ngaoundéré, Cameroon N. Labraoui LRI Lab, Abou Bekr Belkaid University of Tlemcen, Chetouane, Tlemcen, Algeria e-mail: [email protected]

© The Author(s), under exclusive license to Springer Nature Switzerland AG 2024 I. Woungang, S. K. Dhurandher (eds.), The 6th International Conference on Wireless, Intelligent and Distributed Environment for Communication, Lecture Notes on Data Engineering and Communications Technologies 185, https://doi.org/10.1007/978-3-031-47126-1_3

29

30

A. A. A. Ari et al.

why it is essential to be able to ensure an acceptable level of safety. However, given the restrictive characteristics of sensors, security in WSNs becomes a real challenge [4]. Data collection and transmission operations must be performed with minimal malicious interference and an appropriate level of security. In order to meet the security objectives (integrity, confidentiality, authentication, availability), multiple approaches are used, including cryptographic techniques [5]. In the case of WSNs, these techniques need to be small to accommodate the limited resources of the WSN and potentially allow attack detection. For many solutions, communicating nodes share cryptographic keys for encryption and authentication. Equally important is having a key management system to build a secure infrastructure [6]. Key management is the process by which keys are created, assigned, stored, protected, verified, revoked, renewed, and destroyed [7, 8]. In WSNs, a commonly used technique is described by the process of pre-key distribution, which requires loading secret information into sensor nodes prior to their deployment in the network. Whether symmetric, asymmetric, or hybrid, the secret information, deployed in the network, can be a secret key, or auxiliary information that helps the sensor nodes derive the true secret key [9]. Our goal is to provide a lightweight key management protocol that aims at extending the lifetime of the network by minimizing the use of operations and cryptographic resources. In this chapter, we draw inspiration from the functioning of the A-star algorithm initially introduced in [3]. We propose a method for pre-distributing keys with periodic renewal as well as on-demand renewal. We use a cost function that minimizes the cryptographic resource usage of the nodes to construct the optimal path to send information from a node to the base station. The cryptographic cost refers to the amount of cryptographic resources potentially consumed by the node. In our case, it is the energy induced by the cryptographic operations and the memory occupied by the keys on the node. The rest of the chapter is organized as follows: Sect. 2 presents a brief review of some key management protocols for WSNs; A-star is presented in Sect. 3; the network model is presented in Sect. 4; the proposed protocol is described in Sect. 5; this is followed by simulation and discussion in Sect. 6; and we conclude our paper in Sect. 7.

O. Thiare LRI Lab, Gaston Berger University of Saint-Louis, Saint-Louis, Senegal e-mail: [email protected] W. Abdou LIB EA7534, University Bourgogne Franche-Comté, Dijon, France e-mail: [email protected] A. M. Gueroui DAVID Lab, Université Paris-Saclay, University of Versailles Saint-Quentin-en-Yvelines, Versailles, France e-mail: [email protected]

Toward a Lightweight Cryptographic Key Management System in IoT Sensor Networks

31

2 Related Works In [10], four types of keys are used (group key, pairwise key, public key, and private key). Nodes that each have a private key and a public key are organized into a group. The group key is obtained by multiplying all the private keys of the group members. The resulting key is sent to the cluster head, which calculates the group key by multiplying the received key by its own private key. The resulting key is then sent to all nodes in the network. In addition to the space occupied by the many keys, this method requires a lot of exchanges between nodes to establish the keys, which consumes a lot of energy due to radio communications [11, 12]. In the solution proposed in [13], after deployment, each node stores, in addition to its own key, the set of intermediate keys with all other nodes up to the leader of its group with whom it shares a key. The nodes then delete unnecessary keys from their memory. In the end, each subset of nodes has a unique key to communicate with the nodes in its group. The network is therefore static, and if a single node is compromised, an adversary can listen to all messages between all nodes in the group. There is no method for renewing keys. Here [14], initially, each node is pre-loaded with a list of keys and a list of subsets of these keys. In order to communicate, neighboring nodes use a new secret key each time, which they obtain by concatenating two of their keys, each taken from its own subset of keys. Then the nodes delete the unused keys. This approach uses a large amount of memory space to store the key subsets, as well as a lot of computation. In addition, when a new node arrives, neighboring nodes in the chain cannot establish keys with it because they have already erased the rest of the keys. In [15], the authors used combinatorial design theory to propose a pairwise key pre-distribution scheme for WSNs prior to sensor network deployment. The scheme is deterministic and generates fixed-size key chains where each pair of key chains has exactly one key in common, and each key appears in a common key chain. However, not all network sizes can be supported for such a scheme with a fixed key chain size. LEAP [5] supports at least four types of keys for each node: an individual key that it shares with the base station, a pairwise key with each of its neighbors, a global key used by the base station to encrypt messages, and a group key shared by a node with all of its neighbors, which is primarily used to secure broadcast messages and send them to group members. In addition to its minimum of four keys, the number of keys shared with each of the group’s neighbors increases with the number of neighbors, which is not without consequence on the memory given the number of keys to be stored. The protocol is also power hungry since exchanging a large number of messages to establish all the cryptographic keys drains the sensors’ battery. There are many other protocols in the literature, and although these aim to increase network lifetime, very few take cryptographic resources as the first criterion for optimization. We adopt an optimization strategy that puts the cryptographic cost so precious for resource-constrained devices at the center of our optimization policy.

32

A. A. A. Ari et al.

3 A-Star Algorithm 3.1 Preliminaries A-star algorithm initially proposed in [3] is an algorithm used to find shortest path in a graph between two nodes. It applies heuristic on each node to estimate the best path to follow in the graph. A-star consumes less memory and does not require pre-processing. The general expression of the objective function of A-star is as follows: f (n) = g(n) + h(n),

.

(1)

where: ● .g(n) = cost from the source node to the destination node n ● .h(n) = estimation cost of the cheapest path from n to the goal node Definition 1 A search algorithm that guarantees to always find the shortest path to a goal is called an admissible algorithm. Definition 2 Heuristic is admissible if it is too optimistic, i.e., the estimated cost is lower than it actually is. Axiom 1 If A-star uses a heuristic that never overestimates the distance (or more generally the cost) to the goal, A-star can be shown to be admissible. Axiom 2 Heuristic algorithm that allows A-star to be admissible is itself called an admissible heuristic. Axiom 3 If A-star uses a heuristic that never overestimates the distance (or more generally the cost) to the goal, A-star can be shown to be admissible. Axiom 4 A-star generates an optimal solution if .h(n) is an admissible heuristic and the search space is a tree. Axiom 5 .h(n) is admissible if it never overestimates the cost to reach the destination node. Axiom 6 A-star generates an optimal solution if .h(n) is a consistent heuristic and the search space is a graph. Axiom 7 If .h(n) is consistent, then .h(n) is admissible. Axiom 8 Frequently when .h(n) is admissible, it is also consistent.

3.2 Description ● The algorithm starts at a chosen node nstart . It applies a cost g(nstart ) to that node (usually zero for the initial node). A-star then estimates the distance h(nstart )

Toward a Lightweight Cryptographic Key Management System in IoT Sensor Networks











33

from that node to the goal ngoal . The sum of the cost f (nstart ) = g(nstart ) + h(nstart ) is assigned to the current path. The node is then added to a priority queue, commonly called an open list Olist . The algorithm removes the first node from the priority queue (the node with the lowest heuristic is removed first). The process is interrupted if the queue is empty that is to say there is no path from the initial node to the destination node. In case where the selected node is an arrival node, A-star reconstructs the complete path and stops. For reconstruction purpose, we use part of the information saved in the list commonly called closed list Clist . When the node is not an arrival node, new nodes are created for all eligible contiguous nodes. For each successive node, A-star computes the cost and stores it with the node. This cost is calculated from the sum of the cost of its ancestor and the cost of the operation to reach this new node. The algorithm also maintains a list of nodes that have been checked, commonly referred to as the Clist . If a newly produced node is already in Clist with an equal or lower cost, no operation is performed on that node or its counterpart in the list. Afterward, the distance evaluation of the new node from the arrival node is added to the cost to form the node’s heuristic. This node is then added to the priority waiting list. Once the above steps have been completed for each new contiguous node, the original node from the priority queue is added to the list of verified nodes. The next node is then removed from the priority queue and the process begins again (see Algorithm 1).

4 Network Model 4.1 Assumption We assume that the network is a set of .n ∈ N static homogeneous nodes .S = {s1 , s2 , ..., sn } randomly deployed in a given area of interest. We also assume that a stationary base station is located at a position known by each node. The communication channels are bidirectional, i.e., a sensor node u can receive a message from sensor node v and u can send a message to node v. A sensor node can delete a key, and each sensor node has a unique identifier .i ∈ [1; N] ∩ N. Definition 3 (Node Cost) By node cost (. ˆ ), we mean the cryptographic resources used by a node. In our case, this is the value of energy induced by the cryptography computation and the memory space occupied by the keys. Computing power is neglected because all nodes are assumed to be identical for that metric. We assume that the memory space occupied by the keys is given by Eq. 2 ψ = αK,

.

(2)

34

A. A. A. Ari et al.

Algorithm 1 : A-star Require: nstart : start node Require: ngoal : end node Require: Olist : list of nodes to be processed (priority queue) Require: Clist : list of processed nodes Require: N : number of nodes Require: h(i) : estimated distance from node i to the arrival node; i ∈ {1, 2, ..., N} Require: g(i) : actual distance from node i to the start node ; i ∈ {1, 2, ..., N} Require: f (i) : sum of distances h(i) and g(i) Require: parent () : parent of a node i (parent (x) gives the position in parent () of the node preceding x) 1: Initialize Olist to empty; 2: Initialize Clist to empty; 3: Add nstart to Olist ; 4: while (Olist not empty) do 5: Remove node n from Olist such that f (n) is the smallest; 6: if (n == ngoal ) then 7: return the solution; 8: else 9: Add n to Clist ; 10: end if 11: for Each (n' successor of node n) do 12: h = cost estimate of n' at ngoal ; 13: g(n') = g(n) + the cost to go from n to n'; 14: g t mp = g(n'); 15: f (n') = g(n') + h; 16: f t mp = f (n'); 17: if (n' ∈ Olist with a better f (n') then 18: go to the next n' ; 19: end if 20: if (n' ∈ Clist with a better f (n') then 21: go to the next n' ; 22: end if 23: Put n in parent (n'); 24: Put g t mp in g(n'); 25: Put f t mp in f (n'); 26: Remove n' from both Olist and Clist ; 27: Add n' to Olist ; 28: end for 29: end while

where: ● .α ∈ N the number of keys stored by the node ● K, the key size in bytes

Toward a Lightweight Cryptographic Key Management System in IoT Sensor Networks

35

4.2 Energy Model As for energy induced in cryptographic computation, [16] define simple power analysis (SPA) as a technique that consists of directly interpreting the measurements of energy consumption collected during cryptographic operations. They show that the amount of energy of each step of the operation is measurable [16]. In addition, an operation is a function that depends on messages and keys size. Our model does not measure the amount of energy itself. Rather, we are interested in the quantity of resources required to produce energy. We assume that the energy consumed by a cryptographic operation (encryption, decryption) is ΔEs = ϕKM + ϵ,

.

(3)

where: ϕ ∈]0, 1] is a weight parameter that allows us to act on the scale K, the key size in bytes M, the message size in bytes .ϵ the measurement error (noise)  By setting .M = mi , i ∈ R where: .mi is the .i t h part of message M, we have ● ● ● ●

.

ΔEs = ϕKmρ + ϵ

.

(4)

Whith .ρ ∈ R. For a message, the end node collects the information and performs a single operation (encryption) before transmission operation. In other positions, the node performs two operations: received message decryption and sending message encryption. Assuming that the impact of error .ϵ is negligible, the energy cost of a node is therefore 2ΔEs = 2ϕKmρ .

.

(5)

So, for a node that stores .α keys, the total energy cost is 2α(ΔEs ).

.

(6)

According to Eqs. 5 and 6, the total node cost of a node i is written as follows:  ˆ i = 2αΔEsi + ψ = αK(2ϕmρ + 1)i .

.

(7)

The objective function must therefore minimize the node cost in addition to taking into account the receive signal strength .RSSi . Finally, for a node .Si , we formulate the objective function as follows:

36

A. A. A. Ari et al. obj

fi

.

= min(αK(2wmρ + 1)i ∩ RSSi ),

(8)

where: RSSi is the signal strength of node i w ∈]0, 1] is a weight parameter that allows us to act on the scale K, the key size in bytes m, the message size in bytes .ρ ∈ R .α the number of keys stored on the node

● ● ● ● ● ●

. .

More generally, for a node i that receives a set of .Sj = {s1 , s2 , ..., sj } ,.j, n ∈ N and .j ⩽ n, we have Eq. 9. The function selects node candidate that minimizes the node cost when having best signal strength. .

f : Ω = { ˆ 1,  ˆ 2 , ... ˆ j ⩽n } × Γ = {RSS1 , RSS2 , ...RSSj ⩽n } → R+ × R+ obj fi (x, y) → ((MI N ( ˆ i ), MAX(RSSi )))

(9)

5 Protocol Design In the rest of the chapter, we will use the notations described in Table 1. Table 1 Notations Notation .Si .{M}k .BS→∗ .Si →∗

:M

:M

.Si →Sj

:M : {− > Sd , M} .MACk(M) .A||B .H k(M) .K{Si ,Sj } .Olist .Si →Sj

.Olist .predecessor .Olist .rssi

NodeHop

Description ith sensor node in the network Message M encryption with key k The BS broadcasts the message M, which is received by any sensor in its range and then relayed by the other nodes the ith broadcasts the message M, which is received by any sensor in its range The ith sensor node sends the message M, to node j The node .Si sends the message M, to node .Sj through the note .Sd The message authentication message code M with symmetric key k The concatenation of information A with information formation B A one-way hash function applied to the character string M using key k Sharing key between sensor nodes .Si and .Sj List used by each sensor node to store information received from other nodes Contains the reference of the sensor node at the head of the list Contains the signal strength value of the sensor node at the top of the list Sensor node hop

Toward a Lightweight Cryptographic Key Management System in IoT Sensor Networks

37

5.1 Discovery Phase Security requirements assume that all exchanges need confidentiality. We use 3 types of keys: ● A global key: This is a key shared by all nodes in the network. It is used to encrypt (decrypt) messages just after deployment (booting). Therefore, it allows to recognize nodes in the network. ● An individual key: Shared by each node with the base station, an individual key is used to secure communication between a node and the base station. ● A key per pair: This is a key shared between two nodes. It is used for encryption of direct communications between them. Before deployment stage, for each sensor node .Si in the network, we assign a unique identifier and an individual key shared with the base station .K{BS,Si } to secure communications between the sensor nodes and the base station. A global key .Kg is shared by all the sensor nodes of the network. The base station initiates the discovery phase. Since each node covers an area within its coverage range, we consider a hop as a coverage range. After random deployment of the sensor nodes, the base station runs the proposed algorithm based on A-star to build a communication tree. For each hop, times .ts , .tc , and .tf are assigned to select a previous node, to establish the link with the selected node, and to send its information (identifier, hop, and list) to the base station, respectively. We then have Eq. 10 and 11. ts + tc + tf ≤ td

.

MAX(N odeH op)  .

td ≤ tmin ,

(10)

(11)

i=1

where .td is the discovery time for each hop and .tmin the network discovery time during which an attacker can compromise a node and copy the contents of memory. Thus, each sensor node keeps the shortest path to send its information to the BS. When receiving a connection message during the discovery phase, each node compares its own hop with that of the sender node. If the level of signal is the same (it is a neighbor), the message is ignored. Otherwise, it records the node in its list sorted in descending order according to the signal strength of each received message. The pairwise key is created and exchanged with the node that has the best signal. It is in fact the node at the top index of the list. Once the discovery phase is complete for each node (i.e., at .td ), the exact path to forward the collected values to the base station is known. At the end of the network discovery (i.e., at .tmin ), nodes delete the global key from their memory.

38

A. A. A. Ari et al.

The purpose of the message given in Eq.12 is to discover the sensor nodes in the network. The MAC of the source identifier of the message is computed and then encrypted by the key .Kg . When the message is first received by a sensor node, the receiver node stores the sender identifier in .Olist .predecessor. Then, the receiver node records the signal strength in .Olist .rssi and increments its counter NodeHop. The computation of the key shared with the predecessor is given by the Eq. 13. On the other hand, discovered sensor node sends the message using Eq. 14 to discover the other sensor nodes. At the end, the key (see Eq. 15) shared with the predecessor is performed. In fact, .Sj is the preserved predecessor of .Si and is thus the sensor node at the top of .Si ’s list during time .tc .   BS → ∗ : BS, H ELLO, 0, MACKg (SB, N odeH op) Kg

.

  K{Si ,Sj } = H Kg Si ||Sj ||NodeH opi

.

  Si → ∗ : Si , H ELLO, NodeH op, MACKg (Si , NodeH op) Kg

.

(12) (13) (14)

  K{Si ,Sj } = H Kg Si ||Sj ||NodeH opi ||NodeH opj

(15)

  Si → Si+1 : H ELLO, Si , MACK{BS,Si },Si K{BS,Si }

(16)

 Si → BS : Sj , AU T H )K{Bs ,Si }

(17)

 BS → Sv : Su , AU T H _OK}K{BS,Sv }

(18)

 BS → ∗ : BANI SH, Su }K{BS,Si } , i ∈ [1; N]/u.

(19)

.

.

.

.

.

An instance of the described scenario is shown in Fig. 1.

5.2 Operational Phase and Security Analysis At the end of the previous phase, each sensor node shares a symmetric key with the BS, its predecessor, and its next neighbor (for those in the middle of the chain). The .Kg key for entire network is also shared. During the exploitation phase, it is important for security issues, to renew the keys. Renewal, which can occur on demand or periodically, is a good indicator of security. However, because nodes are deployed randomly, connections charge may remain on a single node or a small group of nodes due to their resources limitation (memory, cryptographic operations). This situation leads to the rapid network depletion or causes major disruptions (DDos). Therefore, workloads distribution is required among the different actors in the network. In the proposed protocol, during renewal, the node selects the candidate from its list that satisfies the objective function Eq. 9 based on the node’s cost and

Toward a Lightweight Cryptographic Key Management System in IoT Sensor Networks

39

Fig. 1 Instance of the described scenario. (a) Sensor nodes are randomly deployed in the target area. (b) The base station starts the algorithm by broadcasting the message given in Eq. 12. The discovery operation continues with the nodes sending their signal according to Eq. 14. Diffusion is done hop after hop. (c) At the end of discovery time, the paths are formed. Each node knows the shortest path to convey its information to the base station

the RSSI value. When a node u detects that the node through which it is supposed to send its information is compromised, it blocks it and sends a new connection message .(H ELLO) to the node v in its list that best satisfies the objective function. The v node that receives the new connection request authenticates the initiator to the base station by sending an .(AU T H ) message (Eq. 17). If the node is authenticated, an individual key Ku is encrypted with the individual key Kv of the one that requested authentication from the base station and sent back to v (Eq. 18). Nodes u and v can then securely compute their pairwise keys. At the end of this operation, node v deletes the individual key Ku from its memory. If the node u is not known to the base station, the broadcast is performed for this purpose (Eq. 19). As the communication channels are bidirectional, any connection request that includes the identifier of the initiating node otherwise is ignored by the target node. In the case of a cloning attack, where an attacker loads his own nodes and then attempts to establish pairwise keys for the nodes in the network in order to compromise the operation of the network, our protocol is robust because the pairwise key establishment process requires node identifiers and authentication by the base station. In addition, the Kg global key used in the discovery phase is completely deleted from the sensor’s memory after the discovery phase, which increases the level of difficulty for an adversary that has physically captured a sensor node. However, the protocol does not guarantee the confidentiality of the time interval during which a node is compromised in .tmin . The protocol is therefore vulnerable during this critical phase. Flooding attacks (untimely connection requests) can affect the protocol if the attacker has a large number of devices, as each attempt results in the device concerned being blocked. In the case of an internal attack, one or more sensor nodes are compromised and attempt to usurp, modify, or replay information. The protocol reacts well because communications between two nodes are encrypted

40

A. A. A. Ari et al.

from end to end. The authentication of exchanges is therefore encapsulated by the encryption key that the attacker must possess to send the messages. Algorithm 2 The resistance to compromise Begin

  1. .Si → Si+1 : H ELLO, MACk{BS,Si } (Si ) K{BS,Si } (The .Si node detects that its next one is compromised and sends a connect message to the  .Si+1 node at the top of its list)  2. .Si → Si+1 : (Sj , AU T H )KSj ,Si (The node .Si which receives the authentication request requests the base station through the node .Sj by which it sends its data 3. if ¯(the node is known by the base station) then 4. .BS → Si+1 : {Sj , AU T H _OK, KBS,Sj )KBS,Si } (The base station confirms the node and returns its individual key) 5. else   6. .BS → ∗ : BAN I SH, Si K{BS,Sj } The base station sends a banish order to all the nodes End

6 Simulation and Discussion To evaluate nodes resource usage, we performed intensives simulations in MATLAB using 50, 150, 400, 700, and 1000 nodes. We have also used TOSSIM and TelosB simulators 16-bit architecture, maximum CPU speed 8 MHz, 48 kB flash, 10 kB RAM with CC2420 radio chip [17] for this purpose. The ACORN algorithm that is based on stream encryption that provides authenticated encryption, i.e., both confidentiality, integrity, and authenticity, has also been used [18]. This algorithm supports 128-bit key and a 128-bit initialization vector and consists of 6 linear feedback shift registers (LFSRs). The discovery of the network nodes is done gradually. Since each hop is discovered just at the end of the previous one, there is no need for a special device for collision handling because each node that receives a signal simply registers it in its .Olist . Therefore, nodes do not review confirmation messages that amply limit collision issues. For collected data transmission, each node must perform a cryptographic operation (encryption, decryption) using the key per pair shared with a single node (the one by which it forwards its data). Thus, the number of operations is 1 (encryption) for the end nodes and 2 (encryption and decryption) for the others. It is important to point out that this number is linked to the number of paths that pass through a node. In short, the number of cryptographic operations for each node varies from 1 to .N ∈ N where N is a number of connections of a node. From simulations, we show that this number decreases with network density. Storage cost analysis is similar to computational cost. To cope with this, each node must store an individual key, a global key that is deleted after the deployment

Toward a Lightweight Cryptographic Key Management System in IoT Sensor Networks

41

16 14 Maximum paths

12 10 8 6 4 2 0

50

150

400 Network density

700

1000

7

5

(a) 16 14 Number of keys

12 10 8 6 4 2 0

14

12

9 Maximum paths

(b) Fig. 2 Paths and keys results analysis. (a) Maximum passages through a node. (b) Keys stored

phase, and a number of keys that varies according to its connectivity (.1 + n, .n ∈ N). For instance, in a network with 50 sensors, n is 14, with 400 sensors it is 9, and with 1000 nodes it is equal to 5 (see Fig. 2). Memory usage and energy consumption follow the same trend.

42

A. A. A. Ari et al.

Fig. 3 Comparison with Leap+ [5]

Concerning attack analysis, it was found that our protocol effectively prevents sibling attacks, which is not the case with KDC [19]. Moreover, with KDC, the base station is involved in pairwise key establishment that incurs additional computational and communication costs. This is not the case with our scheme where keys are established from node to node. In fact, the pairwise keys are known only by nodes involved in communication. As for probabilistic key-sharing schemes, symmetric-based key cryptography [20–22] and threshold-based cryptography [23, 24] were considered. In comparison with these schemes, the proposed protocol ensures that each node finds the shortest path to the base station, which minimizes communications cost. To perform comparison, we use the LEAP+ protocol [5]. LEAP+ combines two different services to provide encryption and authentication. The proposed method uses only a single service to perform both operations, as in Tesla protocol [19] and RC5 protocol [25]. Furthermore, our method is lightweight, since it is based on ACORN algorithm, which supports 128 bits. Thus, as shown in Fig. 3, LEAP+ uses too many keys, which leads to a significant memory consumption as compared to the proposed approach.

7 Conclusion The work carried out in this chapter deals with security issues in WSNs. The use of specialized literature on the subject allowed us to study and classify different key management schemes aiming at security objectives in the face of potential

Toward a Lightweight Cryptographic Key Management System in IoT Sensor Networks

43

attacks, achieving them in a more or less satisfactory way. Our contribution is a key management protocol that tries to find a compromise between the level of security to be ensured and the respect of the constraints set by the WSN. Inspired by both the LEAP+ protocol and the A* graph search algorithm, our protocol shows through evaluation results that it can provide more security with fewer constraints. However, the design of an efficient key management protocol for WSN applications remains a vast, open, and ever-expanding field of study and research. Most of the proposals made so far concern topologies with static sensor nodes, so it would be possible, from the perspective of our work, to adapt our proposal to the mobility of sensor nodes while developing mechanisms to detect malicious nodes. Acknowledgments We would like to thank the editor and the anonymous reviewers for their valuable remarks that helped us in better improving the content and presentation of the paper. Moreover, the author is grateful for the facilities provided by the DAVID Labs UPSay-UVSQ and its kind hospitality.

Conflict of Interest Statement On behalf of all authors, the corresponding author states that there is no conflict of interest.

References 1. Ndam, N.A., Salifu, A., Djedouboum, A.C., Tchangmena, A.A.N., Ari, A.A.A., Adouane, A.M., Abdou, W., Gueroui, A.M.: Reduction of data transmission in an IoT wireless sensor network. In: Ngatched, T.M.N., Woungang, I., Tapamo, J.R., Viriri, S. (eds) Pan-African Artificial Intelligence and Smart Systems. PAAISS 2022. Lecture Notes of the Institute for Computer Sciences, Social Informatics and Telecommunications Engineering, Vol. 459, pp. 39–57. Springer, Cham (2023) 2. Djam-Doudou, M., Ari, A.A.A., Emati, J.H.M., Njoya, A.N., Thiare, O., Labraoui, N., Gueroui, A.M.: A certificate-based pairwise key establishment protocol for IoT resourceconstrained devices. In: Ngatched Nkouatchah, T.M., Woungang, I., Tapamo, J.-R., Viriri, S. (eds.), Pan-African Artificial Intelligence and Smart Systems, pp. 3–18. Springer Nature Switzerland, Cham, (2023). https://doi.org/10.1007/978-3-031-25271-6_1 3. Hart, P.E., Nilsson, N.J., Raphael, B.: A formal basis for the heuristic determination of minimum cost paths. IEEE Trans. Syst. Sci. Cybern. 4(2), 100–107 (1968). https://doi.org/ 10.1109/TSSC.1968.300136 4. Babaghayou, M., Labraoui, N., Ari, A.A.A., Lagra, N., Ferrag, M.A., Maglaras, L.: SAMA: Security-aware monitoring approach for location abusing and UAV GPS-spoofing attacks on Internet of Vehicles. In: Jin, H., Liu, C., Pathan, AS.K., Fadlullah, Z.M., Choudhury, S. (eds.) Cognitive Radio Oriented Wireless Networks and Wireless Internet. CROWNCOM WiCON 2021. Lecture Notes of the Institute for Computer Sciences, Social Informatics and Telecom, vol. 427, pp. 343–360. Springer (2022) 5. Zhu, S., Setia, S., Jajodia, S.: Leap efficient security mechanisms for large-scale distributed sensor networks. In: Proceedings of the 1st International Conference on Embedded Networked Sensor Systems, SenSys ’03, pp. 308–309. Association for Computing Machinery, New York, NY, USA (2003). https://doi.org/10.1145/958491.958534

44

A. A. A. Ari et al.

6. Karlof, C., Sastry, N., Wagner, D.: TinySec: A link layer security architecture for wireless sensor networks, in: Proceedings of the 2nd International Conference on Embedded Networked Sensor Systems, SenSys ’04, pp. 162–175. Association for Computing Machinery, New York, NY, USA (2004). https://doi.org/10.1145/1031495.1031515 7. Hamidouche, R., Aliouat, Z., Gueroui, A.M., Ari, A.A.A., Louail, L.: Classical and bioinspired mobility in sensor networks for IoT applications. J. Network Comput. Appl. 121, 70–88 (2018). https://doi.org/10.1016/j.jnca.2018.07.010. https://www.sciencedirect.com/ science/article/pii/S1084804518302340 8. Kponhinto, G., Thiare, O., Ari, A.A.A., Gueroui, A.M., Khemiri-Kallel, S., Hwang, J.: Bioinspired solution for cluster-tree based data collection protocol in wireless sensors networks. In: NOMS 2023-2023 IEEE/IFIP Network Operations and Management Symposium, pp. 1–6. IEEE (2023) 9. Xiao, Y., Rayi, V.K., Sun, B., Du, X., Hu, F., Galloway, M.: A survey of key management schemes in wireless sensor networks. Comput. Commun. 30(11), 2314–2341 (2007). Special issue on security on wireless ad hoc and sensor networks. https://doi.org/10.1016/j.comcom. 2007.04.009. https://www.sciencedirect.com/science/article/pii/S0140366407001752 10. Boumerzoug, H., Amar Bensaber, B., Biskri, I.: A key management method based on an AVL tree and ECC cryptography for wireless sensor networks. In: Proceedings of the 7th ACM Symposium on QoS and Security for Wireless and Mobile Networks, Q2SWinet ’11, pp. 57– 62. Association for Computing Machinery, New York, NY, USA (2011). https://doi.org/10. 1145/2069105.2069115 11. Ari, A.A.A., Djedouboum, A.C., Njoya, A.N., Aziz, H.A., Gueroui, A.M., Mohamadou, A., Thiare, O., Labraoui, N.: Optimizing relay sensors in large-scale wireless sensor networks: A biologically inspired approach. Int. J. Eng. Res. Africa 63, 119–135 (2023) 12. Akyildiz, I., Su, W., Sankarasubramaniam, Y., Cayirci, E.: Wireless sensor networks: a survey. Comput. Networks 38(4), 393–422 (2002). https://doi.org/10.1016/S1389-1286(01)00302-4. https://www.sciencedirect.com/science/article/pii/S1389128601003024 13. Poornima, A., Amberker, B.: Tree-based key management scheme for heterogeneous sensor networks. In: 2008 16th IEEE International Conference on Networks, pp. 1–6. IEEE (2008) 14. Mamun, Q.E.K., Ramakrishnan, S.: SecCOSEn – a key management scheme for securing chain oriented sensor networks. In: 6th Annual Communication Networks and Services Research Conference (CNSR 2008), 2008, pp. 584–592. https://doi.org/10.1109/CNSR.2008.89 15. Camtepe, S.A., Yener, B.: Combinatorial design of key distribution mechanisms for wireless sensor networks. IEEE/ACM Trans. Netw. 15(2), 346–358 (2007). https://doi.org/10.1109/ TNET.2007.892879 16. Kocher, P., Jaffe, J., Jun, B.: Differential power analysis. In: Advances in Cryptology, CRYPTO’99 (1999) 17. telosb, TelosB datasheet: http://www.xbow.com/Products/Product_pdf_files/Wireless_pdf/ TelosB_Datasheet.pdf, Accessed: 2022-02-17 (2022) 18. Wu, H.: ACORN: A lightweight authenticated cipher (v3). Candidate for the CAESAR competition. https://competitions.cr.yp.to/round3/acornv3.pdf 19. Perrig, A., Szewczyk, R., Tygar, J., Wen, V., Culler, D.: SPINS: Security protocols for sensor networks. Wirel. Networks 8, 521–534 (2002). https://doi.org/10.1023/A:1016598314198 20. Labraoui, N., Gueroui, M., Aliouat, M.: Secure DV-Hop localization scheme against wormhole attacks in wireless sensor networks. Trans. Emerg. Telecommun. Technol. 23, 303–316 (2012). https://doi.org/10.1002/ett.1532 21. Eschenauer, L., Gligor, V.D.: A key-management scheme for distributed sensor networks. In: Proceedings of the 9th ACM Conference on Computer and Communications Security, CCS ’02, pp. 41–47. Association for Computing Machinery, New York, NY, USA (2002). https:// doi.org/10.1145/586110.586117 22. Zhu, S., Xu, S., Setia, S., Jajodia, S.: Establishing pair-wise keys for secure communication in ad hoc networks: A probabilistic approach (2003). https://doi.org/10.1109/ICNP.2003.1249782

Toward a Lightweight Cryptographic Key Management System in IoT Sensor Networks

45

23. Eschenauer, L., Gligor, V.D.: A key-management scheme for distributed sensor networks. In: Proceedings of the 9th ACM Conference on Computer and Communications Security, CCS ’02, pp. 41–47. Association for Computing Machinery, New York, NY, USA (2002). https:// doi.org/10.1145/586110.586117 24. Liu, D., Ning, P., Li, R.: Establishing pairwise keys in distributed sensor networks. ACM Trans. Inf. Syst. Secur. 8(1), 41–77 (2005). https://doi.org/10.1145/1053283.1053287 25. Rivest, R.: The RC5 encryption algorithm, Dr Dobb’s J 20. https://doi.org/10.1007/3-54060590-8_7

Edge Clustering and Communication Efficiency with GNNs in Internet of Vehicles Jessica Graham, Anthony Medico, Renata Dividino, and Robson E. De Grande

1 Introduction Technology and the future of intelligent cities with autonomous and driving vehicles are advancing at an accelerated pace. Self-driving vehicles’ trends and future allow for improved safety, flexibility, and traffic management. Vehicular edge computing (VEC) introduces a form of mobile cloud computing that allows offloading tasks to the network edge, allowing for more efficient computation and sharing [23]. VEC leverages communication between vehicles and service providers (SPs) within the range of the requesting user [15]. To handle the tasks, SPs typically represent other vehicles with available resources or cloud resources, such as cloudlets, roadside units (RSUs), and remote cloud servers. Users commonly refer to the vehicles or nodes within the network requesting tasks computed or offloaded to the SPs within range [15]. These clouds usually involve (V2V) and (V2I) to support communication on the edge [15, 23]. Paradigms, such as VEC, vehicular fog computing (VFC), and the Internet of Vehicles (IoV), improve upon the current approaches of vehicular ad hoc networks (VANET) [14, 18, 23]. Many of these paradigms share commonalities, such as types of stakeholders within the cloud network, cloud providers, cloud tenants/users, cloud service brokers, and end users [17]. In addition to the various stakeholders, various tasks and processes may be communicated, such as safety-related, colli-

This work is partially supported by Canada Research grants. J. Graham () · A. Medico · R. Dividino · R. E. De Grande Brock University, St. Catharines, ON, Canada e-mail: [email protected]; [email protected]; [email protected]; [email protected] © The Author(s), under exclusive license to Springer Nature Switzerland AG 2024 I. Woungang, S. K. Dhurandher (eds.), The 6th International Conference on Wireless, Intelligent and Distributed Environment for Communication, Lecture Notes on Data Engineering and Communications Technologies 185, https://doi.org/10.1007/978-3-031-47126-1_4

47

48

J. Graham et. al.

sion avoidance, driver assistance, traffic management, control, and infotainment [1, 11, 15]. Each paradigm differs slightly in its strengths and problems, ranging from design issues with allocation, caching, mobility, and communication. Intelligent transportation systems (ITS) enable services and applications through various vehicular network paradigms (VEC, VFC, VANETs, and IoV) [5]. ITS helps smart vehicles to form the ability to gather and process data in real time through vehicles, sensors, and infrastructure [5, 13, 13]. Data transmission is problematic due to low latency requirements, service-level agreements (SLAs), and disconnecting in a highly mobile environment [11] where computation and storage undergo issues when resources are not evenly shared within the network [1], demanding efficient resource allocation without compromising the quality of service. Numerous approaches attempt to support vehicular systems—intelligent, predictive, stochastic, optimization, incentive, and pricing models/algorithms. Intelligent methods use artificial intelligence to assist in allocating resources [11]. Predictive techniques help estimate the resource needs [29]. Stochastic methods offer statistical models and policies to estimate resource availability [11]. Optimization methods seek to improve the availability of resources by leveraging other resources within the network or reducing workloads [30]. Finally, incentives and pricing mechanisms promote resource sharing to distribute the workload [11]. However, these works fall short when considering scalability and latency with resource allocation. Scalability matters in the decision-making complexity not being compatible with real-time allocation demands. Elasticity is critical to accommodate scaling without service disruption [5]. Additionally, connectivity is crucial for lowering latency and service disruptions [3, 4]. Consequently, addressing these multifaceted challenges requires accounting for collective relationships among nodes, such as vehicles and RSUs. Therefore, organizing and classifying resources in dynamic environments are fundamental to enabling collaborative VEC. Graph neural networks (GNN) support prediction, clustering, and classification in vehicular settings [24]. Naturally, special characteristics of the traffic have been explored for addressing spatiotemporal interactions for predictions [2]. Temporal correlations study to infer trends over time [20]. Estimating mobility through complex graph structures is used to support better vehicle connectivity [7]. GNNs are vital for supporting modelling such intricate, highly dynamic environments. Vehicular systems are susceptible to highly dynamic changes, demanding adaptive approaches. Changes cause instability and reduce connection duration, decreasing service provision within the network. In this chapter, we propose using GNNs that effectively use topological structures in vehicular networks to learn expressive entity representations in low-dimensional space that contain rich global–local structural information to assist with efficient vehicular clustering; such entities are vehicles and infrastructure—towers and RSUs. We show that the GNN-based clustering approach performs better than traditional (non-graph) clustering methods, which do not leverage the vehicular network graph structure. This chapter is structured as follows. Section 2 reviews the current research on clustering in vehicular clouds, describing relevant works. Section 3 defines the problem and assumptions dealt with in this work. Section 4 presents our GNN-

Edge Clustering and Communication Efficiency with GNNs in Internet of Vehicles

49

based approach. Section 5 details this chapter’s setup, testing, and results. Section 6 summarizes our findings and presents future directions.

2 Related Work Traditional approaches extensively utilize artificial intelligence (AI) techniques in vehicular clouds to enhance predictions, efficiencies, and meta-heuristics. While these techniques show promising results, the future of intelligent decision-making in vehicular networks may lie in adopting GNNs.

2.1 Traditional Intelligent Vehicular Networks Reinforcement learning (RL) enables long-term learning and improved decisionmaking. Lee and Lee [11] proposed combining reinforcement learning with heuristic information to allocate resources efficiently, utilizing parked vehicles such as VFC. Similarly, Zhang et al. [31] presented Distributed Task Offloading for multiagent Load Balancing (DTOMALB), incorporating deep reinforcement learning in VEC to optimize resource allocation among different users. In a different context, Shi et al. [21] employed deep reinforcement learning in VFC for task offloading and prioritizing specific tasks, showing the capability to learn and improve decisionmaking in vehicular networks. Other traditional intelligence approaches include semi-Markov decision process (S-MDP), MDP, cognitive networks, and smart VFC [28]. Menguette et al. [18] proposed an optimal decision scheme utilizing S-MDP and ADVICe to maximize resource availability by rewarding the system. Lin et al. [13] presented two decision models: a multitask parallel multi-granularity collaborative decision model (MPMCD), enhancing knowledge discovery for smarter process utilization, and an AI-driven cognitive networking collaborative decision-making (ACNCD) model, supporting real-time collaborative multitasking. Gasmi and Aliouat [5] discussed the benefits of integrating AI into IoV for making more intelligent, real-time decisions. The works highlighted in Table 1 demonstrate diverse implementations to create networks with enhanced decision-making capabilities.

2.2 Graph Neural Networks-Based Intelligent Vehicular Networks GNNs emerged as a promising area of research in vehicular networks, emphasizing enhancing decision-making processes in dynamic environments. An overview

50

J. Graham et. al.





✓ ✓

✓ ✓

✓ ✓ ✓ ✓ ✓ ✓ ✓ ✓

✓ ✓ ✓ ✓ ✓ ✓

✓ ✓

Dist.

V2X Centralized Decentralized Distributed

S-MDP & ADVICe [18] ✓ Predictions LSTM-Based DNN [11] Distributed RL Algo [28] ✓ ✓ ACNCD [13] MPMCD [13] ✓ ✓ Artificial AI with IoV [5] intelligence Soft Actor-Critic DRL [21] ✓ GNN GNN-based [7] Our work



App. Comm.

V2V V2I

Work DTOMALB [31]

Method

Decision-Making Graph Neural Networks Meta-Heuristics Reinforcement Learning Proactive Reactive

Category Decisionmaking

Paradigm

VANET/ MANET ITS VEC VFC IoV

Table 1 Summary of traditional intelligent works





✓ ✓

✓ ✓ ✓ ✓ ✓ ✓

✓ ✓ ✓ ✓ ✓ ✓ ✓ ✓ ✓ ✓ ✓ ✓ ✓ ✓ ✓ ✓ ✓ ✓

✓ ✓ ✓ ✓ ✓ ✓ ✓ ✓ ✓ ✓ ✓ ✓ ✓ ✓ ✓



of existing GNN-based studies in vehicular networks showcases their diverse applications in smart city network management, location accuracy improvement, traffic predictions, and network clustering [24]. The reviewed works demonstrate the adaptability and potential of GNN-based approaches in addressing various challenges within vehicular networks. Further works emphasize location accuracy and spatiotemporal interactions. GNNs facilitate location accuracy, effectively leveraging temporal and spatial correlations [12]. Additionally, the application of spatiotemporal deep graph infomax (STDGI) in traffic networks enables the prediction of future patterns and enhances information sharing, thereby optimizing network performance [19]. Moreover, GNN estimators specifically target time-of-arrival (ETA) estimation in transportation networks, addressing complex spatiotemporal interactions and anticipating events such as rush hours [2]. The proposed temporal-aware multi-interest GNN (TMI-GNN) [20] addresses session-based recommendation (SBR) method limitations by disentangling multiple user interests and incorporating multi-form temporal information. This is achieved through a novel multi-interest graph structure in a mobile network, utilizing GNNs to capture item transitions, disentangle interests, and refine representations while integrating temporal signals for improved recommendation performance. Graph auto-encoder (GAE), which is a neural network architecture for unsupervised representation learning on graph-structured data, is employed in combination with network clustering to predict vehicle connectivity

✓ ✓ ✓ ✓

Spatial

Work STDGI [19] GCN-CNVPS [12] ETA prediction [2] TMI GNN [20] GNN [7]

Temporal

Table 2 Summary of graph neural network works

✓ ✓ ✓

Vehicular networks

51

Mobile networks

Edge Clustering and Communication Efficiency with GNNs in Internet of Vehicles

✓ ✓ ✓ ✓ ✓

and facilitate efficient cluster formation based on the force—based on vehicles’ motion similarity—between vehicles and their relative mobility [7]. The GNN-based studies summarized are displayed in Table 2, highlighting features associated with temporal, spatial, mobile network, and vehicular network implementations. Temporal refers to the progression of events and patterns over time and its influence on relationships in temporal analysis. Spatial concerns the spatial relationships that signify information about objects based on their locations. Mobile networks encompass cellular devices interconnected within a network, while vehicular networks relate to vehicular communication. GNNs within vehicular networks offer opportunities to explore spatial and temporal aspects. Our work explores GNNs for intelligent resource allocation by combining clustering for vehicular connectivity prediction based on motion similarity and relative mobility [7]. Thus, opportunities include exploring diverse features, employing different GNN algorithms, incorporating time-series analysis, and making future predictions; thus, we are inspired to contribute by further developing resource allocation techniques using GNNs, leveraging clustering to optimize resource proximity, and using Euclidean distance for edge representations. The ability to intelligently learn with GNNs and efficiently cluster with clustering techniques presents opportunities to predict future resource allocation demands, dwell time for cluster life, and traffic patterns for improved scalability within the network.

3 Problem Statement Resource and data sharing is a challenge in a highly dynamic environment due to the mobility of vehicles and dynamics in demand for resources, such as storage, energy, computing resources, and cost. Mobility changes the availability of resources, density, and range of communication. It is crucial to have an environment that more precisely manages mobile resources based on communication conditions.

52

J. Graham et. al.

Fig. 1 Illustration of the vehicular scenario. (a) Vehicular communication methods. (b) Cologne, Germany—OpenStreetMap

The challenge thus in enabling the sharing on the network edge in VEC consists of assembling and managing the group of vehicles that consistently and reliably sustain communication during a determined duration. Naturally, by reducing the relevance scope to a smaller region—the edge, data, and resource management become more susceptible to dynamic topology changes. The size of the cluster also directly impacts its management on complexity, scale, and availability of data and resources. Therefore, clustering vehicles is fundamental for VEC, especially when the ITS environment contains many conflicting dynamic features. Figure 1a illustrates the different vehicular communication methods that may happen: V2V, V2I, vehicle-to-everything (V2X), and I2I. The figure shows different entities (vehicle and RSU) and connections. This representation may also be conceptualized as a tree-like structure emphasizing the hierarchical significance of communication within the network. Each entity (vertex) of the graph corresponds to a vehicle or an infrastructure component (towers and RSUs). Entities are also represented by features, such as coordinates (position), speed, and dwell time. The edge represents the communication link between vertices. This chapter focuses on enhancing the formation of vehicular edge networks through clustering using GNNs. An enhanced GNN-based clustering approach significantly reduces latency, enhances network stability, and contributes to the scalability of vehicular networks in future works. Our work aims to verify that clustering remains consistent after analysing and formatting the data with a GNN where relevant features may be added flexibly in our model for more precise and timely forming vehicular edges. This is a particularly crucial endeavour, given the dynamic nature of vehicular networks and the need for efficient utilization of resources.

Edge Clustering and Communication Efficiency with GNNs in Internet of Vehicles

53

4 GNN-Based Vehicular Edge Clustering 4.1 VANET Graphs We define a VANET graph as .G = (V , E, X, λ), where .V = v1 , . . . , vN is a set of nodes, .E ⊆ V × V is a set of edges, .X = X1 , X2 , . . . , XN is a feature matrix where .X ∈ RN ×c and c is the dimension of the node features, and .λ maps a node .vi to a feature vector .Xi . Note that we consider undirected graphs. The node feature vectors encode the node type, such as tower, RSU, and car, and its attributes, such as position and speed. We define that the edges connecting these nodes represent the Euclidean distance between them, bounded within a predefined range from zero to a maximum set distance. Note the maximum distance varies based on the scenario and type of node. For instance, a tower and RSU node have a larger range than a vehicle node with a shorter connection range. It is also possible for weather and buildings to impact this range, which will be discussed in future work. Figure 2 shows the VANET graph with nodes, such as ‘Tower 1’ and ‘RSU 1,’ and their connections and features.

Fig. 2 Architecture of our GAE model

54

J. Graham et. al.

4.2 GNN Architecture GNNs are models that learn by structuring data as a graph into latent lowdimensional representation while preserving the graph properties. GNNs employ  a mapping .f : G → Z ∈ RN ×c , where Z is an updated feature matrix of G. Each layer of a GNN typically consists of two steps: (1) aggregation step, where the information about the neighbourhood of every node is gathered; (2) update step, where the feature vector of every node is updated based on its current feature vector and the aggregated neighbourhood information. These steps are applied as often as the number of layers in the GNN. The output of the final layer is used for downstream tasks, such as node classification, link prediction, and clustering. Different GNN layer implementations are proposed in the literature, such as graph convolution network (GCN [9]), simplified graph convolutions (SGC [27]), graph attention network (GAT [26]), and GraphSAGE [6]. The main differences between different GNN layers consist of the type of aggregation performed (e.g., which edges are considered) on the graph structure. GCNs use convolutions in the neighbourhood to capture localized graph patterns, aiding in traffic flow prediction, anomaly detection, and driving improvements in network management. GATs implement an attention mechanism that empowers nodes to concentrate on pertinent neighbouring nodes. Therefore, facilitating the modelling of varying inter-vehicle relationships is crucial for understanding traffic dynamics. Additionally, GraphSAGE takes a unique approach to learning node embeddings through sampling aggregation to optimize training for large data sets. GAE [10] is a GNN architecture that operates unsupervised or self-supervised. It learns valuable graph representations from an unlabelled data set and transfers this knowledge of representations to downstream tasks, such as clustering. A GAE is composed of an encoder and a decoder. The encoder transforms the input graph into a lower-dimensional latent space. The output of the encoder is the input of the decoder. The decoder aims to reconstruct the original input graph (structure and node features) from the latent representation. Figure 2 depicts this model. Our encoder comprises two layers; we experimented with two GCN layers, GAT layers, and GraphSAGE layers. The dimension of the input layer is the dimension of vehicle features c, and the output dimension is predefined (e.g., five in our experiment). Let A be the adjacency matrix of graph G. For our GCN-based encoder, for a k-layer GCN, the layer-wise propagation rule is given by ˜ − 2 H (l) W (l) ), H (k+1) = f (H (k) , A) = relu(D 2 AD 1

.

1

(1)

where .A˜ = A + I , I is the identity matrix, D is a diagonal matrix with .Dii = ΣjN=1 Aij , .H (l) and .W (l) are the feature and weight at the Kth layer, respectively, and relu() is the rectified linear (ReLU) activation function. .H (0) is the matrix of node feature vectors X, and .H (K) is the (deterministic) graph embedding matrix Z.

Edge Clustering and Communication Efficiency with GNNs in Internet of Vehicles

55

Our decoder is a vanilla model based on the inner product between the latent representations of two nodes. In other words, the graph adjacency matrix .Aˆ is reconstructed from the inner product of two-node latent representation as .Aˆ = σ (ZZ T ), where .σ is the sigmoid activation function. The learning phase of our model involves minimizing the reconstruction loss function—specifically, the differences between the input graph and the reconstructed graph—using gradientbased optimization. The model training occurs in unsupervised learning where the graph reconstruction error is minimized: .



  Aij log(yˆij ) + (1 − Aij ) log(1 − yˆij )

(2)

where .yˆij denotes the probability of an edge with logits between the node .vi and .vj . Once trained, our model transforms VANET graphs to their latent representation. This low-dimensional representation contains rich global–local structural information and is used to assist with efficient vehicular clustering.

4.3 Clustering We employ the K-Means algorithm to cluster the model output data in this chapter. K-Means is a popular clustering algorithm to partition a data set into distinct, nonoverlapping groupings called clusters. This algorithm begins by initializing the number of clusters to be created and randomly selects centroids to begin clustering. The Euclidean distance is then calculated between data points and each cluster centroid; this distance is assigned based on the shortest distance to a centroid. Once all data points are assigned, the centroids are recalculated using the mean average for each cluster. The algorithm aims to choose centroids to minimize the inertia and within-cluster sum-of-squares criterion. This is repeated in a fixed number of iterations or until convergence occurs. In our case, we only set the fixed number of iterations. Upon completion of the iterations, the algorithm converges, meaning the clusters are final and have reached a stable point.

5 Experiments We have conducted experiments to evaluate our proposed model against baseline algorithms. This project’s source code is available in a publicly open repository.1 1 Source

Code for the project is hosted on https://github.com/jegraham/1-GNN-Clustering.

56

J. Graham et. al.

5.1 Data Our proposed analysis scenario is Cologne, Germany. We thus construct the data set based on Cologne’s map using the SUMO [16], VEINS [22], and OMNeT++ [25] simulators. Cologne, Germany, is represented in latitude and longitude (6.166558, 50.510516) and (7.053531, 51.840721). The streets within the data set vary by speed, length, dimension, and traffic density. The map displayed in Fig. 1b is the base transportation topology run in VEINS. OMNet++ produces the output data set containing vehicles and infrastructure nodes (RSUs) through VEINS and with the mobility generated by SUMO. The information extracted from the data set includes the IDs, x and y positions of the vehicles, towers, and RSUs. This data set does not account for any error in vehicle position as this is simulated data. The area of interest is illustrated in Fig. 1b. The GAE model is implemented and trained using Python Geometric Framework.2 The experiments are conducted in Google Colaboratory machine type a2-highgpu-2g.

5.2 Settings We compare our method against a baseline clustering algorithm where we run KMeans on our original input VANET graphs (without any transformation). Parameters within this chapter are described as follows. The clustering algorithm’s number of clusters to group nodes is set to 50. The number of iterations of the clustering algorithm is set to 1000. GAE is trained on 4000 epochs. The number of dimensions of each node feature is set to .c = 3 as each vehicle is characterized by its position latitude, longitude, and node type. In this chapter, we set different maximum distance criteria to connect two cars (e.g., if their distance does not exceed more than 150 m), a car and an RSU (e.g., if their distance does not exceed more than 250 m), a car and a tower (e.g., if their distance does not exceed more than 500 m), and an RSU and a tower (e.g., if their distance does not exceed more than 500 m). The density of 300 vehicles in approximately .21.40 km2 for Cologne, Germany, is approximately 14 cars per . km2 , with 300 vehicles and 11 infrastructure nodes (RSU and Towers). We randomly sample the edges on each graph to form the training, validation, and testing sets. The edge ratios in the training set to the validation and testing sets are .0.05 and .0.15, respectively. We select ADAM [8] with a learning rate of .0.001 as the optimization strategy.

2 PyTorch

Geometric https://pytorch-geometric.readthedocs.io/en/latest/.

Edge Clustering and Communication Efficiency with GNNs in Internet of Vehicles

57

5.3 Results 5.3.1

Model Training Results

The outcomes of this chapter assess the effectiveness of three prevalent GNNs: graph convolutional networks (GCNs), graph attention networks (GATs), and graph sample and aggregation (GraphSAGE). In the following figures, the GCN, GAT, and GraphSAGE processing, shown in green, present a different perspective than our K-Means baseline approach, represented in red, as shown in Fig. 3. The nodes in the network are denoted in grey dots, while a connection in black is made if it meets the specified V2V, V2I, and V2R maximum distance settings. The centre of each cluster, also known as the centroid, is ‘X’ in the respective colour, while the cluster heads are represented as a ‘diamond.’ Figure 3 represents similar graph plots for all three GNN approaches. This graph, in particular, is fusing a GCN.

5.3.2

Average Distance to Centroid

The average distance to a cluster’s centroid measures similarity among data points from the centroids of the clusters to which they belong. In clustering, the goal is to keep nodes close together in clusters, where a centroid represents each cluster. The centroid of a cluster is usually the average of all the data points within that

Fig. 3 GNN comparison on the baseline K-Means approach

58

J. Graham et. al.

(b)

(a)

(c) Fig. 4 Average distance to centroid: (a) GAT, (b) GCN, and (c) GraphSAGE

cluster. Figure 4 shows the comparison of the average distance to the centroid for each cluster size, K, against the baseline approach using K-Means. As shown in Fig. 4a, the GAT approach displays identical averages for the first 9 clusters and a .58.54% decrease in the averages over nine clusters. As illustrated in Fig. 4b, the GCN approach shows identical averages for the first 10 clusters and sees a .62.50% decrease in the average distance over 10 clusters. Figure 4c highlights that GraphSAGE has identical averages for the first 8 clusters and emphasizes a .47.62% decrease in the average distance over 8 clusters. The three GNN approaches share similarities with the K-Means baseline for the first 10 clusters (K) and diverge by 47 to .62.50% decrease in the distance, signalling that considering the graph (local and global connectivity) information among the cars and infrastructure impacts clustering and resource allocation. In the next sections, we further investigate the impact on the quality of the clusters created. 5.3.3

Mean Squared Error and Sum of Squared Error

The sum of squared errors (SSE) analysis is a common approach to assess the quality of the clustering results by measuring the sum of the squared distances

Edge Clustering and Communication Efficiency with GNNs in Internet of Vehicles

(a)

59

(b)

Fig. 5 MSE and SSE analysis: GAT, GCN, and GraphSAGE. (a) GAT SSE. (b) GAT MSE

between each data point within a cluster. The analysis shown in Fig. 5 analyses how close a cluster is to its respective centroid, meaning a smaller SSE indicates a more compact and well-defined data clustering. A good value with SSE is determined using the elbow method, where the data are plotted in an elbow-like format to show where the clustering sees significant and slight improvement on the graph. An elbow will form during the transition from significant to slight improvement, signalling the beginning of the SSE levelling off. All three GNN approaches highlight the same elbow graph as the baseline K-Means approach, with an elbow forming at approximately 10 clusters (K) and a 0% change between the baseline and GNN approaches. A similar observation was noted when we calculated mean squared error (MSE) scores for all three GNN approaches.

5.3.4

Silhouette Score

The silhouette score assesses cluster quality in clustering analyses by measuring how closely data points within a cluster are connected to their cluster (cohesion) in contrast to their separation from other clusters. This score spans from .−1, indicating a weak match, through 0, suggesting proximity to the boundary between neighbouring clusters, to 1, reflecting a strong match. Figure 6 compares all three GNN implementations and their comparison to the baseline K-Means approach. The GAT approach in Fig. 6a and GCN approach in Fig. 6c show a silhouette score between .0.39 and .0.46 for all clusters with similarities between the two approaches for the first 8 clusters before the two diverge and follow a similar upward trend. Similarly, the GraphSAGE approach in Fig. 6e diverges after the first 9 clusters and shows a .63.41% increase after 9 clusters. The three GNN approaches are all within the same range as the baseline approach and show similar trends with slight improvements showing consistency with the baseline approach.

60

J. Graham et. al.

Fig. 6 Silhouette score and score analysis: GCN, GAT, GraphSAGE. (a) GAT. (b) GAT. (c) GCN. (d) GCN. (e) GraphSAGE. (f) GraphSAGE

5.3.5

Davies–Bouldin Index

The Davies–Bouldin index assessed the quality of clusters by providing a comprehensive evaluation of the separation between clusters while also considering internal cohesion. By considering the distances between cluster centroids and the average distances within clusters, the Davies–Bouldin score offers insights into how distinct and related the clusters are to one another, aiding in deciding an optimal number of

Edge Clustering and Communication Efficiency with GNNs in Internet of Vehicles

61

clusters. The closer the score is to 0, the more distinct and well-separated the clusters are, implying an accuracy within the clustering solution. The comparison for the three GNNs is shown in Fig. 6, which shows all values approaching 0 through the increased number of clusters. The GAT approach in Fig. 6b shows a similar trend to the baseline approach where the first 8, K, clusters are identical, and a slight divergence occurs where a .45.24% decrease is seen in comparison to the baseline approach trend. Similarly, the GCN approach in Fig. 6d shows a .42.86% decrease after a cluster size of 8 compared to the baseline approach. Finally, the GraphSAGE Approach 6f has identical index scores for the first 7 cluster sizes and diverges to show a .53.49% decrease from the baseline approach. The three GNN approaches show similarities within the first 8 cluster sizes and diverge to a .42.86% to .53.49% decrease over the remaining 42 clusters.

5.3.6

Area Under the Curve and Average Precision

The Area Under the Curve (AUC) and Average Precision (AP) gauge the effectiveness of GNN models. AUC quantifies a GNN model’s capacity to discern positive and negative instances across a spectrum of threshold values. Its values typically range between 0 and 1. An AUC of .0.5 corresponds to a scenario where the model’s performance is randomly guessed. Exceeding .0.5 signifies performance surpassing random guessing and indicates excellent classification. AP assesses the precision of relevant instances compared to the total instances predicted by the model. Like AUC, AP also spans from 0 to 1. A value of 0 indicates subpar performance, while an AP of 1 signifies impeccable precision and recall trade-off. Notably, an AP of .0.8 or higher is commonly regarded as an excellent model. Figure 7 highlights the values’ performance and improvements from initial epochs until completion for all three GNN approaches. The GAT, Fig. 7a shows a steady improvement with AP starting at approximately .0.69 and improving to .0.73, while the AUC starts at approximately .0.74, increasing to .0.78, just below our .0.8 threshold for a good AUC value. GCN, Fig. 7b shows an AP growth from .0.51 to .0.71, while the AUC starts at .0.45 and increases to .0.74. GraphSAGE, Fig. 7c AP starts at .0.45 and increases to .0.71 after a short drop in the first 500 epochs to .0.38, while the AUC starts at .0.3 and increases to .0.72. All three GNN implementations approach a ‘Good’ AUC value over 1000 epochs. Through sensitive analyses, adjustments to the model layers, training values, and additional epoch runs may improve results.

6 Conclusion This chapter examines the potential of three GNN-based clustering approaches for enhancing data and resource sharing on the network edge for vehicular systems. We assess their capability to form cohesive vehicle clusters in edge computing through experiments and simulations. For a large number of clusters (K), GNN-

62

J. Graham et. al.

(a)

(b)

(c) Fig. 7 AUC and AP analysis: GCN, GAT, GraphSAGE. (a) GAT. (b) GCN. (c) GraphSAGE

based approaches (GCN, GAT, and SAGE) decreased from 47 to 62.5% in average distance to the centroid. At the same time, they presented negligible differences against K-Means when observing SSE. When looking into cluster cohesion, GNNbased approaches outperformed K-Means up to 63.41% for more than nine clusters in the Silhouette score and up to 53.9% for more than seven clusters in the Davies– Bouldin index. Finally, all three GNN-based approaches reached a ‘good’ AUC value over 1000 epochs. Thus, our proposed approach helped cohesively group vehicles on the edge, potentially resulting in more reliable vehicular communication. In future work, several key avenues will be explored to enhance the capabilities and predictive power of the model. We plan to implement this approach with larger data sets, consider the temporal dimension in the vehicular networks to predict future clusters, and explore the integration of additional parameters to improve predictions. We will introduce temporal edges connecting nodes with the same ID across snapshots to capture temporal relationships. Scalability, real-world deployment, and the integration of advanced machine learning techniques will be studied.

Edge Clustering and Communication Efficiency with GNNs in Internet of Vehicles

63

References 1. Benhaddou, D.: Wireless Sensor and Mobile Ad-hoc Networks: Vehicular and Space Applications. Springer (2015) 2. Derrow-Pinion, A., She, J., Wong, D., Lange, O., Hester, T., Perez, L., Nunkesser, M., Lee, S., Guo, X., Wiltshire, B., Battaglia, P.W., Gupta, V., Li, A., Xu, Z., Sanchez-Gonzalez, A., Li, Y., Velickovic, P.: ETA prediction with graph neural networks in Google Maps. In: Proc. of the ACM Int. Conference on Information & Knowledge Management, pp. 3767–3776 (2021) 3. Dey, K.C., Rayamajhi, A., Chowdhury, M., Bhavsar, P., Martin, J.: Vehicle-to-vehicle (v2v) and vehicle-to-infrastructure (v2i) communication in a heterogeneous wireless network— performance evaluation. Transp. Res. Part C Emerg. Technol. 68, 168–184 (2016) 4. Gai, K., Qiu, M., Zhao, H., Tao, L., Zong, Z.: Dynamic energy-aware cloudlet-based mobile cloud computing model for green computing. J. Network Comput. Appl. 59, 46–54 (2016) 5. Gasmi, R., Aliouat, M.: Vehicular ad hoc networks versus Internet of Vehicles - a comparative view. In: Proc. of the IEEE Int. Conference on Networking and Advanced Systems (ICNAS), pp. 1–6 (2019) 6. Hamilton, W., Ying, Z., Leskovec, J.: Inductive representation learning on large graphs. Adv. Neural Inf. Process. Syst. 30, (2017) 7. Hu, H., Lee, M.J.: Graph neural network-based clustering enhancement in VANET for cooperative driving. In: Proc. of the Int. IEEE Conference on Artificial Intelligence in Information and Communication (ICAIIC), pp. 162–167 (2022) 8. Kingma, D.P., Ba, J.: Adam: A method for stochastic optimization. Preprint (2014). arXiv:1412.6980 9. Kipf, T.N., Welling, M.: Semi-supervised classification with graph convolutional networks. In: International Conference on Learning Representations (2016) 10. Kipf, T.N., Welling, M.: Variational graph auto-encoders (2016). ArXiv:1611.07308 [cs, stat] 11. Lee, S.S., Lee, S.: Resource allocation for vehicular fog computing using reinforcement learning combined with heuristic information. IEEE Internet Things J. 7(10), 10,450–10,464 (2020) 12. Lin, C.H., Fang, Y.H., Chang, H.Y., Lin, Y.C., Chung, W.H., Lin, S.C., Lee, T.S.: GCNCNVPS: Novel method for cooperative neighboring vehicle positioning system based on graph convolution network. IEEE Access 9, 153,429–153,441 (2021) 13. Lin, K., Gao, J., Li, Y., Savaglio, C., Fortino, G.: Multi-granularity collaborative decision with cognitive networking in intelligent transportation systems. IEEE Trans. Intell. Transp. Syst., 1–11 (2022) 14. Liu, Y., Xu, C., Zhan, Y., Liu, Z., Guan, J., Zhang, H.: Incentive mechanism for computation offloading using edge computing: A Stackelberg game approach. Comput. Networks 129, 399–409 (2017) 15. LiWang, M., Hosseinalipour, S., Gao, Z., Tang, Y., Huang, L., Dai, H.: Allocation of computation-intensive graph jobs over vehicular clouds in IoV. IEEE Internet Things J. 7(1), 311–324 (2020) 16. Lopez, P.A., Behrisch, M., Bieker-Walz, L., Erdmann, J., Flötteröd, Y.P., Hilbrich, R., Lücken, L., Rummel, J., Wagner, P., Wießner, E.: Microscopic traffic simulation using SUMO. In: Proc. of the IEEE Int. Conf. on Intelligent Transportation Systems, pp. 2575–2582 (2018) 17. Luong, N.C., Wang, P., Niyato, D., Wen, Y., Han, Z.: Resource management in cloud networking using economic analysis and pricing models: A survey. IEEE Commun. Surv. Tutor. 19(2), 954–1001 (2017) 18. Meneguette, R.I., Boukerche, A., Pimenta, A.H.M., Meneguette, M.: A resource allocation scheme based on semi-Markov decision process for dynamic vehicular clouds. In: Proc. of the IEEE Int. Conference on Communications (ICC), pp. 1–6 (2017) 19. Opolka, F.L., Solomon, A., Cangea, C., Veliˇckovi´c, P., Liò, P., Hjelm, R.D.: Spatio-temporal deep graph infomax (2019). ArXiv:1904.06316 [cs, stat]

64

J. Graham et. al.

20. Shen, Q., Zhu, S., Pang, Y., Zhang, Y., Wei, Z.: Temporal aware multi-interest graph neural network for session-based recommendation (2021). ArXiv:2112.15328 [cs] 21. Shi, J., Du, J., Wang, J., Wang, J., Yuan, J.: Priority-aware task offloading in vehicular fog computing based on deep reinforcement learning. IEEE Trans. Veh. Technol. 69(12), 16,067– 16,081 (2020) 22. Sommer, C., Eckhoff, D., Brummer, A., Buse, D.S., Hagenauer, F., Joerer, S., Segata, M.: Veins: The open source vehicular network simulation framework. In: Springer Recent Advances in Network Simulation, pp. 215–252. Springer (2019) 23. Sun, F., Hou, F., Cheng, N., Wang, M., Zhou, H., Gui, L., Shen, X.: Cooperative task scheduling for computation offloading in vehicular cloud. IEEE Trans. Veh. Technol. 67(11), 11,049– 11,061 (2018) 24. Tam, P., Song, I., Kang, S., Ros, S., Kim, S.: Graph neural networks for intelligent modelling in network management and orchestration: A survey on communications. Electronics 11(20), 3371 (2022) 25. Varga, A., Hornig, R.: An overview of the OMNeT++ simulation environment. In: Proc. of the Int. Conf. on Simulation Tools and Techniques for Communications, Networks and Systems, p. 10 (2010) 26. Veliˇckovi´c, P., Cucurull, G., Casanova, A., Romero, A., Liò, P., Bengio, Y.: Graph attention networks. In: International Conference on Learning Representations (2018) 27. Wu, F., Souza, A., Zhang, T., Fifty, C., Yu, T., Weinberger, K.: Simplifying graph convolutional networks. In: International Conference on Machine Learning, pp. 6861–6871. PMLR (2019) 28. Wu, Q., Shen, J., Yong, B., Wu, J., Li, F., Wang, J., Zhou, Q.: Smart fog based workflow for traffic control networks. Future Gener. Comput. Syst. 97, 825–835 (2019) 29. Xiong, L., Zhang, Z., Yao, D.: A novel real-time channel prediction algorithm in high-speed scenario using convolutional neural network. Wirel. Netw. 28(2), 621–634 (2022) 30. Yadav, R., Zhang, W., Kaiwartya, O., Song, H., Yu, S.: Energy-latency trade off for dynamic computation offloading in vehicular fog computing. IEEE Trans. Veh. Technol. 69(12), 14,198–14,211 (2020) 31. Zhang, H., Liu, Z., Hasan, S., Xu, Y.: Joint optimization strategy of heterogeneous resources in multi-MEC-server vehicular network. Wirel. Netw. 28(2), 765–778 (2022)

Discrete Planar Two-Watchtower Problem for k-Visibility Yeganeh Bahoo, Somnath Kundu, and Rudaba Syed

1 Introduction Consider a road projected in a 2D plane. The goal is to build watchtowers on top of the road such that the top of each watchtower acts as a router and sends wireless signals. Given m watchtowers, we are interested in knowing the minimum height needed for the watchtowers such that any point on the terrain receives the wireless signal from at least one of the watchtowers. Wireless signals can penetrate obstacles. The wireless signal can be simulated by the theoretical concept called k-visibility, where two points can see each other when the straight line connecting them intersects at most k obstacles. The explicit definitions are explained in Sect. 1.1. The application of studying such a theoretical concept for wireless signals is in different fields such as robotics, for tasks such as simultaneous localization and mapping where the robots are communicating through wireless signals, coverage of wireless networks considering the network densification with small cells and macrocells that are featured in 5G and 6G, or 5G short-range communication towers. This chapter is organized as follows. Section 1 talks about preliminaries, the definition of the problem, and related work. In Sect. 2, we talk about the main result of the problem and its relative algorithm and time complexity. Section 3 explains an example of the problem using the proposed algorithm. Lastly, Sect. 4 concludes the whole with ideas for future work.

Y. Bahoo () · S. Kundu · R. Syed Toronto Metropolitan University, Toronto, ON, Canada e-mail: [email protected]; [email protected]; [email protected] © The Author(s), under exclusive license to Springer Nature Switzerland AG 2024 I. Woungang, S. K. Dhurandher (eds.), The 6th International Conference on Wireless, Intelligent and Distributed Environment for Communication, Lecture Notes on Data Engineering and Communications Technologies 185, https://doi.org/10.1007/978-3-031-47126-1_5

65

66

Y. Bahoo et al.

Fig. 1 Visibility of a point

r q

p

1.1 Preliminaries A query point q is visible from p in a polygon if a ray emanating from p does not encounter any obstacles until it reaches q; see Fig. 1. Notice that the point r is not visible from p because the emanated ray intersects an edge of the polygon. In other words, the ray is encountering an obstacle. A terrain in .R2 is an x-monotone polygonal chain where the edges are line segments and the intersecting point of a pair of edges is called a vertex. X-monotonicity of a terrain indicates that, if a vertical line l passes through the terrain, then l intersects the terrain at most one point or one segment. In Fig. 2, two vertical lines ab and cd intersect the terrain at most one point and one segment, respectively. Two points p and q are said to be k-visible if the line segment pq passes through at most k edges, where .k ∈ Z+ . A watchtower is a vertical segment whose bottom endpoint lies on T . A point .w ∈ T is guarded by a watchtower if w is k-visible for the top endpoint of the watchtower. A watchtower placed on T will guard T , if each point on T is k-visible from the top endpoint of the watchtower. In Fig. 3, h is a watchtower that is placed on a vertex of the terrain that can see the surface or boundary of the terrain. The edge .e1 is .k = 2 visible from the watchtowers. When considering 2-visibility, a ray emanating from watchtower can pass through at most two obstacles and guard a point or a segment. In this chapter, we study m watchtowers guarding a terrain in .R2 , while considering k-visibility.

1.2 Problem Definition In this section, we formally define the problem and its related concepts. First, we introduce some notations.

Discrete Planar Two-Watchtower Problem for k-Visibility

67 c

v a

v

v

v e v

v

v

v

v

v

d

b

Fig. 2 An x-monotone polygonal chain v h

v

v

e

v

v

v

v

v v

v v

v

v

Fig. 3 A segment is 2-visible from the watchtower

.k ∈ Z+ denotes the given number that indicates the maximum number of obstacles through which an object can be observed. T indicates the given xmonotone terrain in .R2 . The vertices of T are indexed and ordered by the set of natural integers and are shown by .N(T ). The number of vertices is denoted by n, which follows .n := |N(T )| and .N(T ) = {1, . . . , n}. The function .X : Z+ :→ R+ indicates the horizontal position of any point from the origin. The function .Y : Z+ :→ R+ indicates the vertical position of any point from the origin. .s ⊆ N(T ) is the set of indices of points, each of which contains a watchtower. The number of watchtowers is denoted by m, which follows .m := |s|. The function .C(s) indicates the total cost of putting watchtowers on all of the vertices of s. The collection .sN indicates all the subset of vertices that can have possible watchtowers. n .sN = {s :⊆ N (T ), |s| = m}, which follows that .|sN | = m . The set of edges of T is denoted by .E(T ). It follows that .|E(T )| = n − 1. The collection .ek indicates all the subsets of .E(T ) that k number of members.  n−1have .ek := {e :⊆ E, |e| = k}, which follows that .|ek | = k .

68

Y. Bahoo et al.

The function .Vsk (T \e) indicates the k-visible region of terrain T without the set of edges .e ⊆ E(T ) from the watchtowers that are kept in the set .s ⊆ sN . Now, we mention some shortcut notations of special variations of the above definition. k Vik (T \e) := V{i} (T \e),

.

Vsk (T \ex ) := Vsk (T \{ex }),

i ∈ s. ex ∈ E(T ).

Vsk (T ) := Vsk (T \∅), Vs (T \e) := Vs0 (T \e). From this, it follows Vsk (T \e) =



.

Vik (T \e).

i∈s

With these notations, we formally define the m watchtower problem with kvisibility. Definition 1 If .∃s ∈ N(T ), such that .Vsk (T ) = T , then T is k-visible. Definition 2 An x-monotone 2D terrain T is given with n number of vertices that are indexed. We need to find a set of vertices .s ∈ N(T ), such that T is k-visible.

1.3 Related Work Sharir has introduced the watchtower problem for polyhedral terrains in 1988 [15]. Taking into account 0-visibility, while in .R3 , the minimum height of a watchtower such that it can see the whole terrain can be found in .O(n log n) time where n refers to the number of vertices of the terrain, the watchtower can be located at any point on top of the terrain [16]. Having two watchtowers, the minimum height of the highest watchtowers so that each point on the terrain is seen by at least one watchtower takes .O(n4 ) time complexity where n refers to the number of vertices of the terrain and the terrain is located on a vertical line passing through the vertices of the terrain [10]. Using parametric search, they have also proposed an approach to solve the problem when the watchtowers can be located on any point above the terrain as well as when the watchtower is located on vertical lines emanating from the vertices of the terrain. √ Boaz Ben-Moshe et al. proposed an .O(n(3/2) m (n)) algorithm for the decision version of the problem when there are two watchtowers located on vertical lines emanating from vertices of the terrain; .m (n) refers to the time needed for the matrix multiplication of two .n × n matrices [9]. Considering the fastest method to calculate the matrix multiplication, this approach results in a .O(n(2.37)+ ) time complexity

Discrete Planar Two-Watchtower Problem for k-Visibility

69

[3, 9]. Agarwal et al. also used parametric search to improve the time complexity for the optimization problem [1]. The concept of k-visibility was first introduced by Dean et al. [11] and Mouad and Shermer [14], where k was assumed to be one. Recently, in an effort to simulate wireless signals, k-visibility was used for any arbitrary k [7]. While simulating wireless signals by k-visibility, the authors have shown that given a 2D map of a building, the area that receives wireless signals from a given point can be calculated in .O(n2 ), where n refers to the number of walls in the building. Later, other researchers have improved this time complexity [4, 6]. Another problem that has been studied in this concept is calculating the minimum or maximum number of routers needed on a given 2D map of a building such that all points in the building receive signal from at least one of the routers [2, 8, 13]. Evans and Sember have also determined whether there is an area on the map where a router placed there can send a signal to all points in the building [12]. Having one watchtower, finding the minimum height for it such that all points on the terrain can receive the wireless signal was also studied [5]. It must be noted that in the above theoretical studies of kvisibility the distance from the router is not considered as a parameter for which the signal can be received. However, this parameter can be easily added to the existing approaches. Next, we describe our main results and algorithm. This follows by specific results for 2 watchtowers when considering 2-visibility. Finally, we draw the conclusion.

2 Main Result We provide an algorithm for the m watchtower problem considering k-visibility, which has .O(n(m+k) · f (n)) time complexity, when the normal visibility (.k = 0) of m watchtower problem takes the time complexity of .O(f (n)), where .f : Z+ → R+ . Based on Algorithm 1, we provide an Algorithm 2 to determine the minimum number of watch tower that is needed to make the given terrain k-visible, which has time complexity .O(n(m+k+1) · f (n)).

2.1 Algorithm Now we provide an algorithm for a fixed number of watchtowers using k-visibility on a given terrain. Before we provide the algorithm, we present a theorem that forms the backbone of the algorithm.

70

Y. Bahoo et al.

Theorem 1 Vik (T ) =



.

Vi (T \e).

e⊆E(T ), |e|=k

Proof Consider a particular .e ⊆ E(T ), such that .|e| = k. When the set of the edges e is removed from the terrain T , not all combinations of those edges would correspond to k-visibility. That means, it is possible that, from a point i, the normal visibility region of .T \e is less than the k-visibility of the T . ∀e ⊆ E(T ), |e| = k, Vi (T \e) ⊆ Vik (T ).

.

.





Vi (T \e) ⊆ Vik (T ).

e⊆E(T ), |e|=k

Now, out of all the possible combinations of .e ⊆ E(T ), |e| = k, there would be definitely some sets .e0 ⊆ {e : e ⊆ E(T ), |e| = k}, which will correspond to the k-visibility. In that case, 

∃e0 ⊆ {e : e ⊆ E(T ), |e| = k}, Vik (T ) =

.

Vi (T \ex ).

ex∈e0

Combining both, we get Vik (T ) =



.

Vi (T \e).

e⊆E(T ), |e|=k

  Theorem 2 Algorithm 1 takes the time complexity of .O nk+m · f (n) . Proof Here, the time complexity arises from the outermost for loop, which is given by

.

O

       n−1 n (n−1)! n! · · k · f (n) · · k · f (n) = O k m  k!·(n−1−k)! m!·(n−m)! = O nk+m · f (n) .

  Theorem 3 Algorithm 2 takes the time complexity of .O nk+m+1 · f (n) . Proof Here, time complexity arises from the main loop, which is given by     O n · nk+m · f (n) = O nk+m+1 · f (n) .

.

Discrete Planar Two-Watchtower Problem for k-Visibility

71

Algorithm 1: Algorithm for m watchtowers problem for k-visibility Data: T , k ∈ Z+ , m ∈ Z+ n ← |N (T )|; ek ← {e ⊆ E(T ), |e| = k};   Check : |ek | = n−1 k ; Function NegationDetection(N, ek , m): sN ← {s ⊆ N, |s| = m}; n ; Check : |sN | = m Fs ← ∅ /* All feasible solutions foreach s ∈ sN do Vs ← ∅; foreach i ∈ s do Vi ← ∅; ek,i ← ek ; foreach e ∈ ek,i do Vi ← Vi ∪ Vi (T \e) /* Here time complexity is f (n) end Vs ← Vs ∪ Vi ; if Vs = T then /* For decision version return true here Fs .Add(s); end end end if Fs = ∅ then Sort : Fs according to the C(s), ∀s ∈ Fs in ascending order.;

else

*/

*/

*/

return : Fs [0] /* The optimized solution with minimum cost */

return : null /* No solution exist end End Function

*/

VisibilityDetection(N (T ), ek , m) /* Calling the main function

*/

Next, we present an algorithm to find the minimum height of one watchtower required to make a given terrain k-visible using the above algorithm.

3 A Terrain Guarded by Two Watchtowers with 2-Visibility In this section, we explain the steps of the proposed algorithm explicitly for 2visibility when there exist 2 watchtowers. A terrain T is given with two watchtowers

72

Y. Bahoo et al.

Algorithm 2: Algorithm for minimum watch tower problem for k-visibility Data: T , k ∈ Z+ n ← |N (T )|; ek ← {e ⊆ E(T ), |e| = k};   Check : |ek | = n−1 k ; foreach m ∈ n do /* Calling the main function for all the vertices Fm ← VisibilityDetection(N (T ), ek , m); if Fm ! = ∅ then return m, Fm ; end end

*/

return : null /* No solution exists */

with a given height, h. For each watchtower placed on a vertex of the terrain, we remove all combinations of two edges from the set of edges of the terrain to make it 2-visible for the watchtower and pass the new terrain .T  in a function for visibility check. The decision problem can be solved in O(.n2.688 ), which is proposed by Boaz Ben-Moshe et al. [9]. It is confirmed from Theorem 1 that the new terrain does not necessarily resemble to 2-visibility for removing edges of all the combinations. In Fig. 4b, we can see that the edge .e8 is not 2-crossing visible from the watchtower for removing the set of edges of {.e2 , e7 }, but .e8 is visible for removing {.e6 , e7 }. Now, for removing sets of edges for some specific combinations, the terrain is somewhat visible from each watchtower. Then we combine 2-crossing visibility for both watchtowers, and if the visibility resembles to the normal visibility of the terrain, then the whole terrain for those two watchtowers is 2-crossing visible. From Theorem 2, calculating the combinations of two edges from the set of edges of the terrain with two watchtowers in polynomial time takes O (.nk ·n2 ). Calculating the visibility of the terrain takes .O 2.688 [9], resulting in a total time complexity of O(.nk+2 · n2.688 ).

4 Conclusion and Future Work In this chapter, given a height h, we have proposed a polynomial-time complexity algorithm to determine whether m watchtowers with the maximum height h can be placed on vertical lines emanating from the vertices of the terrain such that the entire terrain is k-visible from at least one watchtower. We also proposed an approach to the number of watchtowers needed to cover the whole terrain. Wireless signals not only penetrate walls but also reflect from obstacles. We are also interested in including this characteristic of wireless signals when studying this

Discrete Planar Two-Watchtower Problem for k-Visibility

v

73

v

e e

e

e

v

(a)

v

v

e e

e

v

(b)

v e

v

e

v

(c) Fig. 4 Example of a combination of edges for which a terrain is 2-crossing visible. (a) Watchtower h guarding a terrain. (b) Edge is not 2-crossing visible. (c) Edge is 2-crossing visible from watchtower

problem. Additionally, studying this problem in 3D space will be another area of improvement for this work.

74

Y. Bahoo et al.

References 1. Agarwal, P.K., et al.: Guarding a terrain by two watchtowers. Algorithmica 58(2), 352–390 (2010) 2. Aichholzer, O., et al.: Modem illumination of monotone polygons. Comput. Geom. 68, 101– 118 (2018) 3. Ambainis, A., Filmus, Y., Le Gall, F.: Fast matrix multiplication: limitations of the Coppersmith-Winograd method. In: Proceedings of the Forty-Seventh Annual ACM Symposium on Theory of Computing, pp. 585–593 (2015) 4. Bahoo, Y., Bose, P., Durocher, S.: Watchtower for k-crossing visibility. In: CCCG, pp. 203–209 (2019) 5. Bahoo, Y., et al.: A time–space trade-off for computing the k-visibility region of a point in a polygon. Theor. Comput. Sci. 789, 13–21 (2019) 6. Bahoo, Y., et al.: Computing the k-visibility region of a point in a polygon. Theory Comput. Syst. 64(7), 1292–1306 (2020) 7. Bajuelos, A.L., et al.: A hybrid metaheuristic strategy for covering with wireless devices. J. Univ. Comput. Sci. 18(14), 1906–1932 (2012) 8. Ballinger, B., et al.: Coverage with k-transmitters in the presence of obstacles. J. Combin. Optim. 25, 208–233 (2013) 9. Ben-Moshe, B., Carmi, P., Katz, M.J.: Computing all large sums-of-pairs in Rn and the discrete planar two-watchtower problem. Inf. Process. Lett. 89(3), 137–139 (2004) 10. Bespamyatnikh, S., et al.: On the planar two-watchtower problem. In: Computing and Combinatorics: 7th Annual International Conference, COCOON 2001 Guilin, China, August 20–23, 2001 Proceedings 7, pp. 121–130. Springer (2001) 11. Dean, J.A., Lingas, A., Sack, J.-R.: Recognizing polygons, or how to spy. Vis. Comput. 3, 344–355 (1988) 12. Evans, W., Sember, J.: k-star-shaped polygons, pp. 215–218 (2010) 13. Fabila-Monroy, R., Vargas, A.R., Urrutia, J.: On modem illumination problems. In: XIII encuentros de geometria computacional, Zaragoza, Spain (2009) 14. Mouawad, N., Shermer, T.: The superman problem. Vis. Comput. 10, 459–473 (1994) 15. Sharir, M.: The shortest watchtower and related problems for polyhedral terrains. Inf. Process. Lett. 29(5), 265–270 (1988) 16. Zhu, B.: Computing the shortest watchtower of a polyhedral terrain in O (nlogn) time. Comput. Geom. 8(4), 181–193 (1997)

Towards Intra-cluster Data Prediction in IoT for Efficient Energy Consumption Arouna Ndam Njoya, Innocent Emmanuel Batouri Maidadi, Ado Adamou Abba Ari, Wahabou Abdou, Sondes Khemiri Kallel, Ousmane Thiare, Abdelhak Mourad Gueroui, and Emmanuel Tonye

1 Introduction The evolution of Internet to massive connectivity over 5G and 6G has promoted the expansion of IoT system, which is essential in our daily environment [1]. IoT is a concept that consists of interconnecting several heterogeneous devices to

A. N. Njoya () · I. E. B. Maidadi Department of Computer Engineering, University Institute of Technology, University of Ngaoundéré, Ngaoundéré, Cameroon A. A. A. Ari DAVID Lab, Université Paris-Saclay, University of Versailles Saint-Quentin-en-Yvelines, Versailles, France LaRI Lab, University of Maroua, Maroua, Cameroon e-mail: [email protected] W. Abdou LIB EA7534, University Bourgogne Franche-Comté, Dijon, France e-mail: [email protected] S. K. Kallel · A. M. Gueroui DAVID Lab, Université Paris-Saclay, University of Versailles Saint-Quentin-en-Yvelines, Versailles, France e-mail: [email protected]; [email protected] O. Thiare LRI Lab, Gaston Berger University of Saint-Louis, Saint-Louis, Senegal e-mail: [email protected] E. Tonye Department of Electrical Engineering and Telecommunications, National Advanced School of Engineering of Yaoundé, University of Yaoundé 1, Yaoundé, Cameroon © The Author(s), under exclusive license to Springer Nature Switzerland AG 2024 I. Woungang, S. K. Dhurandher (eds.), The 6th International Conference on Wireless, Intelligent and Distributed Environment for Communication, Lecture Notes on Data Engineering and Communications Technologies 185, https://doi.org/10.1007/978-3-031-47126-1_6

75

76

A. N. Njoya et al.

a global network and being able to exchange information [2]. In such network, each device has an identification and integrates multiple communication protocols. There are several IoT architectures. The most common are the 3 and 5 layers architectures. According to [3], all of them are equivalent. If we refer to the 5 layers architecture, we find in an IoT system: the perception layer that contains various sensors responsible for data collection; the network layer that ensures data transfer through various wireless technologies such as Bluetooth, WiFi, LR-WPAN, 3G, 4G, and 5G; the middleware layer, which may include Cloud and Fog components; the applications layer that offers a management space for user applications, and the business layer that allows the analysis of data through cloud [4]. IoT nodes are known to be one of the most commonly used devices for data collection in various sectors such as health monitoring, agriculture, climate change, and so on [5–10]. There is no doubt that the wide range of applications of IoTs, which are growing significantly every single day, shows that they are fundamental for the future smart environment as illustrated in Fig. 1. However, IoTs suffer from batteries drain when they are constantly used in a long time. It is therefore necessary, in view of the quantity of data captured by IoT nodes, to find an energy-efficient way to control the traffic during information transmission. Energy prediction is one of the mechanisms used to reduce energy consumption in wireless sensor networks (WSNs) and thus in IoT nodes [11]. Many studies have been carried out to perform energy prediction in WSN. Most of the works investigate how the acquisition network is organized in order to collect, process, and transmit data to the base station. The proposed approaches deal, on the one hand, with data aggregation so as to reduce redundancies and eliminate useless data and, on the other hand, with sensor node clustering to avoid each node sending data across a very long distance [12, 13]. We also find schemes based on network organization in cells, grids, following the density and by hierarchy [14–17]. Data prediction in WSNs refers to the practice of applying statistics and machine learning algorithms to identify trends in current and past data to predict future data [11]. To accomplish this task, some proposed strategies perform prediction at the source node level. In this case, the source node has a memory that allows it to compare captured data with current data in its buffer in order to decide what information to transfer. Other methods carry out predictions at the CH level when the network is organized in clusters. The CH has to filter the potential data that can be transmitted by its members and only retain the relevant ones. It is important to notice that combining the two prediction techniques in the same approach is often common. Although there are numerous methods for energy reduction in IoT networks, we believe that little interest has been focused on intra-clusters data prediction. Even if there are initiatives in this direction, it is clear that most of the proposed methods are complex to implement or require IoT nodes to have a fairly large memory space for data analysis before transmission. Yet memory is indeed what the nodes do not have enough. In this chapter, we assume that data inside a cluster must have a correlation. We therefore suppose that dense clusters can satisfy this assumption. Thus, we propose

Towards Intra-cluster Data Prediction in IoT

77

Fig. 1 IoT ecosystem

a hybrid approach based on DBSCAN algorithm, in which properties support cluster density and favour the elimination of isolated nodes that are considered as noises. To ensure minimal communication between the CH and its members, we propose a linear regression prediction model that is able to predict the future data of a member. This helps to limit excessive memory usage, even if it may lead to energy costs during the forecast process. For this reason, we are putting forward an energy computation model while performing prediction operations. This chapter is structured as follows. Approaches for energy reduction through prediction and clustering are presented in Sect. 2. The models behind our considerations are described in Sect. 3. Simulations and analysis of the results are the subject of Sect. 4. Finally, in Sect. 5, we conclude our study by mentioning some future directions.

2 Related Work As mentioned previously, data prediction can be useful in decreasing energy consumption costs in IoT networks. We have mentioned the strong link among prediction, clustering, and data aggregation. In this section, we present relevant studies that have contributed to address these issues. Data aggregation is the process of grouping data in such a way as to filter and remove redundancies in order to keep only useful information. In order to

78

A. N. Njoya et al.

reduce energy consumption and improve the computing capacity of nodes, it was proposed in [18–22], predictive models based on extended cosine regression (ECR), a collision-free distributed data aggregation scheme (DCF-DAS), and a Q-LEARNING algorithm for data aggregation. The developed methods reduce duplicate data transmission while improving data quality and network life. The performances of the proposed techniques were compared with those of the P-DPA and OSSLMS techniques for one and the IAS and SA approaches for the other and presented satisfactory results. Binary trees are used in [23–25] to minimize the quantity of data transmitted and thus improve the life of the network. The methods rely on the detection of data transmission errors and channel allocation that prevents coalescence between packets. Likewise, data prediction is used in [26, 27] to eliminate redundancies and data failures during transmission. The machine learning algorithms that are used in this direction are 1-D CNN, Bi-LSTM, LSTM hybrid, and AdaBoost. Despite these approaches, other studies focus on clustering mechanisms. Clustering is a strategy to divide data and nodes into subgroups in order to limit long-distance transmissions and keep similar data in the same group. Clustering methods can be classified into four categories: hierarchical clustering, partitionbased clustering, cell-based clustering, and density-based clustering. Many studies for efficient energy consumption under various situations have been carried out in [14, 16, 17, 28–30]. The strategies proposed include fuzzy logic, LEACH algorithm, homomorphic encryption algorithm, local tree reconstruction algorithm (DA- LTRA), and lightweight integrity protection-oriented data aggregation scheme (LIPDA).

3 Energy Prediction Model for Data Aggregation 3.1 Problem Statement In WSN, the energy consumption problem can be defined as follows. Let s1 , s2 , . . . , sn be n sensors with the communication radius R. These static sensors are placed randomly as shown in Fig. 2. The objective is to group the nodes into K clusters and then perform a prediction of data in order to avoid redundant transmission so as to extend the network lifetime. The prediction is applied to each cluster. In each cycle, a single node is selected as cluster head .(CH ). The CH is in charge to transfer data from his members to the base station (BS).

.

3.2 Network Model The network is a graph constituted by n sensors .s1 , s2 , . . . , sn with a base station BS located in a given area. Each node has latitude and longitude position in a plan. To communicate, a node uses his communication radius R. Communication

Towards Intra-cluster Data Prediction in IoT

79

Fig. 2 Network model

is restricted to the cluster where the node is assigned. The CH is responsible for the transmission to the base station. A base station (BS) is randomly placed in the network and acts as the final receiver of all transmissions from CHs.

3.3 Prediction and Data Transmission Approach In order to guarantee communication within the network and to extend its lifetime, we have thought of setting up a certain number of procedures. These procedures are divided into 3 steps that are the clusters formation, the election of the cluster head, and the prediction of the data to be sent as shown in Fig. 3: ● Cluster Formation: For the formation of clusters, we use the DBSCAN algorithm that is a density clustering algorithm with the consideration of noise. ● Election of the Cluster Head: The selection of the cluster head is done according to 3 main criteria that are: – Residual energy: It is a question of seeing which node has the greatest amount of energy. – Proximity: Here it is a question of measuring the proximity of the node to the base station. – Choice: Priority should be given to nodes that have not yet been selected.

80

A. N. Njoya et al.

Fig. 3 Implementation steps of the proposed model

● Predicting the data to be sent: In order to extend the lifetime of the network, we want to minimize the amount of data that will be sent to the base station. To do this, the multivariate linear regression algorithm is used. In Fig. 3, we present an overview of our approach.

3.3.1

Cluster Formation

Here the clusters are created according to the density zones of the sensor nodes. And the clustering is done according to the high-density areas. The leading method in this category is called density-based spatial clustering of applications with noise, DBSCAN [29]. In addition to forming classes of nodes, the algorithm also identifies the outlier values that are referred to as noise. It takes two parameters as input: .ϵ the maximum distance that can define two nodes as neighbours, and N the minimum number of nodes needed to form a cluster. The DBSCAN algorithm is organized as follows: For a dataset X containing N nodes, DBSCAN is a density-based clustering mechanism that defines a local density called .density(xi ) in the neighbourhood of the i-th node .xi ∈ X as the number of nodes in its neighbourhood: .density(xi ) = ni=1 Nϵ (xi ) refers to the neighbouring nodes in the neighbourhood of a radius .ϵ.

3.3.2

Election of the Cluster Head

As introduced above, the election of the cluster header is done according to the three criteria that are its proximity to the base station, the residual energy as well as the fact that the node has been chosen or not. In order to make the election, we must first retrieve and group the nodes according to all the clusters that have been formed and then check whether a node is still alive. For a node, being alive means that it still has the energy to process and transmit the necessary data. At the node level, there is an alive property to designate

Towards Intra-cluster Data Prediction in IoT

81

whether a node is still alive or not. For instance, if the energy needed to make the transfer is .Et and the residual energy (energy remaining at the cluster level) is .Er , then the values that alive can contain are  1, Er ≥ Et .alive = . (1) 0, Er < Et If no node exists that is able to do this  transmission, the cluster is considered dead, i.e., if we have k nodes in the cluster, . ki=1 Eri = 0. When these cases occur, we move to another cluster. If there are any surviving nodes capable of performing the requested processing and transmission, they are taken over following a wellestablished process as described in Figs. 5 and 6.

3.3.3

Predicting the Data to Be Sent

To perform this operation, we use the MLR. Multiple linear regression is a type of linear regression when the input has multiple features (variables). Similar to simple linear regression, we have input variable (X) and output variable (Y). But the input variable has n features. Therefore, we can represent this linear model as follows: Y = β0 + β1 x1 + β1 x2 + . . . + βn xn .

.

(2)

xi is the ith feature in input variable by introducing .x0 = 1. This equation to matrix form can be represented as follows:

.

Y = β T X.

(3)

.

3.3.4

Energy Model

To ensure simplicity in data transmission as described in [31], we assume that each node has the same coverage radius .Rs , and thus the probability for a sensor node to detect an event that is in its neighbourhood is given by the following formula: P (d) =

 1,

.

0,

if d ≤ Rs otherwise.

.

(4)

Each sensor node has an initial energy capacity that is .E0 . The base station has an unlimited amount of energy. When transmitting l bits over a distance d, the energy consumption is given by the following formula:

82

A. N. Njoya et al.

Fig. 4 Communication in a flat network

 RT x(l, d) =

.

leelec + lϵf s d 2 ,

d < d0

leelec + lϵamp

d ≥ d0

d 4,

(5)

and ERx (l) = leelec .

.

3.3.5

(6)

Intra-cluster Prediction

Data transfer varies depending on the type of network that is being used. For example, in a flat network as described in Fig. 4, all the nodes in the network can send the captured information to the base station. This does not improve the lifetime of the network in the fact that there will be an imbalance and the most distant nodes will inevitably discharge faster than those closest to the base station. To improve the network imbalance problem, it is possible to form clusters and elect a cluster head. This head is responsible for retrieving the information collected by the nodes that are in the same cluster as it and transmitting it to the base station. As described in Fig. 5, the energy consumption in the network is balanced because the nodes in the cluster will have balanced energies over the iterations. Despite the fact that the energy is balanced in the cluster, this improves the energy management, but it is still not optimal. In order to optimize the intra-cluster energy consumption, a prediction of the data to be sent has been implemented as explained in Fig. 6. As shown in Fig. 6 at each iteration, only the energy of the cluster head is consumed. In this chapter, we perform an intra-cluster prediction, which means that before any prediction operation, we first proceed to the formation of the different clusters. Once these clusters are formed, we proceed to the prediction. This means that if we have a set of n nodes and we divide these nodes into k clusters, each cluster will contain a set of .nk nodes. The prediction is therefore applied to the data collected by each .nk node. For instance, in Fig. 7, we have two clusters, the first with 5 nodes and the second with 12 nodes. At each iteration, the header cluster is elected, and

Towards Intra-cluster Data Prediction in IoT

83

Fig. 5 Communication in a clustered network with CH election

Fig. 6 Communication in a clustered network with data prediction

it is responsible for predicting the data that the other cluster nodes are supposed to send to the base station. The intra-cluster prediction consists of identifying the CH and applying to that CH the MLR algorithm. As prediction is an operation that involves energy consumption, .Ep described in Eq. 7 is used for this purpose. Ep = leelec ∗ γ ,

.

(7)

where l is the number of bits sent, .eele the quantity of energy necessary for the reception of a given packet, and .γ the prediction coefficient of each sensor node.

84

A. N. Njoya et al.

Fig. 7 Intra-cluster prediction Table 1 Training result of the cluster model Cluster Nodes Data items RMSE Accuracy

Cluster 1 25 808,208 2.2787 99.928

Cluster 2 19 408,780 2.0281 99.927

Cluster 3 3 76,369 2.3206 99.921

Cluster 4 2 70,536 2.2922 99.924

Cluster 5 3 127,748 2.3723 99.919

4 Experimental Results In this section, some experimental results of the proposed approach are presented. Table 2 provides the parameters used in the simulations. .ϵ and minP ts define, respectively, the communication radius between the sensors and the minimum number of points in a cluster. For the data transfer, the energy spent corresponds to .eelec , and for the reception of the sent data, the amount of energy consumed is .ϵamp . For each node of the network, we have nBits sent. This corresponds to the number of data bits captured. The data used for the prediction represent the actual data from 54 sensors placed in the Intel laboratory in the period from 28 February to 5 April 2004. At the beginning, we had 2.3 million data to handle, but after processing them, we ended up with a set of 1,588,398 data. Later these data were divided into clusters that we formed using DBSCAN, and we applied to each cluster a regression model that trained on these data. After the training, we performed an intra-cluster prediction. The training results are shown in Table 1. For training and testing, we divided the data of each cluster into two parts. The training part occupies 80% of the data, while the other 20% are for the test values. After the different trainings, we are satisfied with the reliability of the prediction and the accuracy of our model (Table 2).

Towards Intra-cluster Data Prediction in IoT

85

Table 2 Simulation parameters Parameter .ϵ .eelec .ϵamp

Number of nodes nBits

Value m −8 .510 J/bit −15 J/bit/.m4 .1.3 × 10 54 5000 .0.38

Parameter minP ts .ϵf s Base station position Number of iterations .γ

Value 2 −11 J/bit/.m2 .10 Latitude: 20, longitude: 15 10,000 0.2

Fig. 8 The number of remaining nodes per iteration

In order to evaluate the relevance of the approach, we define 54 nodes arbitrarily distributed in a matrix, we proceed to 10,000 iterations, and we present the number of nodes surviving each time.

4.1 Comparative Analysis This part consists in presenting the results we obtained from the different simulations we carried out. Figure 8 represents the evolution of the number of nodes alive in the network as we move through the iterations. The simple observation we can make at this level is that the evolution is done in cascade and that when we reach 6700 iterations there is no more energy in the network. This means that the network is dead at that point.

86

A. N. Njoya et al.

Fig. 9 The number of nodes alive after each iteration compared to K-means and DBSCAN

In the second part, we present the number of nodes surviving at each iteration we perform. From the observations made in Fig. 8, we found that before 6500 iterations all nodes remain alive, but as soon as we cross this threshold, the number of surviving nodes decreases drastically and ends completely. From the observation we make, we notice that the structure of our graph describes a staircase. This is due to the fact that in our model, the election of the cluster head is done according to 3 criteria that are the residual energy, the proximity with the base station, and the history of choices. These criteria allow to balance the energy in the whole cluster because at each iteration, there is a new election. Consequently, when a certain energy balance is reached, no node in the cluster can transmit because the residual energy does not allow it. As a side effect, all the nodes of the cluster are considered as dead, and it automatically decreases the quantity of remaining nodes by eliminating them from the list of living nodes. We compared our model to the K-means method with simple data routing and to the DBSCAN method with simple data routing. We found that the proposed model outperformed the other methods in energy conservation. Figure 9 allows a more visual representation of the results obtained. The advantage of our model compared to the others is that we integrate the prediction when the data are sent to the base station by the cluster head. This allows us to conserve the energy of sending data from each node to the cluster head and the energy of receiving data from the different packets sent to the cluster head. Thus the only energy that is applied is that of the prediction, which is much less significant than the others.

Towards Intra-cluster Data Prediction in IoT

87

Fig. 10 The number of nodes alive after each iteration compared to K-means, DBSCAN, and LEACH

We then compared the proposed model with the LEACH method, and the results obtained are also satisfactory because our model obtained a better score. Figure 10 demonstrates these results. The fundamental difference of our model with respect to LEACH is in the election of the cluster head. This election is done on the basis of multiple variables. These variables favour the balanced distribution of the election of each node. This encircles the balance of the average energy in the cluster.

5 Conclusion Energy consumption optimization remains a major challenge in the context of IoTs, given the large volume of data they drain. To address this concern, it is necessary to develop intelligent approaches to handling the data generated by IoTs. This chapter proposes a hybrid approach to extend the lifetime of IoTs. The proposed approach combines the DBSCAN clustering algorithm and the MLR multiple linear regression algorithm. The DBSCAN algorithm considers a distribution of IoT nodes over a given area and produces clusters containing a cluster leader responsible for transmitting data from its members to the base station. As for MLR, it predicts data from members of the same group. This model was designed to minimize the energy consumption of the sensors, since prediction makes it possible to limit the amount of data to be sent by the source nodes. The results of this chapter showed that the

88

A. N. Njoya et al.

proposed model could significantly reduce the energy consumption of the network while guaranteeing satisfactory quality of transmitted data. In our future work, we plan to explore the use of time series to reduce the data transmitted in the network. Acknowledgments We would like to thank the editor and the anonymous reviewers for their valuable remarks that helped us in better improving the content and presentation of the paper. Moreover, the author is grateful for the facilities provided by the DAVID Labs UPSay-UVSQ and its kind hospitality.

Conflict of Interest Statement On behalf of all authors, the corresponding author states that there is no conflict of interest.

References 1. Ari, A.A.A., Gueroui, A., Titouna, C., Thiare, O., Aliouat, Z.: Resource allocation scheme for 5G C-RAN: a swarm intelligence based approach. Comput. Networks 165, 106957 (2019) 2. Ndam, N.A., Yefou, U.N., Ari, A.A.A., Rockeeller, Djedouboum, A.C., Abdou, W., Thiare, O.: Reinforcement learning-based dynamic path allocation in IoT systems. In: Ngatched, T.M.N., Woungang, I., Tapamo, J.R., Viriri, S. (eds.) Pan-African Artificial Intelligence and Smart Systems. PAAISS 2022. Lecture Notes of the Institute for Computer Sciences, Social Informatics and Telecommunications Engineering, vol. 459, pp. 19–38. Springer, Cham (2023) 3. Kassab, W., Darabkh, K.A.: A–Z survey of Internet of Things: Architectures, protocols, applications, recent advances, future directions and recommendations. J. Network Comput. Appl. 163. http://doi.org/10.1016/j.jnca.2020.102663 4. Mahmud, R., Kotagiri, R., Buyya, R.: Fog Computing: A Taxonomy, Survey and Future Directions, vol. 0. Springer International Publishing (2018). http://doi.org/10.1007/978-98110-5861-5_5 5. Saha, H.N., Auddy, S., Chatterjee, A., Pal, S., Pandey, S., Singh, R., Singh, R., Sharan, P., Banerjee, S., Ghosh, D., et al.: Pollution control using internet of things (IoT). In: 2017 8th Annual Industrial Automation and Electromechanical Engineering Conference (IEMECON). pp. 65–68. IEEE (2017) 6. Jaiganesh, S., Gunaseelan, K., Ellappan, V.: IOT agriculture to improve food and farming technology. In: 2017 Conference on Emerging Devices and Smart Systems (ICEDSS), pp. 260–266. IEEE (2017) 7. Davcev, D., Mitreski, K., Trajkovic, S., Nikolovski, V., Koteli, N.: IoT agriculture system based on LoRaWAN. In: 2018 14th IEEE International Workshop on Factory Communication Systems (WFCS), pp. 1–4. IEEE (2018) 8. Mishra, S.S., Rasool, A.: IoT health care monitoring and tracking: A survey. In: 2019 3rd International Conference on Trends in Electronics and Informatics (ICOEI), pp. 1052–1057. IEEE (2019) 9. Kandris, D., Nakas, C., Vomvas, D., Koulouras, G.: Applications of wireless sensor networks: an up-to-date survey. Appl. Syst. Innovat. 3(1), 14 (2020) 10. Laghari, A.A., Wu, K., Laghari, R.A., Ali, M., Khan, A.A.: A review and state of art of Internet of Things (IoT). Arch. Comput. Methods Eng. 29(3), 1395–1413 (2022). http://doi.org/10. 1007/s11831-021-09622-6 11. Njoya, A.N., Tchangmena, A.A.N., Ari, A.A.A., Gueroui, A., Thron, C., Mpinda, B.N., Thiare, O., Tonye, E.: Data prediction based encoder-decoder learning in wireless sensor networks. IEEE Access 10, 109340–109356 (2022). http://doi.org/10.1109/ACCESS.2022.3213671

Towards Intra-cluster Data Prediction in IoT

89

12. Sirsikar, S., Anavatti, S.: Issues of Data Aggregation Methods in Wireless Sensor Network: A Survey, vol. 49, pp. 194–201. Elsevier B.V. (2015). http://doi.org/10.1016/j.procs.2015.04.244 13. Choudhari, M.R., Rote, U.: Data Aggregation Approaches in WSNs. Institute of Electrical and Electronics Engineers Inc. (2021). http://doi.org/10.1109/ICCCI50826.2021.9402430 14. Balakrishna, S., Thirumaran, M., Padmanaban, R., Solanki, V.K.: An efficient incremental clustering based improved k-medoids for IoT multivariate data cluster analysis. Peer-to-Peer Networking Appl. 13(4), 1152–1175 (2020) 15. Balakrishna, S.: Multi objective-based incremental clustering by fast search technique for dynamically creating and updating clusters in large data. Cluster Comput. 25(2), 1441–1457 (2022) 16. Njoya, A.N., Thron, C., Awa, M.N., Ari, A.A.A., Gueroui, A.M.: Power-saving system designs for hexagonal cell based wireless sensor networks with directional transmission. J. King Saud Univ. Comput. Inf. Sci. 34(10, Part A), 7911–7919 (2022). https://doi.org/10.1016/j.jksuci. 2022.07.008. https://www.sciencedirect.com/science/article/pii/S131915782200235X 17. Njoya, A.N., Thron, C., Awa, M.N., Ari, A.A.A., Gueroui, A.M.: Lifetime optimization of dense wireless sensor networks using continuous ring-sector model. Future Gener. Comput. Syst. 129, 212–224 (2022). https://doi.org/10.1016/j.future.2021.11.024. https://www. sciencedirect.com/science/article/pii/S0167739X21004684 18. Jain, K., Kumar, A.: An energy-efficient prediction model for data aggregation in sensor network. J. Ambient Intell. Human. Comput. 11(11), 5205–5216 (2020) 19. Qin, D., Zhang, Y., Ma, J., Ji, P., Feng, P.: A distributed collision-free data aggregation scheme for wireless sensor network. Int. J. Distrib. Sensor Networks 14(8), 1550147718795847 (2018) 20. Yun, W.-K., Yoo, S.-J.: Q-learning-based data-aggregation-aware energy-efficient routing protocol for wireless sensor networks, IEEE Access 9, 10737–10750 (2021) 21. Zhao, X., Zhu, J., Liang, X., Jiang, S., Chen, Q.: Lightweight and integrity-protecting oriented data aggregation scheme for wireless sensor networks. IET Inf. Secur. 11(2), 82–88 (2017) 22. Song, H., Sui, S., Han, Q., Zhang, H., Yang, Z.: Autoregressive integrated moving average model–based secure data aggregation for wireless sensor networks. Int. J. Distrib. Sensor Networks 16(3), 1550147720912958 (2020) 23. Hasheminejad, E., Barati, H.: A reliable tree-based data aggregation method in wireless sensor networks. Peer-to-Peer Networking Appl. 14(2), 873–887 (2021) 24. Zhou, X., Li, Y., He, D., Zhang, C., Ji, X.: Energy-efficient channel allocation based data aggregation for intertidal wireless sensor networks. IEEE Sensors J. 21(15), 17386–17394 (2021) 25. Chythanya, K.R., Kumar, K.S., Yadav, B.P., Madhuri, P., Mothe, R.: Routing and data aggregation in wireless sensor networks by using clusters. In: IOP Conference Series: Materials Science and Engineering, vol. 981, p. 022051. IOP Publishing (2020) 26. Cheng, H., Xie, Z., Shi, Y., Xiong, N.: Multi-step data prediction in wireless sensor networks based on one-dimensional CNN and bidirectional LSTM. IEEE Access 7, 117883–117896 (2019) 27. Amutha, R., Sivasankari, G., Venugopal, K.: A prediction model for effective data aggregation materials and fault node classification in WSN. Mater. Today Proc. 49, 2962–2967 (2022) 28. Gbadoubissa, J.E.Z., Ari, A.A.A., Gueroui, A.M.: Efficient k-means based clustering scheme for mobile networks cell sites management. J. King Saud Univ. Comput. Inf. Sci. 32(9), 1063– 1070 (2020) 29. Tran, T.N., Drab, K., Daszykowski, M.: Revised DBSCAN algorithm to cluster data with dense adjacent clusters. Chemomet. Intell. Lab. Syst. 120, 92–96 (2013). http://doi.org/10.1016/j. chemolab.2012.11.006 30. Bhushan, S., Kumar, M., Kumar, P., Stephan, T., Shankar, A., Liu, P.: FAJIT: a fuzzy-based data aggregation technique for energy efficiency in wireless sensor network. Complex Intell. Syst. 7(2), 997–1007 (2021) 31. Liu, X.: A deployment strategy for multiple types of requirements in wireless sensor networks. IEEE Trans. Cybern. 45, 2364–2376 (2015). http://doi.org/10.1109/TCYB.2015.2443062

Location-Based Clustering Approach for Next-Hop Selection in Opportunistic Networks Amit Dutta, Satya Jyoti Borah, and Jagdeep Singh

1 Introduction Opportunistic network (OppNet) [1] is a type of network that has developed as a result of recent advancements in wireless technologies—WiMAX [2], Bluetooth [3] and several other short-range radio communication technologies [4]. OppNet is made to function in such environments with high latency, high error rates, sporadic connectivity and lack of end-to-end routes between the source and destination, such as battlegrounds [5], deep space exploration [5] and underwater communications [5], among others. An ad hoc network [6] is a decentralized type of wireless network that is set up temporarily for the data transmission purpose. However, due to the mobility of the nodes within the network, determining the proper location of the nodes becomes a challenging task. This led to the development of Mobile Ad hoc Networks (MANET) [7]. Due to the highly movable nature of the nodes, there occurs frequent disruption of the links between nodes, and as a result, an end-to-end path between source and destination cannot be established. In order to address these issues, OppNets have been developed. In OppNets, the wireless nodes opportunistically communicate among one another in “Store-Carry-Forward” [8] method with the help of inbuilt communication medium. This happens when they interact with one another without any suitable network architecture.

A. Dutta · S. J. Borah Department of Computer Science and Engineering, NERIST, Itanagar, India J. Singh () Department of Computer Science and Engineering, Sant Longowal Institute of Engineering and Technology, Longowal, India © The Author(s), under exclusive license to Springer Nature Switzerland AG 2024 I. Woungang, S. K. Dhurandher (eds.), The 6th International Conference on Wireless, Intelligent and Distributed Environment for Communication, Lecture Notes on Data Engineering and Communications Technologies 185, https://doi.org/10.1007/978-3-031-47126-1_7

91

92

A. Dutta et al.

The major challenges in designing routing protocols for OppNets unlike traditional networks is that, in OppNets, there do not exist any standard network topology. The connections between the nodes are intermittent, occurring at irregular intervals, and are not constant; as a result, a dynamic connection is established between the nodes. In this work, a novel routing protocol, location-based clustering approach for next-hop selection in opportunistic networks (LBC), is proposed. The basic motivation behind the development of this model is the human interaction pattern. It is generally observed that human beings flock together at some specific locations and visit those locations almost regularly. These locations are termed as cluster points. The proposed model initially identifies all those cluster points from the network. During message forwarding, the cluster of the destination node is determined, and the message is forwarded from the source based on some threshold. In order to route packets in OppNets, several researchers have proposed several routing techniques based on flooding approach [9] and context approach [9], each having their own pros and cons. In the flooding-based approach, each node in a network forwards data packet to all its neighbouring nodes, thus increasing the nodes’ message delivery probability. This however results in an increase in resource consumption of the network and increases network overhead. On the other hand, in context-based approach, a node forwards a message to another neighbouring node based on a specific context such as encounter, distance, social interaction, direction of movement, etc., but this approach delays message delivery probability due to manipulation of node context. The proposed protocol follows the context-based approach. The remaining sections of this chapter are arranged as follows: Section 2 provides an overview of some OppNet routing protocols. Section 3 explains thoroughly the proposed LBC routing protocol. Simulation using ONE Simulator and evaluation of the model is discussed in Sect. 4. Finally, Section 5 concludes the chapter.

2 Related Works Routing protocols in OppNets generally follow the “Store-Carry-Forward” [8] technique, since there is no definite end-to-end connection between the source and destination nodes. In this technique, the nodes store the messages with them until they find any other suitable node within their communication range and successfully take the message closer to the destination. In literature, several routing protocols [9] for OppNets have been proposed over the years. Here is a glimpse of some of the protocols. In [10], Vahdat et al. proposed Epidemic routing protocol for opportunistic networks. It is a flooding-based technique in which a message is replicated in the network. Whenever one node comes within the contact of the other node, the first node sends a summary vector to the second node. The packets it has in its buffer are uniquely identified by the data in its summary vector. Similar to the first node, the

Location-Based Clustering Approach for Next-Hop Selection in Opportunistic. . .

93

second node also transfers those packets to the first node, which is not available with the first node. Messages are thus transmitted in both directions. As a result, all the packets are finally distributed to every node within the network and eventually reach the destination as early as possible with very high delivery probability. However, it increases the resource consumption and also creates a lot of congestion as there are several copies of the same message in the network. The Prophet (Probabilistic Routing Protocol using History of Encounters and Transitivity) routing protocol proposed by Lindgren et al. [11] is based on the concept that the likelihood of a node returning to the same area is higher if it has previously visited it multiple times. Before sending data packets, this protocol creates “probabilistic metric” called “delivery predictability.” This message delivery predictability measures the likelihood that a node will be able to send a message to its intended recipient. For instance, if two nodes, P and Q, come into contact, node P will only send the packet to node Q if and only if node Q’s message delivery predictability is higher than node P’s. Dhurander et al. in [12] proposed the ProWait routing protocol, which is a hybrid protocol that combines the advantages of Spray and Wait [13] and Prophet [11] protocol. It follows a two-step message forwarding mechanism. A packet is only transmitted to the other node whenever two nodes come into contact and the delivery predictability of the packet’s destination is higher at that node. The criteria set out by Prophet [11] are used to calculate this delivery predictability. The data packets are then distributed to the selected neighbour nodes using the Spray and Wait [13] routing technique. It thus reduces the flooding in the network. Dhurandher et al. [14] have proposed another routing protocol, History-Based Prediction for Routing (HBPR), which analyses node movement history to ascertain its distance in respect of the destination. This protocol operates in three phases: In the first phase, the Home Location is initialized. Whenever the network becomes functional, the nodes broadcast their frequently visited locations. Thus, utilizing a node’s historical position data, it is possible to forecast its future location quite accurately. In the second phase, two activities are performed—generating new messages by some nodes and updating the Home Location table. Each node needs to maintain its own history. Within a fixed interval of time, referred to as refresh period, the nodes rescan history to determine the home location cell. Finally, in the third phase, the next hop is decided by calculating a “Utility Metric,” which is composed of three parameters, viz. node movement stability, prediction of future movement direction using Markov predictors and the perpendicular distance of the neighbouring nodes from the line of sight of source and destination. It is observed that HBPR controls flooding to several extents and performs much better in case of human mobility pattern thus improving the message delivery rate and the overhead ratio. However, in cases where all the neighbour nodes have a utility metric value higher than that of the source node, a flood-like situation is created, which eventually increases the message dropping rate. A routing protocol named as Encounter and Distance-based Routing (EDR) protocol was proposed by Dhurandher et al. in [15]. This protocol depends on two variables, viz. the frequency of encounters and the distance between a node and the

94

A. Dutta et al.

target node. The ratio of these two values is then calculated to determine which node is to be selected as the next node for packet forwarding. This selection is done based on a threshold value. It ensures minimum number of messages dropped, minimum hop count and minimum delay as compared to HBPR [14] and ProWait [12]. However, HBPR and ProWait dominate EDR in respect of delivery probability and overhead ratio. In [16], Borah et al. proposed the EBC protocol, which is an Encounter, Buffer and Contact duration-based routing protocol. It is based on three parameters—the frequency of encounters among the nodes, contact duration among the nodes and buffer space of nodes. Another parameter called the “best forwarding parameter” is obtained by multiplying these three parameters. Those nodes having the value of “best forwarding parameter” more than or the same as the predefined threshold value are considered for data forwarding. This protocol ensures superiority over HBPR and Epidemic routing protocol in respect of average latency, hop count and buffer time average. However, this protocol is unable to perform better in case of messages dropped, message delivery probability and overhead ratio.

3 System Model The proposed LBC, “Location-Based Clustering Approach for Next-Hop Selection in Opportunistic Networks”, initially creates several cluster points based on the X-Y coordinate of node in the network where nodes generally gather. Considering there are N mobile nodes in the network, which are assumed to have sufficient buffer space, cooperate with each other and equally participate in packet forwarding and no malicious intentions. Since nodes are mobile in nature, they frequently encounter each other at different locations. Prior to transmitting messages, the proposed work creates cluster points in the network. These cluster points are the locations where nodes generally gather for some time interval measured in terms of X-Y coordinate (Tables 1 and 2). Table 1 Notations used and their meaning Notations N S D dAB mAB dt N nc dc

Meaning Total number of mobile nodes in the network Source node Destination node Distance between nodes A and B, having coordinates- A(ax , ay ), B(bx , by ) Mean value of coordinates- A(ax , ay ), B(bx , by ) Distance threshold Neighbour node Cluster to which the neighbour node, n belongs to or is the nearest Cluster to which the destination node, D belongs to or is the nearest

Location-Based Clustering Approach for Next-Hop Selection in Opportunistic. . .

95

Table 2 Hashmaps used in the proposed model Hashmaps Clusters

Uses To store all the clusters, also called significant points in the form of 2D-coordinate distDestCluster To store the Euclidean distance of the destination’s cluster from all the cluster points that are stored in the “clusters” hashmap

3.1 Methods Used and Their Roles • calcDistance(): It takes XY-coordinate as location of two nodes that reside in a particular location at a particular time and return the Euclidean distance using Eq. (1). 

2  (ax − bx ) + ay − by 2

.

 (1)

where A(ax , ay ), B(bx , by ) are XY-coordinates of nodes A and B, respectively. • calcMean(): It takes XY-coordinate as location of two nodes that reside in that location at a particular time and return the mean values among them using Eq. (2).  .

  (ax + bx ) ay + by , 2 2

(2)

where A(ax , ay ), B(bx , by ) are XY-coordinates of nodes A and B, respectively. • calcAverageDistance(): It returns the average of all the distances stored in the hashmap distDestCluster, which is calculated as follows: for d in distDestCluster sum = sum + d average = sum /sizeof(distDestCluster) return(average) The working mechanism of the proposed model is basically divided in two phases, viz.: (i) Cluster point identification (ii) Message transmission Phase I: Cluster Point Identification In this phase, the cluster points are identified and stored in the hashmap clusters. Whenever any node A at location (ax , ay ) encounters any other node B, which is at location (bx , by ), the distance, dAB , between them is calculated by calling the function calcDistance() as

96

A. Dutta et al.

dAB = calcDistance (A, B)

.

(3)

Then the schema compares the calculated distance, dAB , with prescribed distance threshold, dt . If the value of dAB is less than dt , the mean distance of A and B, mAB , is calculated by calling the calcMean() function as follows: mAB = calcMean (A, B)

.

(4)

Initially, this mAB is stored in the hashmap clusters. However, if clusters hashmap already contains some cluster points, then distance of mAB is calculated from all these points by calling calcDistance() function. Those cluster point for which the distance ≤dt , the mean of these two values are calculated which replaces the existing cluster point in the hashmap. Otherwise, mAB is appended to the hashmap. Phase II: Message Transmission Whenever S encounters any neighbour node n, it determines the cluster to which n belongs. It undergoes the following steps: For each neighbour node n: (a) The cluster of the destination, dc , is identified. (b) The calcDistance() function is called to calculate distance between dc and all the other cluster points. All these distances are stored in another hashmap distDestCluster. (c) Now, the cluster nc , to which the neighbour node belongs or is nearest to, is identified. (d) Finally, the message will be forwarded to n only if the distance between dc and nc is less than the average of all the distances stored in distDestCluster hashmap. In other words, n will be considered as the next best forwarding node if calcDistance (nc , dc ) < calcAverageDistance(distDestCluster)

.

(5)

The algorithm for the proposed model is stated in Algorithm 1.

4 Simulation and Evaluation The proposed LBC Routing Protocol is simulated using the ONE—Opportunistic Network Environment—Simulator [17–20], and the performance is evaluated. It is one of the best and efficient simulation tools for OppNets as it can implement several conventional routing protocols. Moreover, it can also support a number of mobility movement models and facilitates in generating their mobility traces.

Location-Based Clustering Approach for Next-Hop Selection in Opportunistic. . .

97

Algorithm 1 Simulation space location-based clustering approach for selecting next best forwarding node in opportunistic networks //clusters: A hashmap to store all the clusters, in the form of 2D-coordinate. //distDestCluster: A hashmap to store the Euclidean distance of the destination’s cluster from all the cluster points that is stored in the “clusters” hashmap //calcDistance(): Method that takes two parameters in the form of coordinates in the XY-plane and returns the Euclidean distance between them. //calcMean(): Method that takes two parameters in the form of coordinates in the XY-plane and returns the mean value between them. //calcAverageDistance(): Method that takes the hashmap distDestCluster and returns the average of all the distances stored in the hashmap. //isEmpty(): Method to check whether a hashmap is empty or not //append(): Method to append a new element to a hashmap //replace(): Method to replace an existing cluster with a new cluster //flag=0 BEGIN for each neighbour node n do Calculate the Euclidean Distance between the source, S and n dsn = calcDistance(s, n) if dsn ≤ dt then If distance is less than threshold, calculate mean of their locations msn = calcMean(s, n) endIf if clusters.isEmpty() then Append msn to hashmap clusters if it is empty clusters. append(msn ) else flag=0 for each cluster c in Hashmap clustersdo ifcalcDistance(s, n) ≤ dt then Replace existing cluster if distance between s & n is less than threshold clusters. replace(c, calcMean(c, msn )) flag=1 endIf endFor if flag==0 then clusters. append(msn ) endIf endIf endFor for each message m do Identify destination’s cluster, dc for each cluster c in Hashmap clustersdo distDestCluster. append(calcDistance(dc , c)) endFor for each neighbour node n do Identify neighbour node’s cluster, nc ifcalcDistance(nc , dc ) ≤ calcAverageDstance(distDestCluster) then Forward the packet from s to n endIf endFor endFor END

98

A. Dutta et al.

In the simulation, the result of this work is compared with four benchmark routing protocols, viz. Epidemic [10], Prophet [11], EDR (Encounter and Distance Routing) [15] and EBC (Encounter Buffer and Contact Duration) [16] routing, and the result is analysed. For this simulation, the work basically considers 96 mobile nodes with 6 groups—2 groups of pedestrians each containing 30 nodes, 3 groups of trams containing 2 nodes in each and 1 group of cars having 30 nodes. Each pedestrian node has buffer size of 10 MB and travels with a speed of 0.5–1.5 m per second. The tram group nodes travelling with a speed of 7–10 m/s have a buffer size of 50 MB. The nodes in the car group having a buffer size of 10 MB move at 2.7–13.9 m/s speed. These nodes generate new messages, size of each ranging from 500 KB to 1 MB within an interval of 25–35 s having TTL (Time-to-Live) of 300 min each. Table 3 shows the parameters commonly used for the evaluation purpose. For comparing the said model with existing models, the work considered five sets of values for each evaluating parameters, viz. number of nodes (66, 96, 126, 156, 186), TTL (300, 350, 400, 450, 500) minutes, buffer size (5, 10, 15, 20, 25) MB and message generation interval (5–15, 15–25, 25–35, 35–45, 45–55) seconds. The result after simulation by using the number of nodes (66, 96, 126, 156, 186), TTL (300, 350, 400, 450, 500) minutes, buffer size (5, 10, 15, 20, 25) MB and message generation interval (5–15, 15–25, 25–35, 35–45, 45–55) seconds compared with traditional routing protocols with different measuring parameters—Average Latency, Messages Dropped, Buffer Time Average, Hop Count average and Delivery Probability—are plotted in Figs. 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16 and 17. Table 3 Simulation parameters used in the proposed model Parameter Simulation space Simulation time Movement model Communication interface Transmission range Transmission speed High-speed interface transmission range High-speed interface transmission speed Time-to-live (TTL) Message sizes Message creation interval Buffer size (BS)

Values 4500 × 3400 metres 100,000 seconds Shortest-path-map-based movement model Bluetooth 20 m 250 kbps 1500 m 10 mbps 300 min 500 KB to 1 MB 25–35 s 10 MB

Location-Based Clustering Approach for Next-Hop Selection in Opportunistic. . .

99

Fig. 1 It shows the relationships between average latency with number of nodes, and it is found that by increasing the number of nodes from 66 to 186, the mean latency of all the protocol decreases. It happens since the increase in nodes in the network results in more carriers of the message, and hence the time required to forward that message decreases, thus reducing the average latency. However, the average latency of the proposed algorithm is much lesser as compared to Epidemic, Prophet, EDR and EBC protocols. Again the performance of LBC is better than Epidemic, Prophet, EDR and EBC routing protocols by approximately 12.46%, 10.63%, 35.9% and 15.38%, respectively, in terms of average latency on changing the number of nodes

Figures 1, 2, 3 and 4 show the relation of average latency with changes in all the parameters respectively. Figures 5, 6 and 7 depict the effect of changes in TTL, message generation interval and buffer size, respectively, on the number of messages dropped. The relationships of buffer time average with the evaluating parameters are depicted in Figs. 8, 9, 10 and 11, respectively. Figures 12, 13, 14 and 15 show the effects of changes in evaluating parameters on hop count. Figures 16 and 17 show how changes in number of nodes and buffer size affect the delivery probability.

100

A. Dutta et al.

Fig. 2 The comparison between average latency and TTL is depicted. It has been seen that by varying TTL value from 300 to 500 min, the average latency of all the protocols increases. The reason is as follows: as TTL value increases, the amount of time that a message remain in the nodes buffer also increases, which further results in increase of message latency. However, it is observed that the average latency of LBC is less than that of other protocols, thus improving the performance of the proposed algorithm approximately by 14.5%, 14.7%, 36.36% and 11.05% in comparison to Epidemic, Prophet, EDR and EBC protocols in respect of average latency

Fig. 3 It has been drawn between average latency and message generation interval, and it is observed that as the message generation interval changes from 5–15 to 45–55, the mean latency value of all the protocols gradually increases. It is seen that the average latency of the proposed model is comparatively less than Epidemic, Prophet, EDR and EBC, thus improving the performance by 12.99%, 11.71%, 31% and 9%, respectively

Location-Based Clustering Approach for Next-Hop Selection in Opportunistic. . .

101

Fig. 4 It shows the relations between average latency and buffer size where it is seen that for all protocols, the latency increases as the buffer size increases from 5 MB to 25 MB. However, according to the set criteria of the proposed model, it is seen that LBC has much less latency as compared to the other models, thus making it more efficient in respect of average latency by 25.6%, 22%, 36% and 15.6%, as compared to Epidemic, Prophet, EDR and EBC protocols, respectively

Fig. 5 It shows that as TTL increases from 300 to 500 minutes, the number of message dropped also increases for all the protocols. The reason is that as TTL increases, the messages remain in the node buffer for a longer duration of time. With proper node selection criteria in the proposed model, the suitable node is selected for message forwarding, thus resulting in less dropping those messages, and as result, LBC is observed to improve performance by 39.42%, 31%, 9% and 28.13% than Epidemic, Prophet, EDR and EBC, respectively, with respect to Messages Dropped

102

A. Dutta et al.

Fig. 6 Relationship among message generating interval and total messages dropped, which shows that by increasing the interval of message generation from 5–15 to 45–55, less messages will be created, resulting in a decrease in message dropping rate. This henceforth improves the performance of LBC by 36.6%, 30.6%, 6.5% and 26.61%, respectively, as compared to Epidemic, Prophet, EDR and EBC in respect to messages dropped

Fig. 7 Changes in the messages dropped with an increase in buffer size from 5 MB to 25 MB. It has been found that when buffer capacity increases, messages are dropped more frequently in all the protocols. Again, the proposed model drops much less number of messages as compared to Epidemic, Prophet, EDR and EBC routing, thus improving the performance, respectively, by 35.9%, 29.8%, 8.6% and 28.4% in terms of messages dropped

Location-Based Clustering Approach for Next-Hop Selection in Opportunistic. . .

103

Fig. 8 The relationships between average buffer time and the number of nodes are displayed where it is seen that with the increase in nodes from 66 to 186, more and more buffer space become available for the messages, and as a result, the average buffer time gradually decreases. Thus, in context of average buffer time, the proposed model is approximately 33.8%, 32%, 15.6% and 21% better than Epidemic, Prophet, EDR and EBC Routing, respectively

Fig. 9 The comparison between buffer time average and TTL is depicted. It is observed that on increasing TTL from 300 to 500 min, the node can keep the messages in their buffer until and unless they are not delivered or its validity does not expire. Also a higher buffer time represents that the proposed model is 39.8%, 38.%, 22.6% and 29% more efficient as compared to the Epidemic, Prophet, EDR and EBC routing protocols in respect to Buffer Time average

104

A. Dutta et al.

Fig. 10 It depicts the changes in message generation interval on buffer time average. It is seen that on increasing the message generation interval from 5–15 to 45–55, the mean buffer time increases for all the models. The reason for this is as the interval of generating messages increases, the nodes become more capable of storing messages till they are delivered or their time limit expires, which eventually increases the mean buffer time. The proposed model also follows this pattern with a higher value of buffer time average compared to Epidemic, Prophet, EDR and EBC routing, thus improving the performance by 36.9%, 34.62%, 18.5% and 26.6%, respectively

Fig. 11 The relationship between average buffer time and buffer size is shown, where it is observed that as the nodes buffer size increases, the average buffer time also increases in all the protocols. The reason is, with increasing buffer size of nodes, more and more space become available to store the messages. As a result, the node will store the message till it can deliver it or the time of that message expires. However, it is observed that the proposed model has mean value of buffer time much higher than Epidemic, Prophet, EDR and EBC routing, thus increasing the performance of LBC by 36.2%, 34.2%, 24% and 28.9%, respectively, in terms of buffer time average

Location-Based Clustering Approach for Next-Hop Selection in Opportunistic. . .

105

Fig. 12 As the number of nodes increase from 66 to 186, the number of hops for transmitting a message also increases. The reason is that with the increase of nodes in a network, a packet has to travel through several nodes to reach to the destination, and as a result, the number of hops required increases. It seems that the proposed model has an average hop count lesser than that of Epidemic, Prophet and EBC routing by 26.9%, 3.3% and 12.4%, respectively. However, EDR provides 7.7% less average hop count than the proposed model since it forwards a message to a subset of nodes at a time rather than to a single node at a time as done in EDR

Fig. 13 The relationship between hop-count and TTL is depicted, where it is seen that as TTL increases from 300 to 500 min, the proposed model in an average requires less hops (nodes) for forwarding a message as compared to Epidemic, Prophet and EBC routing, thus performing 25.7%, 4% and 14%, respectively, better than LBC. However, LBC requires more hops than that of EDR, since a message in EDR is forwarded to a single node at a time, whereas in the proposed model, a message is being forwarded to a subset of nodes at a time

106

A. Dutta et al.

Fig. 14 The effect of changes in hop count on changing the message generating interval is shown, where it is seen that the number of hops required by the proposed model is less than that of Epidemic, Prophet and EBC routing but is more than that of EDR, since a message in EDR is transmitted to a single node (hop) at a time unlike LBC routing. Thus the proposed model on an average performs 25.8%, 4.1% and 14.6% better in comparison to Epidemic, Prophet and EBC, respectively, in terms of hop count

Fig. 15 It depicts the relationship between hop count and buffer size that as buffer size increases, the average number of hops traversed by a message decreases. The reason is, with an increase in buffer size, a node becomes more capable of storing more messages for a longer duration of time, and as a result, messages have to go through less number of nodes, thus decreasing the average hop count for all the protocols. The proposed model requires less number of hops than Epidemic, Prophet and EBC routing, thus improving the performance by 24.3%, 3.1% and 14.4%, respectively, but it requires more hops as compared to EDR since in EDR, a packet is forwarded to a single hop/node at a time unlike the proposed model

Location-Based Clustering Approach for Next-Hop Selection in Opportunistic. . .

107

Fig. 16 Here it is observed that with an increase in nodes in a network, the delivery probability of all the protocols decreases. The proposed model also exhibits similar behaviour but is seen that delivery probability of this model surpasses that of EBC routing by 2.68%, whereas it has lesser delivery probability in comparison to Epidemic, Prophet and EDR routing

Fig. 17 It is seen that on increasing the buffer size, delivery probability increases in all the protocols. It happens because as the buffer size of a node increases, it becomes capable of storing a message for a longer duration of time till it encounters another node to forward the message, thus increasing delivery probability. The next node selection criteria used in the proposed model increases its delivery probability than EBC routing by 7.3% but is lesser than Epidemic, Prophet and EDR routing

5 Conclusion This chapter proposed the LBC routing—a protocol based on the clustering of nodes depending upon a threshold distance. The work basically focuses on creating clusters depending upon distance between the nodes and then forwarding the

108

A. Dutta et al.

message to those nodes that have a distance from the cluster point less than a specific threshold. After simulation using ONE Simulator, it is observed that in the context of messages dropped, buffer time average and average latency, the suggested LBC performs better than the protocols Epidemic, Prophet, EDR and EBC. It is found from simulations that in terms of average latency, LBC outperforms Epidemic, Prophet, EDR and EBC, respectively, by 12.46%, 10.63%, 35.9% and 15.38% when the number of nodes is increased. Similarly in the context of average buffer time, the proposed model is approximately 33.8%, 32%, 15.6% and 21% better than Epidemic, Prophet, EDR and EBC Routing, respectively. Also, in terms of number of messages dropped, LBC improves performance by 39.42%, 31%, 9% and 28.13% as compared to Epidemic, Prophet, EDR and EBC, respectively. In future work, aspects such as security, energy and other mobility models associated with the proposed method can be resolved.

References 1. Pelusi, L., Passarella, A., Conti, M.: Opportunistic networking: data forwarding in disconnected mobile ad hoc networks. IEEE Commun. Mag. 44(11), 134–141 (2006). https://doi.org/ 10.1109/MCOM.2006.248176 2. Etemad, K.: Overview of mobile WiMAX technology and evolution. IEEE Commun. Mag. 46(10), 31–40 (2008). https://doi.org/10.1109/MCOM.2008.4644117 3. Bisdikian, C.: An overview of the Bluetooth wireless technology. IEEE Commun. Mag. 39(12), 86–94 (2001). https://doi.org/10.1109/35.968817 4. Kraemer, R., Katz, M. (eds.): Short-range wireless communications: Emerging technologies and applications. Wiley (2009) 5. Denko, M.K. (ed.): Mobile Opportunistic Networks: Architectures, Protocols and Applications. CRC Press (2016) 6. Ramanathan, R., Redi, J.: A brief overview of ad hoc networks: challenges and directions. IEEE Commun. Mag. 40(5), 20–22 (2002) 7. Sun, J.-Z.: Mobile ad hoc networking: an essential technology for pervasive computing, vol. 3, pp. 316–321. 2001 International Conferences on Info-Tech and Info-Net. Proceedings (Cat. No.01EX479), Beijing (2001). https://doi.org/10.1109/ICII.2001.983076 8. Nguyen, T.D., Le, T.V., Pham, H.A.: Novel store–carry–forward scheme for message dissemination in vehicular ad-hoc networks. ICT Exp. 3(4), 193–198 (2017) 9. Alajeely, M., Doss, R., Ahmad, A.’a.: Routing protocols in opportunistic networks – a survey. IETE Tech. Rev. 35(4), 369–387 (2018). https://doi.org/10.1080/02564602.2017.1304834 10. Vahdat, A., Becker, D.: Epidemic Routing for Partially Connected Ad Hoc Networks. Technical Report CS-2000-06, Dept. of Computer Science, Duke University, Durham (2000) 11. Lindgren, A., Doria, A., Schelen, O.: Probabilistic routing in intermittently connected networks. ACM SIGMOBILE, Mobile Computing and Communications, 2003 Review. 7(3), 19–20 (2003) 12. Dhurandher, S.K., Borah, S.J., Obaidat, M.S., Sharma, D.K., Gupta, S., Baruah, B.: Probability-Based Controlled Flooding in Opportunistic Networks, pp. 3–8. 12th International Joint Conference on e-Business and Telecommunications (ICETE), Colmar (2015) 13. Spyropoulos, T., Psounis, K., Raghavendra, C.S.: Spray and Wait: An Efficient Routing Scheme for Intermittently Connected Mobile Networks, pp. 22–259. Proc. of SIGCOMM Workshop on Delay-Tolerant Networking, PA (2005)

Location-Based Clustering Approach for Next-Hop Selection in Opportunistic. . .

109

14. Dhurandher, S.K., Deepak, K.R., Sharma, Woungang, I., Bhati, S.: HBPR: History Based Prediction for Routing in Infrastructure-less Opportunistic Networks, pp. 931–936. Proc. of 27th IEEE AINA, Barcelona (2013) 15. Dhurandher, S.K., Borah, S., Woungang, I., Sharma, D.K., Arora, K., Agarwal, D.: EDR: An Encounter and Distance Based Routing Protocol for Opportunistic Networks, pp. 297– 302. 2016 IEEE 30th International Conference on Advanced Information Networking and Applications (AINA) (2016). https://doi.org/10.1109/AINA.2016.15 16. Borah, S.J., Singh, J., Singh, T.D.: EBC: Encounter Buffer and Contact duration-based Routing Protocol in Opportunistic Networks, pp. 1–6. Accepted for publication in the proceedings of Widecom 2022, University of Windsor, Springer, Windsor (2022) 17. Barun Saha’s Blog on Delay Tolerant Networks (n.d.). http://delay-tolerantnetworks.blogspot.com/p/one-tutorial.html 18. Keränen, A., Ott, J., Kärkkäinen, T.: The ONE simulator for DTN protocol evaluation, pp. 1–10. Proceedings of the 2nd International Conference on Simulation Tools and Techniques (2009) 19. Keränen, A., Kärkkäinen, T., Ott, J.: Simulating mobility and DTNs with the ONE. J. Commun. 5(2), 92–105 (2010) 20. Sharma, A., Gupta, P., Grover, J.: Configuration of ONE simulator using eclipse. IOSR J Electron Commun Eng. 1, 110–118 (2016)

Dungeons, Dragons, and Data Breaches: Analyzing AI Attacks on Various Network Configurations Kevin Olenic and Sheridan Houghten

1 Introduction The usage of artificial intelligence in cyber-security is an increasing trend as the capabilities of AI are beginning to surpass the abilities of humans in identifying vulnerabilities in computers and their associated networks. Thus the potential benefit of deploying AI in a cyber-security context is invaluable as they can perform vulnerability analysis and penetration testing on computer networks more efficiently and effectively than cyber-security analysis by a human. In this chapter, software that utilizes deep learning AI to analyze and take control of an abstract computer network is implemented to demonstrate the usage of AI in cyber-security; in particular, it performs a penetration test on an abstract computer network. Networks with a variety of characteristics are considered, to establish features that may contribute to the success of the AI in penetrating networks with those features. We use Microsoft’s CyberBattleSim [6, 7], an experimental open-source research project investigating how autonomous agents will perform in a simulated industry environment, using high-level abstractions of computer networks and cyber-security concepts. The program utilizes a “capture the flag” game methodology with the AI acting to capture all the flags (i.e., nodes) in the network to take control. The remainder of this chapter is organized as follows. Section 2 provides information on reinforcement learning, Q-learning, Deep-Q-learning, and other works involving the software used in this report. The algorithms and experimental setup are described in Sect. 3. Section 4 presents the results, while Sect. 5 concludes the paper and discusses possible future work.

K. Olenic · S. Houghten () Brock University, St. Catharines, ON, Canada e-mail: [email protected]; [email protected] © The Author(s), under exclusive license to Springer Nature Switzerland AG 2024 I. Woungang, S. K. Dhurandher (eds.), The 6th International Conference on Wireless, Intelligent and Distributed Environment for Communication, Lecture Notes on Data Engineering and Communications Technologies 185, https://doi.org/10.1007/978-3-031-47126-1_8

111

112

K. Olenic and S. Houghten

2 Background A major difficulty humans have in cyber-security is determining the vulnerabilities cyber-attacks or breaches could produce on networks due to their complexity and interconnected nature. This chapter covers an AI that examines such an event to determine the extent a network could be compromised. Through AI, cyber-security professionals can expedite and improve the analysis of security systems to gain insight into weak points in a computer system or network [5]. AI can perform quick automated defense and penetration testing on computer networks. Turning complex computer networks into abstract representations allows the attack to be represented as a game scenario, as in CyberBattleSim. This permits the AI to be more effective in its analysis. In this chapter, we use Deep-Q-learning to perform penetration tests on several abstract representations of computer networks. The AI will perform a complete analysis of the system to reveal its points of weakness.

2.1 Reinforcement Learning Reinforcement learning is a form of machine learning that uses autonomous decision-making agents to train an AI model, where the agents will interact with the environment by performing legal actions within the environment, performing these actions unsupervised throughout the process, meaning no human interaction or interference occurs [2]. This chapter examines software security scenarios in the context of reinforcement learning, where an attacker or a defender is an evolving agent in an abstract computer-generated environment mimicking a computer network. The agents’ actions within the environment are the available network and computer commands. The goal of the attacker agents is to steal confidential information, while the goal of the defender agents is to expel the attackers or, at minimum, mitigate damage to the system by performing defensive functions.

2.2 Q-Learning As Deep-Q-learning is an extension of Q-learning, it is prudent to understand this concept before diving into its deep counterpart. Q-learning uses a Q-table of State– Action Values (also called Q-values). The rows of the Q-table are all possible states of the system, while the columns are all the actions the agent can perform. Each cell contains the reward (or Q-value) associated with performing that action at that state. Over time, as the agent interacts with the environment and receives feedback, the algorithm iteratively improves the Q-values until they converge to the optimal Q-

Dungeons, Dragons, and Data Breaches: Analyzing AI Attacks on Various. . .

113

values. The Q-values are updated using the Bellman equation, given in Equation 1 [2]: V (s) = maxa (R(s, a) + yV (s  )).

.

(1)

In this equation, s is the current state of the environment in which the agent is acting, .s  is the state that follows from the agent performing its desired action, a is an action, and y is a constant discount factor. V is the value of a state, used to aid the agent in finding its optimal path, so that .V (s) is the value for current state s and   .V (s ) is the value for resulting state .s . R is the reward the agent receives for acting, so that .R(s) is the reward gained for being in state s and .R(s, a) is the reward for being in state s and performing action a. The Q-learning algorithm initializes the system with the agent randomly selecting an action in its current state. Over time, as the agent interacts with the environment, it learns the optimal activity to produce the best result based on the rewards it will obtain. During training, the algorithm performs four distinct stages, as follows: 1. Initialize the Q-table values to zero and randomly select the initial state (s). The agent will now begin training. 2. The agent selects an action (.a1 ) from its list of currently executable actions using the epsilon-greedy search policy (see [2]). The goal is to choose the action with the highest estimated reward, balancing between exploration and exploitation. 3. The action (.a1 ) selected is passed to the environment (s) for execution by the agent. Upon execution of .a1 , the environment returns the reward (.R1 ) associated with the action and the resulting next state (.s  ). 4. Update the current values in the Q-table using the reward (.R1 ) returned from the previous state (s) and the targeted Q-value, which is the action with the maximum Q-value in the current state (.s  ). With all values chosen, use the update formula to compute a new value for the Q-value of the action performed in the previous state. Note that the target action is used only for updating the Q-value for the action performed in the previous state, not necessarily the action executed in the current time step. Steps 2–4 repeat for several epochs until the model achieves a desired termination condition set by the user or reaches the maximum number of epochs; upon reaching a termination condition, this constitutes a single episode (which we interchangeably refer to as a run). When training the agent in Q-learning, the number of epochs determines the number of times the algorithm runs through a specific set of training data, with each episode having its own training data. Each set of training data is a particular network topology. Once an episode completes, the algorithm takes the trained model and applies what it learned in subsequent episodes. This process repeats until the final episode of training finishes.

114

K. Olenic and S. Houghten

2.3 Deep-Q-Learning Now that we have a basic understanding of Q-learning, we go into its deep counterpart. One of the main distinctions between deep and non-Deep-Q-learning is that Deep-Q-learning replaces the Q-table with two neural networks that handle the learning process. Unlike Q-learning, which maps each state–action pair to its corresponding Q-value (via the Q-table), Deep-Q-learning uses a neural network to drive agent responses. The neural net takes the current state as input and outputs the action to perform and the resulting next state. Training these networks is accomplished via a three-step process: first to initialize the target and main neural networks, next to choose an action, and finally to update the network weights. These networks possess the same overarching architecture but have different weights, and once every Nth step, the weight values from the main network are copied to the target network. Using both of these networks aids in stabilizing the learning process, allowing the algorithm to learn more effectively. Like Q-learning, Deep-Q-learning uses an epsilon-greedy exploration strategy, and the Bellman equation (Eq. 1) to update the Q-table values. Agents in deep Q-learning utilize experience replay, which involves storing and replaying previous states of the game from which the reinforcement learning algorithm can learn, discovering additional information about their current environment and using it to update both the Main and Target networks. The Main network samples and trains using a batch of past ventures every four stages, and the Main’s weights are copied to the Target network every sixty steps. This is comparable to regular Q-learning, save that the agent revises the model weights using Eq. 1 [4].

2.4 Related Work Since CyberBattleSim was first presented in [6], other papers have also examined the system to determine its capabilities in automated attack and defense. Several researchers have used this system to study different aspects of cyber-security. An extension to CyberBattleSim is presented in [1]. The research analyzed autonomous agents trained with Tabular Q-Learning through multiple experiments examining a range of network scenarios. The results demonstrated off-the-shelf Tabular Q-Learning did not offer a solution across all scenarios. However, they also found that modifying the underlying state encoding and update function can influence the robustness of the defensive agent to generalize to unseen evaluation environments without significant loss in accuracy. This highlighted potential optimizations for more advanced RL techniques and provided a baseline for others leveraging RL for defensive cyber automation. In [11], the process of black-box penetration testing is modelled as a Partially Observed Markov Decision Process (POMDP) while utilizing a new algorithm

Dungeons, Dragons, and Data Breaches: Analyzing AI Attacks on Various. . .

115

named ND3RQN, which is then applied to automated black-box penetration testing. Three networks from [6] were examined as well as a random scenario. A web platform extension to CyberBattleSim is presented in [3]. This extension of the project allows a user to model an enterprise network topology, interact with the topology manually, and simulate an automated adversarial agent. Leveraging the CyberBattleSim toolkit, it enables the swift prototyping of different network configurations that are analyzable by a defensive security team member either manually or automatically through the automated agent. In [9], CyberBattleSim is used in the investigation of artificial intelligence and machine learning methods for optimizing the adversarial behavior of agents in cyber-security simulations by integrating the modelling of agents launching Advanced Persistent Threats (APTs) with the modelling of agents using detection and mitigation mechanisms against APTs. This simulates the phenomenon of how attacks and defenses coevolve. In [10], deceptive features such as honeypots, honeytokens, and decoys were included into the Microsoft CyberBattleSim experimentation and research platform. In this chapter, we analyze the success of the AI in attacking networks with a wide range of different features. Our work differs from [10] as we did not implement honeytokens, meaning all credentials and tokens lead to a node in all of our network models.

3 Methodology 3.1 Environments For this chapter, several network environments are tested to determine the AI’s ability to perform a penetration test on unique environments. The networks used in the examination include a simple chain pattern and a toy network pattern, both of which are provided in [7] using 12 nodes. We create networks based on both of these patterns, varying the number of nodes so as to study the effects on the time required and the reward per epoch. We also perform the same analysis on a new custom network of 11 nodes. For each of the networks, the types of nodes, their connections, and the number of vulnerabilities are specified in the following sections. When the AI successfully takes control of a node, it obtains a reward that is based on which vulnerability it used and the type of node. Each node contains listening services unique to that node, and certain vulnerabilities such as revealing other nodes in the network or providing credentials to access another node in the network through the port associated with that credential. The exact vulnerabilities for each type of node are given in [8].

116

K. Olenic and S. Houghten

Fig. 1 Example of chain network topology. At this stage, the agent has control of all nodes (shown in red)

3.1.1

Chain Network

The chain network environment consists of two types of nodes, Linux nodes (with HTTPS and SSH connections, and 5 vulnerabilities) and Windows nodes (with HTTPS and RDP connections and 6 vulnerabilities). The environment is a chain with an even number of nodes (half Linux, half Windows), with the nodes in the chain alternating between the two as shown in Fig. 1 for a network of 10 nodes. For this network pattern, we use environments containing 10, 30, and 50 nodes to examine the effect a change in size would have on the AI’s effectiveness in taking control of the network.

3.1.2

Toy Network

The second environment examined is based on the toy environment described in [6]. This represents a small abstract network in which an attacker takes over a client node (user’s machine) and uses it to access their GitHub account and several other weakly protected nodes. A toy network with 10 nodes is shown in Fig. 2. This initial network environment undergoes several changes to increase the difficulty and a variety of scenarios the AI will encounter. To increase the models’ accuracy, the Transfer Control Protocol (TCP) and File Transfer Protocol (FTP) were added to the network and applied to their corresponding nodes. A network of 12 nodes was created by adding Gmail and Google Password Manager nodes to the network in Fig. 2. A network of 14 nodes additionally included Webcam and CloudFiles nodes, while a network of 16 nodes further included PrivateServer and WorkEmail nodes. Details on the nodes are provided in Table 1.

Dungeons, Dragons, and Data Breaches: Analyzing AI Attacks on Various. . . Fig. 2 Example of toy network topology. At this stage, the agent has control of the red nodes and does not have control of the green nodes

Table 1 Toy/custom network node characteristics Node Client Website Website.Directory Website[user=monitor] GitHubProject AzureStorage Sharpoint AzureResourceManager AzureResourceManager[user=monitor] Gmail WorkEmail CloudFiles Webcam PrivateServer GooglePasswordManager RemoteDesktop Sakai HoneyPot Printer CardReader Telephones

Connections N/A HTTPS, SSH HTTPS SSH, SSH-key, su GIT HTTPS HTTPS HTTPS HTTPS Ping, TCP Ping, TCP FTP TCP HTTPS, SSH HTTP, TCP RDP HTTPS HTTPS WSD WSD WSD

Num vulnerabilities Toy Custom 8 10 4 5 2 1 1 N/A 1 N/A 1 N/A 1 N/A 1 N/A 0 N/A 0 0 0 N/A 0 0 0 N/A 0 0 3 3 N/A 0 N/A 0 N/A 0 N/A 0 N/A 0 N/A 0

117

118

K. Olenic and S. Houghten

Fig. 3 Example of custom network topology. At this stage, the agent has control of the red nodes and does not have control of the green nodes

3.1.3

Custom Network

The final environment examined is a custom environment based on the toy environment that includes a personal network with several vulnerable machines, with a honeytrap node present in the network to hamper the AI’s attack. The network contains nodes representing personal work devices such as printers, telephones, and card readers, along with nodes requiring two-factor authentication, denying an attacker access even if they have the correct credentials for the node (Fig. 3). There are also nodes representing honeypots and an additional connection, such as the Web Services for Devices (WSD) port connection. The environment is shown in Fig. 5, and information on the nodes is given in Table 1.

4 Performance Evaluation Results 4.1 Cumulative Reward per Epoch Generated by the Chain Network We first examine the cumulative reward at each epoch during a training episode as it attacks the chain network environment. The charts are provided by summing the reward for each episode and dividing the total by the number of training episodes performed, revealing the number of rewards the attacker AI acquires during each epoch for each training episode. Figure 4 shows the results for three separate experiments of five episodes each, for the chain network containing 10 nodes. There is a noticeable trend in the algorithm’s learning ability: For each experiment, during the first episode, the AI requires a considerable amount of time to take control of the network and, in some cases, does not take full possession until the

Dungeons, Dragons, and Data Breaches: Analyzing AI Attacks on Various. . .

119

Fig. 4 Cumulative reward per epoch for each episode (run) for the chain network containing 10 nodes for three different experiments

Fig. 5 Cumulative reward per epoch for each episode (run) for the chain network containing 30 nodes for three different experiments

second episode. Due to the lack of experience the algorithm holds during the initial episode, a significant amount of time is required for the AI to examine and explore the network’s topology. The second episode requires less time to traverse and take control of the network, as it acquires knowledge of the topology and the actions producing the most efficient way to take control. This trend holds for subsequent episodes as the AI refines its decision-making process until it can take control of the network with minimal effort. However, there were instances where the algorithm performed worse than previous episodes, most likely caused by the AI performing actions optimal for earlier configurations of the network, but which for the current network caused a drop in efficiency. Next, experimentation of the chain network containing 30 nodes is conducted. As seen in Fig. 5, there is a similar trend to the network containing 10 nodes, with the first episode taking the longest, subsequent episodes requiring less time, and a trend where in a later episode the AI performs less optimally on average than previous episodes. Finally, we examine a chain network containing 50 nodes to determine if the trends in the previous topologies hold for an additionally extended network. As shown in Fig. 6, the trends observed in the analysis of the smaller networks are also present in the results for the cumulative reward per epoch for the network containing 50 nodes.

120

K. Olenic and S. Houghten

Fig. 6 Cumulative reward per epoch for each episode (run) for the chain network containing 50 nodes for three different experiments

Fig. 7 Cumulative reward per epoch for each episode (run) for the toy network containing 12 nodes for three different experiments

4.2 Cumulative Reward per Epoch Generated by the Toy Network We now perform the same examination on more complex networks based on the toy pattern described in Sect. 3.1.2. We first examine a network containing 12 nodes. Figure 7 depicts the total reward the attacker AI accumulated at each epoch for a training episode. By examining these graphs, one can deduce that the AI performs the same base exploration during the first training episode but does not collect enough information nor traverse enough of the network during the first episode to improve its attack in the next episode. Also, while later episodes take longer to accumulate rewards, they obtain a greater amount than in the first run. This is a result of the network navigating the network it already traversed in the first episode quickly and now expanding its attack into nodes it did not reach the first time. In later episodes, the AI begins improving its performance as it can more quickly accumulate rewards. We now examine the 14-node toy network. The results in Fig. 8 show a similar trend to the smaller toy network. The first training episode produces the lowest cumulative reward, with later episodes requiring more epochs. Once the AI has explored the entire network that it can access, it begins refining its decision-making process. Finally, we examine the toy network of 16 nodes. As seen in Fig. 9, the same trend of exploration and refinement of decisions is prevalent. This implies that as the

Dungeons, Dragons, and Data Breaches: Analyzing AI Attacks on Various. . .

121

Fig. 8 Cumulative reward per epoch for each episode (run) for the toy network containing 14 nodes for three different experiments

Fig. 9 Cumulative reward per epoch for each episode (run) for the toy network containing 16 nodes for three different experiments

Fig. 10 Cumulative reward per epoch for each episode (run) for the custom network containing 10 nodes for three different experiments

complexity and size of the network both grow, more time is needed for exploration to allow the AI to collect all the necessary information to refine its decisions.

4.3 Cumulative Reward per Epoch Generated by the Custom Network In this section, we examine the cumulative reward per epoch for the attacker AI during an episode of training for the custom network described in Sect. 3.1.3. Three experiments are performed on the same custom environment, with the results shown in Fig. 10. These show the same trends as in the toy network: the first episode has

122

K. Olenic and S. Houghten

the AI perform an exploratory examination of the network, while in later stages, the number of epochs required to accumulate the rewards available in the network decreases. The custom network also shows that the AI will continue to attack the network even though there are no more vulnerable nodes, and it could not discern that the Honeypot node placed in the network produced an unfavorable outcome as the AI always decided to try to take control of this node. This analysis of the custom network demonstrates the AI is wasting resources on nodes that will damage its effectiveness in taking control of the network.

4.4 Average Time Generated by the Chain Network In this section, we examine the average overall time, in seconds, that the attacker AI needs to take control of the network during an episode, revealing how efficient the AI is at taking control of a simple network comprised of only two types of nodes. The results for the chain networks of 10, 30, and 50 nodes are summarized in Table 2. This table depicts a trend in the time taken in each episode across all experiments: the first episode requires the greatest amount of time, while the later episodes need less and less time to take control of the network. Due to the AI’s lack of information in the first episodes, it explores the topology at random. However, after the first episode, the AI learns the basics of the network and uses this information in later episodes to expedite traversal and conquering of the network. With an increase in the number of nodes in the network, the average time per episode is longer, a situation that persists through all runs after the first run. The average time spent on the first episode is greater than in subsequent episodes. However, it should be noted that depending on the size of the network, this can be seen as either an advantage or disadvantage, as it can reduce training in subsequent episodes due to the repetition of nodes in the topology, but it can also limit the AI’s effectiveness with other networks as it overfits to a specific model structure. This examination of the average time per episode demonstrates how effective a tool this program is as it can perform the analysis in a few seconds, whereas it may take a human analyst hours or days to examine the full network. Table 2 Average time required to take control for chain networks

Nodes 10 30 50

E1 312.34 247.43 340.26

E2 17.49 32.26 32.73

E3 8.58 30.03 25.68

E4 9.9 19.87 24.14

E5 6.84 19.35 19.68

Run Avg 355.15 348.95 442.49

Dungeons, Dragons, and Data Breaches: Analyzing AI Attacks on Various. . .

123

Table 3 Average time required to take control for toy networks Nodes 12 14 16

E1 291.52 463.05 635.79

E2 96.53 117.23 138.98

E3 131.21 146.34 178.09

E4 147.12 179.58 189.7

E5 147.02 208.02 183.86

Run Avg 813.41 1114.22 1326.42

4.5 Average Time Generated by the Toy Network We now consider the average time per episode and average run time for the AI to take control of the more complex toy network, to determine its effectiveness at taking control of a network with a greater variety of nodes and connections. Table 3 summarizes the results for the 12-, 14-, and 16-node toy networks described in Sect. 3.1.2. The results in this table demonstrate similar trends to those seen for the chain network, as the AI takes the longest in the first episode and, in the following episodes, the time needed decreases from the initial attacks as the network gains more experience. However, in contrast to the chain network, the time in later episodes stagnates, resulting from the AI attempting to take control of protected nodes. When considering the larger toy networks, one can observe the same trends persists through all three experiments, with the first training episode taking the longest, and subsequent episodes being shorter. Again, later episodes have their time stagnate or increase as the AI attempts to find a way to access the protected nodes in the network. While the time required to take control of the chain network in the first episode is not significantly different as the number of nodes in the network increases, the time required to take control of the toy networks in the first episode significantly increases as the number of nodes increases; this is expected due to the increased complexity of the topology. However, this increase is less significant in later episodes.

4.6 Average Time Generated by the Custom Network The average time per episode required for the AI to take control of the custom network is presented in Table 4. This table depicts the same trend as in the other networks: The first episode is the longest as this is the exploratory training episode, where the AI is first introduced to the network and is determining the types of nodes and connections, while also taking control of as many nodes as possible in the allotted time. Subsequent episodes see the average time decrease, resulting from the AI refining its tactics based on the information it has gathered on the nodes of which it has successfully taken control. However, the overall average time does not continue to decrease throughout the process because the AI is attempting

124

K. Olenic and S. Houghten

Table 4 Average time required to take control for custom network E1 333.47

E2 158.28

E3 193.0

E4 197.51

E5 205.38

Run 1087.65

to take control of nodes that are protected against its currently defined methods of infiltration and attack, causing it to waste time and resources in an attempt to infiltrate the nodes and take control. This means that while the program is efficient in this task, it still requires improvements to make it more capable of analyzing computer networks. There are several observations that can be made based on the experiments performed. First, given a simple network such as the chain network, with a lack of security measures and a small variety of nodes, the program is efficient at attacking and taking control of the network even if it contains a high number of machines as this number makes little difference to the efficiency of the algorithm during the attack. However, when given more complex networks such as the toy or custom networks, the algorithm makes quick work of finding and exploiting the vulnerable nodes in the network, but it will waste resources in attempts to take control of nodes that are beyond its reach; should there be traps in the network such as honeypots, the AI has no countermeasure or defined method to prevent itself from wasting resources on these forms of traps.

5 Conclusion In this research, it was found that the AI presented in the CyberBattleSim software is an efficient and intriguing method of performing a penetration test on an abstract representation of a computer network, capable of navigating and determining weaknesses in the structure of the computer network faster than a human, while finding the path that will provide the most effective and efficient attack to take control of the network and usable information that can eliminate these weaknesses. However, this AI possesses several limitations, including an inability to react to nodes in the network that are a waste of resources or protected against its methods of attack. This causes it to waste resources and time and possibly exposes it to cyber-security measures within the network or devices connected to it. In short, traps such as honeypots included in the network design successfully prevented the AI from taking control, but from the AI perspective some improvements should be considered. AI is a valuable tool when testing the security of a network as it can perform quick analysis and improve its approach to discover the most vulnerable sections and paths for an attacker to take control of a network, but some modifications can make it an even better and more efficient resource for penetration testing of a network.

Dungeons, Dragons, and Data Breaches: Analyzing AI Attacks on Various. . .

125

Future work can include incorporating features into the AI to detect whether it is attempting to take control of a protected node by placing a timer, the number of attempts constraint or scanner to determine if the AI possesses the correct security credentials to prevent detection by the system’s security. Other modifications could include integrating features that allow it to detect if it is attempting to take control of a honeypot and having it employ some countermeasure to prevent any waste of resources on such a trap. It could also be worthwhile to focus on the AI’s ability to perform more focused attacks, rather than simply exploration. For example, it could be made into a more directed program that attacks high-value data files or infrastructure rather than the entire network. Finally, note that while the program is an effective tool for testing defenses, it can be adjusted to perform malicious attacks, making it useful for both protecting and destroying networks.

References 1. Applebaum, A., et al.: Bridging automated to autonomous cyber defense: Foundational analysis of tabular Q-learning. In: Proceedings of the 15th ACM Workshop on Artificial Intelligence and Security, pp. 149–159 (2022) 2. Ding, Z., et al.: Introduction to Reinforcement Learning. Springer, Singapore (2020) 3. Esteban, J.: Simulating Network Lateral Movements through the CyberBattleSim Web Platform. PhD thesis, Massachusetts Institute of Technology, 2022 4. Hester, T., et al.: Deep Q-learning from demonstrations. In: Proceedings of the AAAI Conference on Artificial Intelligence, vol. 32(1), Apr. 2018 5. Kott, A.: Intelligent autonomous agents are key to cyber defense of the future army networks. Cyber Defense Rev. 3(3), 57–70 (2018) 6. Microsoft 365 Defender Research Team: Gamifying machine learning for stronger security and AI models, Apr 2021 7. Microsoft Defender Research Team: Cyberbattlesim. Available at https://github.com/ microsoft/cyberbattlesim, 2021 8. Olenic, K.: Using Artificial Intelligence for Cyber-Security. Bachelor’s thesis, Brock University, 2023 9. Shashkov, A., et al.: Adversarial agent-learning for cybersecurity: a comparison of algorithms. Knowl. Eng. Rev. 38, e3 (2023) 10. Walter, E., Ferguson-Walter, K., Ridley, A.: Incorporating deception into cyberbattlesim for autonomous defense. CoRR, abs/2108.13980 (2021) 11. Zhang, Y., et al.: Improved deep recurrent q-network of POMDPs for automated penetration testing. Appl. Sci. 12(20), 10339 (2022)

Q-Learning-Based Underwater Sensor Networks Routing Protocol for Pollution Monitoring Simon Chege and Tom Walingo

1 Introduction The increasing demand for natural marine surveillance, investigation of marine resources, scientific marine research, and marine protection has fueled a paradigm shift in the studies related to the design and implementation of practical underwater acquisition techniques. Research in UWSNs has become desirable and popular to the institutions and community due to its significance namely: monitoring of water quality and marine life environment; disaster prediction such as floods, volcanic activities, and earthquakes; surveillance applications such as port security, communication with sub-marines, and detection of mines; localization in underwater that is vessels and explorers navigation assistance; lastly, sensing applications in underwater sports such as velocity of swimmers for further analysis. The underwater presents very rough environments as a result of strong ocean currents, varying temperatures, and different salinity levels. The underwater sound speed is quite low at about 1500 m/s compared to the surface radio waves, which results in large propagation delays [1]. Furthermore, the dynamic underwater environment makes the network topology design difficult. The sensors are batterypowered that are strenuous to recharge or replace. Thus, there is need for prudent energy management in order to enhance the network lifetime. Other UWSN network

The work was supported by The Centre for Radio Access and Rural Technologies (CRART), University of KwaZulu Natal, South Africa. S. Chege () · T. Walingo Discipline of Electrical, Electronic and Computer Engineering, University of KwaZulu Natal, Durban, South Africa © The Author(s), under exclusive license to Springer Nature Switzerland AG 2024 I. Woungang, S. K. Dhurandher (eds.), The 6th International Conference on Wireless, Intelligent and Distributed Environment for Communication, Lecture Notes on Data Engineering and Communications Technologies 185, https://doi.org/10.1007/978-3-031-47126-1_9

127

128

S. Chege and T. Walingo

design challenges include routing and MAC protocols, limited bandwidth, high error rate, latency, and node localization [1]. Lastly, the void region issue is a key consideration in the design of a robust routing protocol. A void region is that region where sensor nodes are at zero battery level or that has got no node at all. Figure 1 illustrates the UWSNs routing protocols design challenges. With such challenges, establishing a robust typical terrestrial UWSN connection protocol is an arduous and demanding task. Ongoing research investigates alternative UWSN communication technologies including the deployment of optical waves, acoustic waves, and electromagnetic (EM) waves. Different communication perspectives present divergent characteristics. As a result, selecting a suitable and appropriate technology is essential in the realization of a robust UWSNs. Research shows that acoustic communication is most preferred technique despite its drawbacks that include: poor latency efficiency, strong environmental influence on the channel behavior, and significantly minimized data rates. Research has also established that most protocols associated with the surface WSNs do not apply with the UWSNs. Additionally, it is desired that ongoing research investigates challenges associated with routing and MAC protocols, power limitations, latency, dynamic

Fig. 1 UWSNs routing protocols design challenges [1]

Q-Learning-Based Underwater Sensor Networks Routing Protocol for Pollution. . .

129

range of nodes, network topography, and all network necessities to provide solutions for UWSNs. Machine learning (ML) applications in UWSNs has recently explosively been researched. In [2], the authors propose QELAR, where every node trades its information with the bordering nodes, purposely to expand the UWSNs’ lifetime. The neighboring nodes can overhear, extract, and decide to carry or drop. While considering delivery latency, authors in [3] proposed an ML-based routing protocol QDAR. The routing protocol involves two types of packet structures that is a dataready and an interest packet. The interest packet transfers data from sink node to source node to determine the routine path, while data-ready packet transmits from source to sink that contains the nodes required information. The routing algorithm, with five phases, significantly reduces the latency in comparison to other protocols. However, to attain the equivalent latency reduction, its network lifetime is compromised. In [4], authors aim to increase lifetime while decreasing transmission delay using magnetic induction. The protocol utilizes Q-learning to create multi-hop paths. In [5], a multiagent reinforcement learning protocol (MARL) is proposed for UWSNs that suffer low delivery ratio and low energy efficiency. In [6], authors balance network lifetime extension and node residual energy while solving the void problem using Q-learning. In [7], a Q-learning integrated with deep neural network protocol is proposed. The protocol considers multiple metrics to train the routing decisions. In [8], a bio-inspired algorithm, i.e., the ant colony algorithm aided by Q-learning, is proposed. The concept of routing path is based on the reward path and the critical paths. Build on Faraday’s law of induction, magnetic induction (MI) utilizes two wired coils to transceive information [9]. The modulated signal current generates the magnetic field that varies with time in space in the forward transmit coil. The receive coil is then induced by the incoming sinusoidal current. Demodulation is then performed for data recovery. MI manifests some merits while in application in UWSN. In MI, there is minimal multi-path fading since just a modest quantity of energy is transmitted across the channel. Additionally, magnetic permeability on surface is the same as under surface and not necessarily dependent of water quality that changes with time, altitude, region, and depth. As a result, MI channel behavior is unvarying, predictable, and hence formulaic. Unlike acoustic communication channels, MI communication waves travel faster, eliminate delays, and provide prompt information transfer. Due to the consistency of the channel response and the reduced latency encountered with MI, synchronization of the physical layer wireless devices is more dependable and accessible. Moreover, MI waves are unseen, therefore facilitate energy-saving, and secure communication channels for secured applications. Even though the existing routing protocols enhance UWSNs performance, there is considerable capacity for improvement. More so, there is need to strike a balance between delay, energy consumption, and network lifetime. This chapter proposes a Q-learning-based routing protocol supported by magnetic induction (MI) communication (Q-MIRP), a new and promising technology. In Q-MIRP, the reward function is based on the energy consumption of each UWSN multi-hop

130

S. Chege and T. Walingo

transmission link. The ML is then trained to choose the route with the minimum energy consumption.

1.1 Organization The rest of this chapter is organized as follows: a background study of the reinforcement learning, Q-learning, acoustic communication, and magnetic induction communication techniques is presented in Sect. 2. Section 3 details the proposed Q-MIRP scheme for the UWSNs. In Sect. 4, the performance evaluation of the proposed Q-MIRP scheme is presented. Finally, Sect. 5 concludes the chapter.

2 Background 2.1 Reinforcement Learning Artificial intelligence (AI) has a subfield known as machine learning that focuses on creating statistical models and algorithms that let computer systems learn from their past performance without having to be explicitly programmed. In other words, machine learning uses data and statistical techniques to help computers get better over time at a particular task or problem. With the aid of incentives or penalties, an agent learns to make decisions in a given environment through the process of reinforcement learning (RL), a type of machine learning. The goal of RL is to maximize the cumulative reward obtained by the agent over time. In reinforcement learning, the agent interacts with the environment by taking actions, and the environment responds with a reward signal that reflects the quality of the action. The agent then updates its policy or strategy for selecting actions based on the received reward signal. This iterative process continues until the agent learns an optimal policy for the task at hand. Figure 2 demonstrates the classic RL framework [9]. The numerical value received by an agent for moving from one environmental state to another is referred to as Reward Rt [10]. The policy pi defines the agent’s behavior at any given time. The discount rate .γ is employed in the future cumulative reward equation to define the return for infinite series. The agent obtains the policy .π to map the actions to states and optimize the process. Reinforcement learning utilizes the Bellman equation to obtain the current state value by identifying the next state value. Finding the ideal Q-function .q ∗ , and by extension .π ∗ , is made easier by the information provided. Denote by .Q(s, a) the anticipated outcome of choosing the start point, state s while choosing action a following .π. Consequently, we obtain Rt, which is the full anticipated reward for tracking .π in state s choosing action a.   Further, .maxa Q(s , a ) denotes the maximum discounted return that is anticipated   for every .s choosing the action .a [11].

Q-Learning-Based Underwater Sensor Networks Routing Protocol for Pollution. . .

131

Fig. 2 Reinforcement learning framework [9]

Fig. 3 Q-learning framework [12]

2.2 Q-LEARNING Technique Q-learning is an RL algorithm seen as a Markov process [20]. Figure 3 illustrates the Q-learning process. The agent retains its past knowledge as the Q-value and learns from it at each step. The following equation serves as a guidance for revising the Q-value. 



Q(s, a) = R(s, a) + γ · max Q(s , a ).

.





(1)

R(s, a) represents the current reward and .max Q(s , a ) denotes the largest Q-value we can get in the next state. The discount factor that ranges .0 < γ < 1, if the difference is greater, the agent prioritizes the potential reward over the present reward. Generally, .Q(s, a) determines whether the value of the current state should be taken into consideration or not. The Q-values in each state are documented using

.

132

S. Chege and T. Walingo

a Q-matrix, which is a .m × n, with m denoting the sum total of states and n, the sum total of actions. Before the training begins, all of the Q-values are set to zero.

2.3 Acoustic Communication In underwater acoustic communication, packet transmission requires much more energy than receiving of packets. As a result, the acoustic model only considers just the packets transmission power. For a point-to-point UWSN, the energy consumption model can be described as follows: Given that .δ(f ) denotes the absorption coefficient, the power attenuation in relation to the distance, denoted by .U (d), is given by U (d) = (1000 · d)κ · α d .

δ(f ) α = 10 10 δ(f ) =

(2)

0.11f 2 44f 2 2.75f 2 3 + + + 3. 1 + f2 4100 + f 2 104 10

The value of .κ is dependent on the communication condition. At ocean surface or deep sea bed with cylindrically propagating waves, .κ = 1, while with cylindrical waves experiencing absorption at sea bed, .κ = 1.5. At open water, with spherically propagating waves, .κ = 2. Given that d denotes the distance between two nodes, 2 200 )3 . the optimal f is selected based on the formula, .fopt = ( d The minimum power level at which a data packet will be correctly recognized by the receiver is denoted by .P0 . The minimum node P transmission power is given by P = P0 × U (d).

.

(3)

Using (2) and (3), we can determine each packet transmission power at each transmission instance. The total energy consumption cost function .L(d), as given in [12], is expressed as the direct correlation relationship to the power attenuation .U (d) and given as L(u) ∝ U (d).

.

(4)

Thus, the Q-learning algorithm reward table is then designed based on the multi-hop UWSN distance. Consequently, by denoting source node with i and sink node with j , the source to sink node total energy consumption cost function .ΦT otal is the sum of each link .Lk,ij given as

Q-Learning-Based Underwater Sensor Networks Routing Protocol for Pollution. . .

ΦT otal =



.

133

(5)

Lk,ij .

2.4 Magnetic Induction Communication The proposed mode of communication in this chapter is the magnetic induction (MI). As observed, MI transmits faster than acoustic communication waves with shorter delays and hence less complexity in the design and deployment of routing, localization, and MAC protocols. To design an efficient MI channel model, the transmit and receive power are considered. In MI, the primary coil of the transformer is modeled as the transmitter, while the secondary coil is modeled as the receiver. The primary coil operates at a low frequency to strengthen the magnetic field and improve the magnetic moment. The real part transmit power .Pt for a single hop is given by  Pt (r) = Re

.

Us2

 

Zt + Zt

.

(6)

The sum of the receive power and the data processing power determines the receive power for a single hop. Therefore, the energy consumption per receive denoted by .Ereceive can be given as [9] Ereceive =

.

L(Pr + Ptrans ) . αm B(l)

(7)

For each packet, the delay in a single hop is given as Thop =

.

Dnm L + . αm B(l) S

(8)

Since we consider a multi-hop path system, the total sum of the distances between the source knodes and the sink nodes determines the distance between them, i.e., .Dns = i=1 Dnmi . As a result, the combined delay is the sum of all single-hop delays and queue delays. Ttotal =

.

Dnm L + + C × h. αm B(l) S

(9)

Table 1 gives the notations used in the equations. These equations are used in calculation of the energy consumption.

134 Table 1 MI equation notations

S. Chege and T. Walingo Notation .Pt (r) .Us .Zt  .Zt L .Pr .Ptrans .αm .B(l) .Thop .Dnm S C h

Definition Single-hop transmitting power Transmitter battery voltage Transmitter self-impedance Transmitter influence on the receiver Packet size Received power Translating power Modulating BW frequency Available BW Single-hop delay Distance between nodes n and m MI speed Number of data chunks Duration to receive a data chunk

Algorithm 1 Proposed Q-MIRP routing protocol for UWSNs Initialization : Set the parameter .γ , reward values and Initialize Q table to input the Q values. 1: for .i = 1, 2, · · · , do 2: STEP 1: Select at random the starting point and randomly perform an action in accordance to the Q-table in an effort to have the agent arrive at the desired sink. 3: STEP 2: Perform a table update in accordance to Eq. (1); 4: STEP 3: Make a choice by comparing the new Q value to the previous Q value.; 5: if the Q table portrays a variation then 6: From step 1, update the Q table once more. 7: else if the Q table portrays minimal variation then 8: Discontinue the update to the Q table and check out. 9: end if 10: end for 11: In accordance to the updated and stabilised Q table, Choose the adequate routing path.

3 Proposed Q-Learning for UWSNs Q-Learning algorithm works by allowing an agent to interact with the environment and learn from the feedback it receives. In the case of UWSNs, the agent can be the network itself, and the environment can be the underwater channel. In Q-Learning, the agent maintains a Q-table, which stores the expected reward for each possible action in each state. The Q-table is updated at each iteration based on the feedback received from the environment. The algorithm uses an exploration–exploitation strategy to balance between exploring new routes and exploiting known ones. To apply Q-Learning for routing design in UWSNs, the first step is to define the state and action spaces. The state space can be defined based on the network topology, the location of the sensors, and the quality of the underwater channel. The action space can be defined as the set of possible routes that the data packets can take to reach the surface.

Q-Learning-Based Underwater Sensor Networks Routing Protocol for Pollution. . .

135

Fig. 4 The reward table and Q-table for Q-learning. (a) The Reward table. (b) The initialized Q-table. (c) Q-table after one update. (d) The Q-table after training

Fig. 5 The Q-learning UWSN model. (a) The initial node connections. (b) The distributed rewards. (c) The Q-value connection relation

In this model, we consider six nodes, with each being able to transmit and receive data packets. The node connection is illustrated in Fig. 5, with sensor nodes and transmission directions are represented by circles and arrows, respectively. A circle represents a state, while an arrow represents an action. From Fig. 5a, nodes 0 and 2 only connect to one node. Node 5 is set as the destination node. At the first instance, a random node sends a packet. We set the action reward to lead to the destination to be 100; otherwise, it is set to 0. The reward of an unfeasible action such as connection between node 0 and 2 is set to .−1. For possible action such as connection between node 1 and 5, the reward action .R(1, 5) = 100. The reward distribution and matrix are given in Figs. 5c and 4a, respectively. We initialize the Q-table with zeros at the beginning of the training process as shown in Fig. 4b. Setting the discount factor .γ = 0.9, we can select state 4 to be the source node. If we randomly choose 5 as the action, then .Q(4, 5) will be evaluated for updating using the following equation:

136

S. Chege and T. Walingo

Q(4, 5) = R(4, 5) + 0.9 .

× max Q(5, 1), Q(5, 2), Q(5, 3), Q(5, 4), Q(5, 5)

(10)

= 100 + 0.9 × max 0, 0, 0, 0, 0. The Q-table is then updated as in Fig. 4d, and the training process continues the iterations and stops when all the Q-values are almost stable. In Fig. 5c, the values alongside the arrows represent the corresponding Q-value. Values represented in red arrow represent the highest value, denoting the optimal response for each node. Following training, the agent is prepared to select the ideal routing in any circumstance. For instance, consider node 4. Since .Q(4, 5) is greater than both .Q(4, 3) and .Q(4, 0), the package will be delivered to node 5. When there are more than two actions with the same Q-value, the next action will be selected at random from among them. The process of the proposed Q-learning routing protocol for UWSNs can be summarized as Algorithm 1.

4 Performance Evaluation We demonstrate the Q-MIRP simulation results for the UWSN routing protocol in this section. The total energy consumption is shown in Fig. 6 for the MI and acoustic communication models, for different packet numbers and different .γ values. An increasing trend in the energy consumption trend has been seen in each

Fig. 6 Total energy consumption versus the number of packets

Q-Learning-Based Underwater Sensor Networks Routing Protocol for Pollution. . .

137

Fig. 7 Energy consumption versus the number of nodes

communication model, albeit a difference in the .γ values. Lower .γ values exhibit in large total energy consumption. In Fig. 7, the comparison of MI and acoustic communication models versus the number of nodes is shown. The energy consumption increases as the number of nodes involved increases. Higher values of .γ lead to lower energy consumption and hence better energy efficiency. The selected routing result of Q-MIRP protocol is illustrated in Fig. 8. The chosen routing, which is represented by the solid blue line, is 1-3-4-5-7-9-10-1213-16-18. The transmission’s overall energy consumption cost function has a value of 2733000, and the Q-MIRP algorithm takes 0.21 seconds to run. Figure 9 illustrates the end-to-end delay comparison results at different data intervals. MI communication model exhibits lower delay compared to the acoustic communication model. This is due to the fact that MI waves travel faster than acoustic waves and thus enhance the UWSN delay efficiency thereby providing timely data transmission. The comparison of the normalized energy consumption between the proposed Q-MIRP algorithm, cooperative game-theory-based scheme, named DATUM proposed in [13] and QMCR proposed [12] versus the number of nodes is presented in Fig. 10. It can be observed that with the increase in the number of nodes deployed in the network, the normalized EE decreases significantly using the proposed Q-MIRP than in QMCR and DATUM. Using Q-MIRP, the EE reduces due to deployment of a lesser number of activated nodes and MI optimal transmission power level of the activated nodes.

138

S. Chege and T. Walingo

Fig. 8 Routing selected by Q-MIRP routing algorithm

Fig. 9 Average end-to-end delay

Lastly, in Fig. 11, a comparison analysis of the normalized latency for the proposed Q-MIRP algorithm, cooperative game-theory-based scheme, named DATUM proposed in [13] and QMCR proposed [12] versus the number of nodes is presented. From the figure, we yield that using Q-MIRP, network delay reduces

Q-Learning-Based Underwater Sensor Networks Routing Protocol for Pollution. . .

139

Fig. 10 Comparison of the normalized EE

Fig. 11 Comparison of the normalized delay

by .30.74–47.23% than using QMCR and DATUM, respectively. It is also observed that using Q-MIRP, the link failure reduces significantly than using QMCR and DATUM.

140

S. Chege and T. Walingo

5 Conclusion In this chapter, a Q-MIRP routing protocol for UWSN is proposed. The comparison results between MI communication and acoustic communication models under different .γ values are drawn. The average end-to-end delay results are also simulated for both MI and acoustic communication models. The best routing selected by Q-MIRP algorithm is also presented. In comparison to previous routing protocols, the agent will quickly and automatically choose the best transmission routing by continuously updating and optimizing the Q-table. The proposed QMIRP protocol, supported by MI communication model, is therefore suitable for underwater pollution monitoring. Further exploratory research on the application of the deep learning models for the dynamically changing channel environments and diversified devices needs to be studied for efficient underwater pollution monitoring. Acknowledgments The authors would like to thank the Centre for Radio Access and Rural Technologies (CRART) at University of KwaZulu Natal (UKZN) for supporting this work.

References 1. Awan, K.M., e. Shah, P.A.: Underwater wireless sensor networks: a review of recent issues and challenges. Wirel. Commun. Mob. Comput. 2019(3), 1–20 (2019) 2. Hu, T., Fei, Y.: QELAR: A Q-learning-based energy-efficient and lifetime-aware routing protocol for underwater sensor networks. In: 2008 IEEE International Performance, Computing and Communications Conference, pp. 247–255 (2008) 3. Zhigang, J., Yingying, M., Yishan, S., Li, S., Xiaomei, F.: A Q-learning-based delay-aware routing algorithm to extend the lifetime of underwater sensor networks. Sensors 17(7), 1660 (2017) 4. Wang, S., Shin, Y.: Efficient routing protocol based on reinforcement learning for magnetic induction underwater sensor networks. IEEE Access 7, 82027–82037 (2019) 5. Li, X., Hu, X., Li, W., Hu, H.: A multi-agent reinforcement learning routing protocol for underwater optical sensor networks. In: ICC 2019–2019 IEEE International Conference on Communications (ICC), pp. 1–7 (2019) 6. Javaid, N., Hafeez, T., Wadud, Z., Alrajeh, N., Alabed, M.S., Guizani, N.: Establishing a cooperation-based and void node avoiding energy-efficient underwater WSN for a cloud. IEEE Access 5, 11582–11593 (2017) 7. Su, Y., Fan, R., Fu, X., Jin, Z.: DQELR: an adaptive deep Q-network-based energy- and latency-aware routing protocol design for underwater acoustic sensor networks. IEEE Access 7, 9091–9104 (2019) 8. Fang, Z., Wang, J., Jiang, C., Zhang, B., Qin, C., Ren, Y.: QLACO: Q-learning aided ant colony routing protocol for underwater acoustic sensor networks. In: 2020 IEEE Wireless Communications and Networking Conference (WCNC), pp. 1–6 (2020) 9. Alsalman, L., Alotaibi, E.: A balanced routing protocol based on machine learning for underwater sensor networks. IEEE Access 9, 152082–152097 (2021) 10. Sutton, R.S., Barto, A.G.: Reinforcement Learning: An Introduction. MIT Press, Cambridge (2018) 11. Gosavi, A.: Reinforcement learning: a tutorial survey and recent advances. INFORMS J. Comput. 21, 178–192 (2009)

Q-Learning-Based Underwater Sensor Networks Routing Protocol for Pollution. . .

141

12. Chen, Y., Zheng, K., Fang, X., Wan, L., Xu, X.: QMCR: A Q-learning-based multi-hop cooperative routing protocol for underwater acoustic sensor networks. China Commun. 18(8), 224–236 (2021) 13. Misra, S., Mondal, A., Mondal, A.: DATUM: dynamic topology control for underwater wireless multimedia sensor networks. In: 2019 IEEE Wireless Communications and Networking Conference (WCNC). IEEE, New York, pp. 1–6 (2019)

Flood Forecasting in the Far-North Region of Cameroon: A Comparative Study of Machine Learning and Deep Learning Methods Ado Adamou Abba Ari, Francis Yongwa Dtissibe, Arouna Ndam Njoya, Hamadjam Abboubakar, Abdelhak Mourad Gueroui, Ousmane Thiare, and Alidou Mohamadou

1 Introduction 1.1 Background Floods remain the natural disasters causing a significant number of loss of lives and material damage [1, 2]. In the last 10 years, 45.54% (1298) of natural disasters (2850) were floods [3]. Since the 1960s, floods remain the most frequent

A. A. A. Ari () DAVID Lab, Université Paris-Saclay, University of Versailles Saint-Quentin-en-Yvelines, Versailles, France LaRI Lab, University of Maroua, Maroua, Cameroon CREATIVE, Institute of Fine Arts and Innovation, University of Garoua, Garoua, Cameroon e-mail: [email protected]; [email protected] F. Y. Dtissibe · A. Mohamadou LaRI Lab, University of Maroua, Maroua, Cameroon e-mail: [email protected]; [email protected] A. N. Njoya · H. Abboubakar Department of Computer Engineering, University Institute of Technology, University of Ngaoundéré, Ngaoundéré, Cameroon A. M. Gueroui DAVID Lab, Université Paris-Saclay, University of Versailles Saint-Quentin-en-Yvelines, Versailles, France e-mail: [email protected] O. Thiare LRI Lab, Gaston Berger University of Saint-Louis, Saint-Louis, Senegal e-mail: [email protected] © The Author(s), under exclusive license to Springer Nature Switzerland AG 2024 I. Woungang, S. K. Dhurandher (eds.), The 6th International Conference on Wireless, Intelligent and Distributed Environment for Communication, Lecture Notes on Data Engineering and Communications Technologies 185, https://doi.org/10.1007/978-3-031-47126-1_10

143

144

A. A. A. Ari et al.

climatological disasters, and the proportion of floods is steadily increasing [3]. Floods are the most frequent among natural disaster, and they can occur anywhere after heavy rainfall [4]. According to [5], the impact of extreme weather events is greater in Africa than in other regions of the world due to Africa’s low adaptive capacity, high reliance on ecosystem resources for livelihoods and climate-sensitive agriculture, and the number of households displaced and made homeless by floods is increasing dramatically in Africa [6]. In August and September 2012 in Maga in Cameroon’s Far-North region, 30,000 people were affected by floods. These floods caused significant deterioration of economic, social, crop and livestock activities [7]. In the same period in 2020, Cameroon’s Far-North region was again affected by floods resulting in the loss of lives, material and infrastructural damages. Work on precipitation trends and flood risks in Cameroon’s Far-North region was also carried out by Bouba et al. [8] using traditional methods. They analyzed the history of flood disasters and discovered that 30 of the 47 municipalities in the Far-North region have been affected at least once by floods [8]. The main objective of flood risk management strategies is to reduce exposure and losses [9]. Before the 1990s, the methods used for rainfall forecasting were based on hydrodynamic theories [10]. Artificial intelligence technology has developed at an astonishing speed and is rapidly emerging within the field of meteorology [10, 11]. ML methods have been shown to be promising for flood modeling and offer a useful alternative to physical-based hydraulic models, which are computationally demanding and difficult to use in operational flood forecasting systems [12].

1.2 Contribution of the Authors The present research work consists of the design and performance comparison of several ML and DL models for flood forecasting. Our contributions through this research work are the design and determination of the best performing model for short-term flood forecasting firstly, and secondly, the design and determination of the best performing model for long-term flood forecasting in Cameroon’s Far-North region. The ML and DL models (1D-CNN, LSTM, and MLP) designed take rainfall and temperature time series as inputs and produce rainfall as outputs. The selected models for short- and long-term flood forecasting have satisfactory performance criteria and are alternatives to the less efficient traditional hydrological methods. These models will allow the implementation of efficient flood warning systems and also to define flood risk management policies in order to make Cameroon’s FarNorth Region more resilient to flood crises.

Flood Forecasting in the Far-North Region of Cameroon: A Comparative Study. . .

145

1.3 Organization of the Paper Section 2 presents some related works. Section 3 of this research work presents the ML and DL methods used for short- and long-term flood forecasting. The study area (Cameroon’s Far-North Region) and the data (temperature and rainfall time series) are described in Sect. 4. The design and comparison of the flood forecasting models are done in Sect. 5, and the methodology used, the performance evaluation, and the testing of the models are described in this section. The presentation of the results and discussions is made in Sect. 6. Conclusion of our research work is presented in Sect. 7.

2 Related Works As applications of data-driven, artificial intelligence models such as ANFIS, ANN, GP, MLP, SVM, and DL algorithms find their place in the field of hydrology [13]. Application of ML tools such as ANN, VM and several prediction systems to flood forecasting appear to be more efficient than physical-based methods [14]. Many more studies on performance comparison of ML and DL models for flood forecasting have been conducted by several authors (Table 1).

Table 1 Performance comparison of ML and DL techniques for flood forecasting Modeling techniques Reference compared WASH123D, [15] HEC-HMS, SVM [16] LR, MLP, SVM, LSTM CNN, RNN, KNN, [17] MLP, SVM, DT, RF, LR ANN, SVR, DT, [18] RFA, LSTM ANFIS, SVM, GEP [19] [20] [21] [22] [23]

Input variables Radar rainfall Precipitation, Streamflow Temperature, rainfall intensity Rainfall

18 parameters MLR, MLP, ANFIS Climate signals AR, ANN, ANFIS Reservoir inflow ARMA, ANN, River flow ANFIS, GP, SVM discharge ANFIS, ANN, River flow, GRNN, FFNN, AR rainfall

Output variables Flood level

Prediction Best model type Hourly SVM for QPF Streamflow Daily LSTM

Region Taiwan USA

Flood

Monthly

CNN, KNN Iraq

Rainfall

Weekly

LSTM

Flood discharge Precipitation (SPI) Reservoir inflow River flow discharge River flow

Long term ANFIS, Iran SVM, GEP Long term MLP Iran

Malaysia

Monthly

ANFIS

Monthly

ANFIS, GP, Asia SVM ANFIS Turkey

Daily

India

146

A. A. A. Ari et al.

3 ML and DL Models 3.1 1D-CNN The weight sharing concept is the main difference between CNN and MLP [24]. Ghimire et al. [24] described Conv1D as follows: In one-dimensional CNN, the convolution kernels move in one direction. The input and output data of Conv1D are two-dimensional. The motivation of using this model is that Conv1D is suitable for time series and has powerful feature extraction capabilities, and Conv1D algorithms eliminate the manual feature extraction in conventional algorithms as mentioned by Ghimire et al. [24]. Figure 1 shows our Conv1D model. Convolutional layer and pooling layer are expressed by Eqs. (1) and (2), respectively [25]. gi = f

N 

.

 conv1D(wi,n , an ) + bi ,

(1)

n=1

where .gi is the result of the ith filter, a the input data of size .1 × Na × N, .wi the weight matrix of the ith filter, the size of which is .1 × Nw × N, and .bi and f the bias of the ith filter and the activation function, respectively. pi (j ) =

.

max

(ai (k)),

(j −1)×m 1 .0.65 < N SE > 0.75 .0.5 < N SE > 0.65 .N SE ≤ 0.5

P BI AS .P BI AS < ±10 .±10 ≤ P BI AS < ±15 .±15 ≤ P BI AS < ±25 .P BI AS ≥ ±25

.R

2

≥ 0.85 < R 2 ≤ 0.85 2 .0.60 < R ≤ 0.75 2 .R < 0.60 .R

2

.0.75

Table 3 Models’ performance criteria during training and test (short term) Models 1D-CNN LSTM MLP

Training N SE 0.93900 0.96945 0.89496

P BI AS 4.35361 1.06640 7.40411

.R

2

RMSE 0.96968 0.00655 0.98490 0.00462 0.94886 0.00855

Testing N SE P BI AS 0.90227 19.37708 0.95118 4.74773 0.88108 1.10791

.R

2

RMSE 0.96445 0.00608 0.97631 0.00429 0.93894 0.00670

Table 4 Models’ performance criteria during training and test (long term) Models 1D-CNN LSTM MLP

Training N SE 0.91624 0.94877 0.86972

P BI AS 4.18730 4.14095 2.32371

.R

2

RMSE 0.95789 0.00768 0.97460 0.00599 0.93332 0.00958

Testing N SE 0.84693 0.92954 0.81318

P BI AS 4.19780 1.54409 2.89724

.R

2

RMSE 0.92137 0.00760 0.96422 0.00516 0.90218 0.00840

5.3 Comparison of Models for Short-Term Flood Forecasting For short-term forecasting, 1D-CNN, LSTM, and MLP models were trained on the training dataset with a time lag of 2. Precipitation and temperature time series data from test dataset were used to test them. The performance criteria .(N SE, P BI AS, 2 .R and .RMSE) of the different models for training and test are presented in Table 3.

5.4 Comparison of Models for Long-Term Flood Forecasting All the models were trained on the training dataset with a time lag of 22. Table 4 shows the performance criteria of the different models for training and test.

6 Results and Discussion The 1D-CNN, LSTM and MLP models were designed, trained, and tested on rainfall and temperature time series data for short- and long-term flood forecasting. Table 3 shows the performance criteria .(N SE, P BI AS, .R 2 , and .RMSE) of the different models for short-term flood forecasting. The performance criteria of the different

154

A. A. A. Ari et al.

Fig. 6 Short-term forecasting—scatter plots of the best model for training (a) and test (b)

models for long-term flood forecasting are presented in Table 4. Figures 6 and 7 show the .R 2 scatter plots of the models for training and test. The comparison of the models for short-term flood forecasting shows that the best performing model is LSTM (Stacked). For long-term flood forecasting, a comparison of the performance criteria of the different models shows that the best performing model is still LSTM (Stacked) model. The results of the tests show that the Stacked LSTM models for short- and long-term forecasting have very good flood forecasting performance. These models, therefore, have a good generalization capacity that reflects the absence of underfitting and overfitting during training according to the values of P BI AS. NSE values show a strong correlation between the calculated and observed values, which means that selected models perform well. Similarly, the .R 2 and RMSE values of selected models show small variation between the calculated and observed values. Therefore, the goodness of fit of ML and DL models (1D-CNN, LSTM, and MLP) compared are in general good for both short- and long-term flood forecasts according to their performance criteria values (Tables 5 and 6).

Flood Forecasting in the Far-North Region of Cameroon: A Comparative Study. . .

155

Fig. 7 Short-term forecasting—Scatter plots of the best model for training (a) and test (b) Table 5 Performance criteria for the best model for short-term flood forecasting Model LSTM

Performance criteria N SE P BI AS 2 .R RMSE

Training 0.96945 1.06640 0.98490 0.00462

Testing 0.95118 4.74773 0.97631 0.00429

Goodness of fit Very Good Very Good Very Good Very Good

Table 6 Performance criteria for the best model for long-term flood forecasting Model LSTM

Performance criteria N SE P BI AS 2 .R RMSE

Training 0.94877 4.14095 0.97460 0.00599

Testing 0.92954 1.54409 0.96422 0.00516

Goodness of fit Very Good Very Good Very Good Very Good

7 Conclusion Floods are the most frequent natural hazards causing a huge loss of human lives, material and economic damage all over the world. Cameroon’s Far-North region has experienced several flood crises. In view of the above, there is a need to adopt effective and efficient flood risk management policies. The aim of this chapter was to design and compare the ML and DL methods for short- and long-term flood forecasting in the Far-North region of Cameroon. After designing, training, and

156

A. A. A. Ari et al.

testing the different models on monthly rainfall and temperature time series data, it appears that the best performing model for short- and long-term flood forecasting is the LSTM (Stacked). The goodness of fit of this model is very good. The LSTM model has good flood forecasting capabilities that reflect good generalization capabilities and the absence of underfitting/overfitting during training. Our findings can be used for the implementation of automatic flood warning systems in the FarNorth region of Cameroon. They can also be used to define effective and efficient flood risk management policies to avoid or limit loss of lives and material damage and make the Cameroon’s Far-North region more resilient to flood crises. Acknowledgments We would like to thank the editor and the anonymous reviewers for their valuable remarks that helped us in better improving the content and presentation of the paper. Moreover, the author is grateful for the facilities provided by the DAVID Lab UPSay-UVSQ and its kind hospitality.

Conflict of Interest Statement On behalf of all authors, the corresponding author states that there is no conflict of interest.

References 1. Dtissibe, F.Y., Ari, A.A.A., Titouna, C., Thiare, O., Gueroui, A.M.: Flood forecasting based on an artificial neural network scheme. Nat. Hazards 104(2), 1211–1237 (2020) 2. Falah, F., Rahmati, O., Rostami, M., Ahmadisharaf, E., Daliakopoulos, I.N., Pourghasemi, H.R.: Artificial neural networks for flood susceptibility mapping in data-scarce urban areas. In: Spatial Modeling in GIS and R for Earth and Environmental Sciences, pp. 323–336. Elsevier, Amsterdam (2019) 3. IFRC: World Disasters Report 2020: Come heat or high water, Tech. rep., International Federation of Red Cross and Red Crescent Societies (IFRC), Geneva (2020) 4. Simonov, Y.: Latest tools and methodologies for flood modeling (2017) 5. Ofoegbu, C., Chirwa, P.W.: Analysis of rural people’s attitude towards the management of tribal forests in South Africa. J. Sustain. For. 38(4), 396–411 (2019) 6. Tamiru, H., Dinka, M.O.: Application of ANN and HEC-RAS model for flood inundation mapping in lower Baro Akobo river basin, Ethiopia. J. Hydrol.: Reg. Stud. 36, 100855 (2021) 7. GFDRR: Evaluation de l’état du barrage, des digues, du réservoir et des structures hydrauliques du système de maga-logone-vrick. cameroun, Tech. rep. Global Facility for Disaster Reduction and Recovery (GFDRR) (2012) 8. Bouba, L., Sauvagnargues, S., Gonne, B., Ayral, P.-A., Ombolo, A.: Trends in rainfall and flood hazard in the Far North Region of Cameroon. Geo-Eco-Trop 41(3), 339–358 (2017) 9. UNISDR: Global assessment report on disaster risk reduction, Tech. rep., United Nations Office for Disaster Risk Reduction (UNISDR), Geneva (2019) 10. Gao, G., Li, Y., Li, J., Zhou, X., Zhou, Z.: A hybrid model for short-term rainstorm forecasting based on a back-propagation neural network and synoptic diagnosis. Atmos. Oceanic Sci. Lett. 14(5), 100053 (2021) 11. Ndam, N.A., Yefou, U.N., Ari, A.A.A., Rockeeller, Djedouboum, A.C., Abdou, W., Thiare, O.: Reinforcement learning-based dynamic path allocation in IoT systems. In: Ngatched, T.M.N., Woungang, I., Tapamo, J.R., Viriri, S. (eds). Pan-African Artificial Intelligence and Smart Systems. PAAISS 2022. Lecture Notes of the Institute for Computer Sciences, Social Informatics and Telecommunications Engineering, vol. 459. Springer, Cham, pp. 19–38 (2023)

Flood Forecasting in the Far-North Region of Cameroon: A Comparative Study. . .

157

12. Nevo, S., Morin, E., Gerzi Rosenthal, A., Metzger, A., Barshai, C., Weitzner, D., et al.: Flood forecasting with machine learning models in an operational framework. Hydrol. and Earth Syst. Sci. 26(15), 4013–4032 (2022) 13. Krajewski, W.F., Ghimire, G.R., Demir, I., Mantilla, R.: Real-time streamflow forecasting: AI vs. hydrologic insights. J. Hydrol. X 13, 100110 (2021) 14. Mosavi, A., Ozturk, P., Chau, K.-w.: Flood prediction using machine learning models: Literature review. Water 10(11), 1536 (2018) 15. Hussain, F., Wu, R.-S., Wang, J.-X.: Comparative study of very short-term flood forecasting using physics-based numerical model and data-driven prediction model. Nat. Hazards 107(1), 249–284 (2021) 16. Rahimzad, M., Moghaddam Nia, A., Zolfonoon, H., Soltani, J., Danandeh Mehr, A., Kwon, H.-H.: Performance comparison of an LSTM-based deep learning model versus conventional machine learning algorithms for streamflow forecasting. Water Resour. Manag. 35(12), 4167– 4187 (2021) 17. Idan, H.M., Hussein, K.Q.: Comparison study between selected techniques of (ML, SVM and deep learning) regarding prediction of flooding in east of Iraq. Turk. J. Comput. Math. Educ. (TURCOMAT) 12(14), 2893–2904 (2021) 18. Khairudin, N.B.M., Mustapha, N.B., Aris, T.N.B.M., Zolkepli, M.B.: Comparison of machine learning models for rainfall forecasting. In: 2020 International Conference on Computer Science and Its Application in Agriculture (ICOSICA), pp. 1–5. IEEE, New York (2020) 19. Ghaderi, K., Motamedvaziri, B., Vafakhah, M., Dehghani, A.A.: Regional flood frequency modeling: a comparative study among several data-driven models. Arab. J. Geosci. 12(18), 1–9 (2019) 20. Choubin, B., Khalighi-Sigaroodi, S., Malekian, A., Ki¸si, Ö.: Multiple linear regression, multi-layer perceptron network and adaptive neuro-fuzzy inference system for forecasting precipitation based on large-scale climate signals. Hydrol. Sci. J. 61(6), 1001–1009 (2016) 21. Lohani, A., Kumar, R., Singh, R.: Hydrological time series modeling: a comparison between adaptive neuro-fuzzy, neural network and autoregressive techniques. J. Hydrol. 442, 23–35 (2012) 22. Wang, W.-C., Chau, K.-W., Cheng, C.-T., Qiu, L.: A comparison of performance of several artificial intelligence methods for forecasting monthly discharge time series. J. Hydrol. 374(3– 4), 294–306 (2009) 23. Firat, M.: Comparison of artificial intelligence techniques for river flow forecasting. Hydrol. Earth Syst. Sci. 12(1), 123–139 (2008) 24. Ghimire, S., Yaseen, Z.M., Farooque, A.A., Deo, R.C., Zhang, J., Tao, X.: Streamflow prediction using an integrated methodology based on convolutional neural network and long short-term memory networks. Sci. Rep. 11(1), 1–26 (2021) 25. Liu, T., Xu, H., Ragulskis, M., Cao, M., Ostachowicz, W.: A data-driven damage identification framework based on transmissibility function datasets and one-dimensional convolutional neural networks: verification on a structural health monitoring benchmark structure. Sensors 20(4), 1059 (2020) 26. Hochreiter, S., Schmidhuber, J.: Long short-term memory. Neural Comput. 9(8), 1735–1780 (1997) 27. Ishida, K., Ercan, A., Nagasato, T., Kiyama, M., Amagasaki, M.: Use of 1D-CNN for input data size reduction of LSTM in hourly rainfall-runoff modeling, arXiv preprint arXiv:2111.04732 28. Hu, C., Wu, Q., Li, H., Jian, S., Li, N., Lou, Z.: Deep learning with a long short-term memory networks approach for rainfall-runoff simulation. Water 10(11), 1543 (2018) 29. Li, W., Gao, X., Hao, Z., Sun, R.: Using deep learning for precipitation forecasting based on spatio-temporal information: a case study. Climate Dynam. 58(1), 443–457 (2022) 30. Tamiru, H., Wagari, M.: Evaluation of data-driven model and GIS technique performance for identification of groundwater potential zones: a case of Fincha Catchment, Abay Basin, Ethiopia. J. Hydrol.: Reg. Stud. 37, 100902 (2021) 31. Cybenko, G.: Approximation by superpositions of a sigmoidal function. Math. Control. Signals Syst. 5(4), 455 (1992)

158

A. A. A. Ari et al.

32. Funahashi, K.-I.: On the approximate realization of continuous mappings by neural networks. Neural Netw. 2(3), 183–192 (1989) 33. Barron, A.R.: Universal approximation bounds for superpositions of a sigmoidal function. IEEE Trans. Inf. Theory 39(3), 930–945 (1993) 34. Cheo, A.: Understanding seasonal trend of rainfall for the better planning of water harvesting facilities in the Far-North Region, Cameroon. Water Utility J. 13, 3–11 (2016) 35. ONACC: Pluviométrie et température dans la région de l’extrême-nord cameroun: Analyse de l’évolution de 1950 à 2015 et projections jusqu’à l’horizon 2090, Tech. rep. Observatoire National sur les Changements Climatiques (ONACC). Yaoundé (2018) 36. Leumbe, O., Bitom, D., Mamdem, L., Tiki, D., Ibrahim, A.: Cartographie des zones à risques d’inondation en zone soudano-sahélienne: cas de maga et ses environs dans la région de l’extrême-nord cameroun. Afrique Science: Revue Internationale des Sciences et Technologie 11(3), 45–61 (2015) 37. Ghimire, G.R., Krajewski, W.F., Ayalew, T.B., Goska, R.: Hydrologic investigations of radarrainfall error propagation to rainfall-runoff model hydrographs. Adv. Water Resour. 161, 104145 (2022) 38. Fofana, M., Adounkpe, J., Larbi, I., Hounkpe, J., Koubodana, H.D., Toure, A., Maiga, H.B., Dotse, S.-Q., Limantol, A.M.: Urban flash flood and extreme rainfall events trend analysis in Bamako, Mali. Environ. Challenges 6, 100449 (2022) 39. Sattari, M.-T., Rezazadeh-Joudi, A., Kusiak, A.: Assessment of different methods for estimation of missing data in precipitation studies. Hydrol. Res. 48(4), 1032–1044 (2017) 40. Ouali, D., Cannon, A.: Estimation of rainfall intensity–duration–frequency curves at ungauged locations using quantile regression methods. Stoch. Env. Res. Risk A. 32(10), 2821–2836 (2018) 41. Pérez-Sánchez, J., Senent-Aparicio, J., Segura-Méndez, F., Pulido-Velazquez, D., Srinivasan, R.: Evaluating hydrological models for deriving water resources in Peninsular Spain. Sustainability 11(10), 2872 (2019) 42. Wang, Y., Liu, R., Guo, L., Tian, J., Zhang, X., Ding, L., Wang, C., Shang, Y.: Forecasting and providing warnings of flash floods for ungauged mountainous areas based on a distributed hydrological model. Water 9(10), 776 (2017)

A Multifactorial Approach to Explain Risk Features for Predicting Survival Rate of Heart Failure Ling Xue and Wei Lu

1 Introduction Heart failure (HF) is widely acknowledged as one of the most severe and fatal diseases impacting humans. It is a leading cause of hospitalization among elderly patients and presents multiple challenges in diagnosis, management, health service organization, and risk prediction. The increasing prevalence and high mortality rates associated with HF impose significant risks and burdens on healthcare systems worldwide. World Health Organization (WHO) data shows that heart disease accounts for one-third of global deaths. Within 1–2 years of diagnosis, approximately half of all heart disease patients succumb to the condition, and around 3% of the healthcare budget is allocated to treating heart disease [1]. Predicting heart diseases requires multiple tests, and accuracy in predictions can be compromised due to limited medical staff expertise [2]. Early detection of heart disease can be a challenging task [3]. Surgical treatment of heart disease presents particular difficulties, especially in developing countries where there may be a lack of trained medical personnel, testing equipment, and essential resources for accurate diagnosis and patient care [4]. Diagnosing heart health can be challenging due to various factors such as blood pressure, cholesterol, and creatine levels. Multiple factors contribute to heart disease, including alcohol consumption, smoking, diabetes, high

L. Xue Department of Health Management and Policy, University of New Hampshire, USNH, Durham, NH, USA W. Lu Department of Computer Science, Keene State College, USNH, The University System of New Hampshire, Keene, NH, USA e-mail: [email protected] © The Author(s), under exclusive license to Springer Nature Switzerland AG 2024 I. Woungang, S. K. Dhurandher (eds.), The 6th International Conference on Wireless, Intelligent and Distributed Environment for Communication, Lecture Notes on Data Engineering and Communications Technologies 185, https://doi.org/10.1007/978-3-031-47126-1_11

159

160

L. Xue and W. Lu

cholesterol, and lack of physical activity [6]. In recent years, EHRs have played a valuable role in clinical practice and research. They allow patients to record numerous diagnostic tests, invasive procedures, and therapies, generating substantial data. These data can be consolidated into registries or institutional databases to evaluate healthcare utilization, care quality, cost, and disease progression. Machine learning algorithms can also be applied to EHRs to diagnose heart disease and assess heart failure risk. This can aid in preventing severe heart attacks, improving patient safety, and reducing mortality rates [5]. Although machine learning-based expert systems have demonstrated their effectiveness in disease identification when trained on appropriate data [8], the inconsistency and redundancy present in clinical datasets emphasize the importance of adequate preprocessing [7]. It is crucial to select significant risk factors as features in prediction models and carefully consider the appropriate combination of features and machine learning algorithms to ensure accurate predictions [9]. To address this concern, our chapter investigates a multifactorial statistical analysis to explain the risk features for predicting the survival rate of heart failure using the multiple logistic regression model. Specifically, we explore the following four questions: (1) What are the contributing risk factors to survival after heart failure treatment among smokers and non-smokers? (2) Which risk factors are most significant for patients’ survival based on the presence or absence of high blood pressure? (3) What are the risk factors for patients with or without diabetes? (4) Which factors pose the highest risk for patients with or without anemia? Our visualization results, using data from a publicly available clinical heart failure dataset, reveal that diabetes, high blood pressure, smoking, and anemia do not directly contribute to the occurrence of heart failure-related deaths. However, within each category of smokers/non-smokers, high blood pressure/no high blood pressure, diabetes/no diabetes, anemia/no anemia, the attributes of age, ejection fraction, and serum creatinine significantly influence the prediction of survival rates after heart failure treatment. The remaining sections of the chapter are structured as follows: In Sect. 2, we summarize the existing literature on employing machine learning techniques for predicting the survival rate of heart failure. Section 3 presents a descriptive analysis of a publicly available medical dataset comprising 299 heart failure patients. In this section, we visualize the relationship between each feature and the target variable, which represents the occurrence of death. Section 4 focuses on feature selection for identifying significant features among patients with diabetes, high blood pressure, smoking, and anemia. Finally, Section 5 concludes the chapter with future works.

2 Related Works Heart failure has a global annual impact on approximately 26 million individuals, presenting challenges for accurate prediction within the medical field involving cardiologists and surgeons. The search for effective treatments is a time-consuming process mainly due to its high cost. In a study by Almazroi [10], machine learning

A Multifactorial Approach to Explain Risk Features for Predicting Survival. . .

161

models for heart failure prediction are proposed. The study compares the accuracy of various algorithms and boosting techniques, focusing on 12 cardiovascular diseases, including heart failure. The experimental evaluation indicates that decision trees outperform logistic regression, support vector machines, and artificial neural networks. Another study by Grgi´c [11] focuses on analyzing cardiovascular parameters in patients with heart disease to predict mortality. The study employs random forest and logistic regression algorithms to predict death based on 12 parameters. Both algorithms are fine-tuned to determine the optimal settings. Comparative analysis of the results reveals that the random forest algorithm achieves the highest accuracy of 90%. In a recent study by Mpanya et al. [12], they concentrate on using machine learning to predict all-cause mortality in heart failure patients hospitalized in a tertiary academic center. The primary objective is to showcase the usefulness of machine learning in risk stratification for heart failure patients, particularly in lowand middle-income countries (LMIC), where the age of onset and causes of heart failure may differ. Six supervised machine learning algorithms were trained, with support vector machines (SVM) emerging as the best-performing algorithm [19]. Noteworthy factors such as medication use, clinical signs, and electrocardiogram findings were identified as having positive or negative coefficients concerning the target feature. In another study by Ahmed et al. [13], the aim is to enhance heart failure prediction by applying classification and prediction models to medical data. By extracting data from a medical database and employing machine learning techniques, the study achieves high precision in predicting the probability of heart failure. Among the evaluated models, logistic regression, SVM, KNN [20], GNB, and MNB demonstrate good performance, with the highest accuracy of 82.76%. Furthermore, in [14], Ali et al. propose using machine learning for risk factor analysis and survival prediction in heart failure patients utilizing a survival dataset. Five supervised machine learning methods are applied and compared based on performance metrics, including decision tree, decision tree regressor, random forest, XGBoost [21], and gradient boosting. The random forest algorithm outperforms other models, achieving the highest accuracy. The study concludes that the proposed ML model can accurately predict heart failure survival and holds potential value in clinical settings for screening patients with a probability of heart failure. In comparing the experimental evaluation results of using machine learning for predicting patients’ heart failure, a notable observation is the contradiction among the findings, even when using the same dataset, as summarized in Table 1. This inconsistency primarily stems from the differing approaches to feature selection employed in these experiments. Some studies opt for a small subset of features, while others utilize the entire set of features available in the dataset. Addressing this issue of disparate feature selection methods is the focus of the subsequent sections in this chapter.

162

L. Xue and W. Lu

Table 1 Best performing models identified in related works Literature [11] [12] [13] [14] [15]

Best performing machine learning model with the same benchmark dataset Decision trees Random forest Support vector machines Logistic regression Random forest

Table 2 Parameter estimates Feature name Sex Anemia High blood pressure Smoking Diabetes Ejection fraction Platelets Age Serum creatinine Serum sodium Creatinine phosphokinase (CPK) Time Death event

Descriptions Man or woman Decrease of red blood cells or hemoglobin If the patient has hypertension or not If the patient smokes or not If the patient has diabetes or not Percentage of blood leaving the heart at each contraction (%) Platelets in the blood in the unit of kilo platelets/mL Age of the patient Level of serum creatinine in the blood in the unit of mg/dL Level of serum sodium in the blood in the unit of mEq/L Level of the CPK enzyme in the blood in the unit of mcg/L Follow-up period, number of days If the patient deceased during the follow-up period or not

3 Descriptive Statistics on Clinical Heart Failure Dataset This chapter’s research revolves around a publicly available dataset concerning patients with and without heart failure, comprising 13 clinical features [15]. Table 2 provides detailed information about these 13 clinical features. Table 3 presents the basic descriptive statistics for the attributes with numerical values, including age, creatinine phosphokinase (CPK), ejection fraction, platelets, serum creatinine, serum sodium, and time. For instance, as depicted in Table 3, we can observe that the mean age of the patients is 60.83, with a standard deviation of 11.895. The minimum age recorded in the dataset is 40, while the maximum age is 95. Upon examining Table 3, it becomes apparent that attributes such as creatinine phosphokinase (CPK), platelets, and serum creatinine likely contain outliers. This inference is drawn based on data points exceeding 1.5 times the interquartile range (IQR) above the third quartile. To elaborate, taking CPK as an example, the first quartile value is 116.5, and the third quartile value is 582, resulting in an IQR of 465.5 (582–116.5). The maximum CPK level recorded is 7861, which significantly exceeds the threshold of 1280.25 (582 + 1.5 * 465.5), indicating the presence of outliers.

A Multifactorial Approach to Explain Risk Features for Predicting Survival. . .

163

Table 3 Descriptive statistics for the attributes with numerical values Descriptive statistics Features Mean Age 60.83 CPK 581.84 Ejection_fraction 38.08 Platelets 263358.03 Serum_creatinine 1.39 Serum_sodium 136.63 Time 130.26 Table 4 Patients’ smoking vs. survived or not: two-way table

Table 5 Patients’ anemia vs. survived or not: two-way table

Std 11.895 970.29 11.83 97804.24 1.03 4.12 77.61

Min 40.0 23.0 14.0 25100.0 0.5 113.0 4.0

25% 51.0 116.5 30.0 212500.0 0.9 134.0 73.0

50% 60.0 250.0 38.0 262000.0 1.1 137.0 115.00

75% 70.0 582.0 45.0 303500.0 1.4 140.0 203.0

Max 95.0 7861.0 80.0 850000.0 9.4 148.0 285.0

Survived Deceased

Non-smoking 137 66

Patient smokes 66 30

Survived Deceased

Anemia (no) 120 50

Anemia (yes) 83 46

The remaining six attributes in the dataset are of Boolean or binary type, taking values of 1 or 0 and representing true or false. These attributes include anemia (Boolean type, where 1 indicates the presence of anemia and 0 indicates its absence), high blood pressure (Boolean type, with 1 indicating hypertension and 0 representing the absence of hypertension), diabetes (Boolean type, where 1 indicates the presence of diabetes and 0 indicates its absence), sex (binary type, where 1 denotes male and 0 denotes female), smoking (Boolean type, where 1 indicates smoking and 0 represents non-smoking), and death_event (Boolean type, where 1 signifies patient decease during the follow-up period and 0 indicates patient survival during the follow-up period). To explore the relationship between each Boolean attribute and the target variable death_event, 2-way frequency tables are created. Table 4 specifically illustrates the relationship between smoking status and patient survival. As described in Table 4, among the 96 deceased patients, 66 were non-smokers, and 30 were smokers. Among the 203 surviving patients, 66 were smokers, and 137 were non-smokers. This information provides insights into the distribution of smoking status among deceased and surviving patients. Table 5 demonstrates the relationship between anemia in patients and their survival. As depicted in Table 5, among the 96 deceased patients, 50 did not have anemia, while 46 had anemia. Among the 203 surviving patients, 120 did not have anemia, while 83 had anemia. This data provides insights into the distribution of anemia status among deceased and surviving patients. Table 6 presents the relationship between diabetes in patients and their survival. According to Table 6, among the 96 deceased patients, 56 did not have diabetes,

164 Table 6 Patients’ diabetes vs. survived or not: two-way table

Table 7 Patients’ hypertension vs. survived or not: two-way table

L. Xue and W. Lu

Survived Deceased

Survived Deceased

Diabetes (no) 118 56 Hypertension (no) 137 57

Diabetes (yes) 85 40 Hypertension (yes) 66 39

while 40 had diabetes. Among the 203 surviving patients, 118 did not have diabetes, while 85 had diabetes. This information provides insights into the distribution of diabetes status among deceased and surviving patients. Table 7 depicts the correlation between high blood pressure and patient survival. According to Table 7, out of the 96 surviving patients, 57 did not have high blood pressure, while 39 did. Similarly, among the 203 patients who unfortunately passed away, 137 did not have high blood pressure, whereas 66 did. Upon comparing the two-way tables in Tables 4, 5, 6, and 7, we can deduce that the binary factors of smoking, high blood pressure, diabetes, and anemia do not appear to significantly contribute to patient mortality caused by heart failure. This lack of significance can primarily be attributed to a sampling issue during data collection. The correlation matrix further supports our observation that the dataset predominantly comprises healthy patients. Consequently, we categorize the dataset into four groups: smoking vs. non-smoking, hypertension vs. non-hypertension, anemia vs. non-anemia, and diabetes vs. non-diabetes.

4 Feature Selection Table 2 summarizes the heart failure dataset, consisting of 13 raw features, where two pseudo features, namely, sex and time, are used solely for defining patient gender and follow-up periods. Hence, these two features need to be excluded when selecting significant features. The Boolean features anemia, smoking, diabetes, and high blood pressure are utilized for categorizing patients. The target variable, death_event, is not considered part of the feature selection process. Consequently, six features are utilized for feature selection, categorized within each patient group. The framework of our feature selection methodology is presented in Table 8, where the input comprises six features distributed across eight groups: smoking vs. nonsmoking, diabetes vs. non-diabetes, hypertension vs. non-hypertension, and anemia vs. non-anemia. We established a significance threshold p-value of 0.05 to conduct feature selection among smoking patients. Using a regression model, we fitted all six features and obtained the results illustrated in Table 9. It is evident from Table 9 that serum_creatinine has the largest p-value of 0.4146, exceeding the significance

A Multifactorial Approach to Explain Risk Features for Predicting Survival. . .

165

Table 8 Feature selection by patients’ category Group 1 Group 2 Group 3 Group 4

Smoking (96) Non-smoking (203) Diabetes (125) Non-diabetes (174) Hypertension (105) Non-hypertension (194) Anemia (129) Non-anemia (170)

Ejection fraction Platelets Age Serum creatinine Serum sodium CPK

Table 9 Parameters estimates for six features from smoking patients

Term Age CPK Ejection_fraction Platelets Serum_creatinine Serum_sodium

Table 10 Parameters estimates for selected features from smoking patients

Term Age Ejection_fraction

Estimate 0.097 −0.00024 −0.094 0.00000377 0.322 −0.072 Estimate 0.091 −0.091

P-value 0.0004 0.3915 0.0019 0.1306 0.4146 0.2390 P-value 0.0003 0.0012

threshold. Consequently, we removed serum_creatinine and re-ran the feature selection model. In the subsequent iteration, we found that the p-value for feature CPK was 0.3118, the highest among all the features and considerably greater than 0.05. As a result, we decided to remove CPK as well. We repeated this process, eliminating variables that did not meet the significance threshold in the order of serum_sodium and platelets. Finally, we obtained a model containing only the significant features, namely, age and ejection fraction, as depicted in Table 10. Following the same modeling fit process described earlier, we applied it to patients without smoking. Assuming a significance threshold p-value of 0.05, the parameter estimates with the six features are presented in Table 11. From Table 11, we observe that the feature platelets has a p-value of 0.2564, which exceeds the threshold of 0.05. Consequently, we excluded this feature and performed iterative runs of the feature selection model. Subsequently, we removed serum_sodium and CPK, which did not meet the significance threshold. Finally, we obtained a model containing only the significant features: age, ejection fraction, and serum creatinine. These features are depicted in Table 12. To perform feature selection among patients with diabetes, we applied a significance threshold p-value of 0.05 and utilized a regression model to fit all six features. The result of this modeling fit is depicted in Table 13. From Table 13, we can observe that platelets have the largest p-value of 0.8122, exceeding the significance threshold. Therefore, we removed platelets and re-ran the feature selection model.

166

L. Xue and W. Lu

Table 11 Parameters estimates for six features from non-smoking patients

Term Age CPK Ejection_fraction Platelets Serum_creatinine Serum_sodium

Table 12 Parameters estimates for selected features from non-smoking patients

Term Age Ejection_fraction Serum_creatinine

Table 13 Parameters estimates for six features from patients with diabetes

Term Age CPK Ejection_fraction Platelets Serum_creatinine Serum_sodium

Table 14 Parameters estimates for selected features from patients with diabetes

Term Age Ejection_fraction Serum_creatinine

Estimate 0.0444 0.00036 −0.06 −0.00000224 0.677 −0.056 Estimate 0.039 −0.063 0.710 Estimate 0.058 0.0003 −0.045 −0.00000052 0.651 −0.038 Estimate 0.0533 −0.047 0.714

P-value 0.0028 0.0449 0.0005 0.2564 0.0009 0.1592 P-value 0.0065 0.0001 0.0002 P-value 0.0070 0.1918 0.0373 0.8122 0.0329 0.3513 P-value 0.0107 0.0270 0.0138

In the subsequent iteration, we found that the p-value for feature serum_sodium was 0.3524, the highest among all the features and considerably greater than 0.05. Hence, we decided to remove serum_sodium as well. We repeated this process, removing CPK, which did not meet the significance threshold. Eventually, we obtained a model comprising only the significant features, age and ejection fraction, as illustrated in Table 14. Applying the same modeling fit process described earlier, we directed our attention to patients without diabetes. Assuming a significance threshold p-value of 0.05, we obtained the parameter estimates for the six features, as displayed in Table 15. From Table 15, it is apparent that the feature platelets has a p-value of 0.7828, surpassing the threshold of 0.05. Consequently, we removed platelets and conducted iterative runs of the feature selection model. Subsequently, we eliminated CPK and serum_sodium, as they did not meet the significance threshold. Finally, we obtained a model consisting solely of the significant features: age, ejection fraction, and serum creatinine. These features are illustrated in Table 16. To conduct feature selection among patients with anemia, we applied a significance threshold p-value of 0.05 and employed a regression model to fit all six

A Multifactorial Approach to Explain Risk Features for Predicting Survival. . . Table 15 Parameters estimates for six features from patients without diabetes

Term Age CPK Ejection_fraction Platelets Serum_creatinine Serum_sodium

Estimate 0.053 0.0002 −0.082 0.00000061 0.629 −0.073

Table 16 Parameters estimates for selected features from patients without diabetes

Term Age Ejection_fraction Serum_creatinine

Estimate 0.0533 −0.087 0.679

Table 17 Parameters estimates for six features from patients with anemia

Term Age CPK Ejection_fraction Platelets Serum_creatinine Serum_sodium

Estimate 0.057 −0.0002 −0.0643 −0.00000045 0.53 −0.079

Table 18 Parameters estimates for selected features from patients with anemia

Term Age Ejection_fraction Serum_creatinine

Estimate 0.0561 −0.066 0.585

167 P-value 0.0011 0.3526