## 4 Machine Learning and LoRaWAN
### Ensemble Learning, ML, and AI Based Techniques  
The study [30] addressed performance degradation in LPWAN technologies, which was caused by congestion and interference. The authors stated that rule-based approaches for assigning and adapting device parameters were found to be insufficient in terms of large-scale IoT deployments, specifically the ADR algorithm in LoRaWAN. The authors have suggested a novel approach for allocating resources in LoRaWAN by using supervisedML for transmission power allocation and reinforcement learning (RL) for SF allocation. The EXP4 method was used for SF allocation in the study, while a variation in the Lasso algorithm was used for transmission power (TP) allocation. The authors evaluated their approach by using experimental data generated from the LoRaSim python simulator for LoRaWAN IoT networks. They also used PySimulator to monitor the traffic load and evaluate the proposed performance of the algorithms. Results showed that the proposed approach demonstrated approximately ten times faster convergence than the LoRaMAB EDR and the LoRaWAN ADR algorithms. In a LoRaWAN network, mutual interference between wireless nodes can result in packet collisions and a drop in packet delivery rate (PDR). To address this issue, the authors of the study [47] proposed a ML-based Q-learning approach to efficiently allocate channels and enhance PDR. They used the weighted sum of successfully received packets as the Q-reward when applying Q-learning to the LoRaWAN system. The gateway allocated the parameters such as packet size, Q-factor, Q-reward, and discount factor to maximize this Q-reward. The performance of the proposed approach was tested by the authors using the ns-3 simulator, in which they created a synthetic dataset of randomly positioned nodes for evaluation. MATLAB was used to assess simulation results and generate plots. The findings showed that the proposed strategy has improved average PDR performance by around 20% as compared to random resource allocation methods. The authors of the study [48] addressed the need for precise outdoor localization techniques in LPWAN technologies such as Sigfox and LoRaWAN. They proposed an approach for outdoor positioning based on ensemble learning that combines exact timestamps with nanosecond signal strength. The proposed approach aimed to improve positioning accuracy so that an accurate localization would not need additional bandwidth. They configured a combined approach called KNN-RFR, which used k-nearest neighbors (kNN) integrated with the Random Forest Regressor (RFR). Results showed an improvement of 16% and 29% for mean and median error, respectively. The authors used MATLAB, Python, and LoRaSim, along with a real-world outdoor dataset composed of LoRaWAN features. The authors stated that the proposed method offered improved scalability and lower power consumption. The authors of the study [49] addressed the problem of efficient management of IoT devices that have different velocities in dense LoRa networks. The authors proposed the LoRaDRL algorithm to enhance the PDR and to support the mobility of end-devices (EDs). The authors also aimed to utilize the same method to reduce energy usage and collisions. LoRaDRL has used DRL and cognitive radio systems to dynamically modify the SF of EDs based on channel usage and signal-to-interference-and-noise ratio (SINR) conditions. The algorithm also used Q-learning to determine optimal actions for SF adjustment while considering factors such as SFs that are currently available, current channel conditions, and channel availability. The authors have used a dataset from the dense LoRa network in Lahore, and experiments are executed using NS-3, MATLAB, and Python. LoRaDRL demonstrated resistance to widespread frequency jamming attempts as well as a 500% improvement in PDR. The study [50] addressed the issue of energy consumption (EC) in LoRaWAN and evaluated its efficiency using metrics such as PDR, EC, and coverage area.