Machine Learning Approaches to Detect DoS and Their Effect on WSNs Lifetime | Synapse