Analyzing the Effectiveness and Contribution of Each Axis of Tri-Axial Accelerometer Sensor for Accurate Activity Recognition
Abstract
:1. Introduction
- Investigates the effectiveness and contribution of each axis of the accelerometer for activity recognition.
- Proposes an approach to recognize the activities using only two axes of an accelerometer, resulting in fast and accurate recognition of physical activities.
- Presents an evaluation of variants of the sliding window.
- In addition to our own collected dataset, the proposed approach was tested and evaluated extensively on a standard publicly available dataset WISDM [31] used in state-of-the-art studies.
2. Literature Review
3. Proposed Methodology
3.1. Data Collection
3.2. Preproscessing
3.3. Feature Extraction
3.4. Data Balancing
3.5. Activity Recognition
- Decision Tree (J48): J48 classifier builds the trees based on their information gain (IG) and entropy [51]. It compares the IG of all the features and split the tree with the feature having the best IG.
- Logistic Regression (LR) LR is used for classification by adding some parameters in linear regression algorithm like adding sigmoid function and threshold if the value is higher then 0.5 it will be yes and if the value of predicator is less then 0.5 it will go to no class [51]. The logistic regression algorithm uses the logistic function of fitting a straight line or hyperplane to squeeze the output of a linear equation between 0 and 1.The mathematical definition of logistic regression is given below:This research modelled the affiliation between outcome and attributes with the linear equations in the linear regression classifier.Logistic regression prefers the probability between 0 and 1 for classification, so we put the right side of the equation into logistic regression function. This emphasizes the output to assume values between 0 and 1.The above equation represents the log function for logistic regression, also called the log odd function. This theorem shows that the concept of logistic regression is a linear model for log changes. If one of the attribute is changed by one element, prediction changes.We then compare what happens if one of the feature values is increased by 1, yet we look at the ratio of the two projections rather than looking at the difference:Finally, a one-unit change in a feature changes the odds ratio by an exp factor (). This can also be represented as a one-unit shift in increases the log odds ratio by the same weight factor. Many research studies interpreted the odds ratio because it is understood that thinking about something’s log () is difficult to comprehend.
- Multilayer Neural Network (MLP): MLP is a feed-forward neural network, that maps the inputs to an appropriate set of outputs [51]. Typically, the network consists of an input layer, a hidden layer(s), and an output layer as shown in Figure 3. Given an input node , the output of the hidden node is given asThe mapping of inputs to outputs is an iterative process, where in each iteration, weights are updated. One of the commonly used algorithm is the Back Propagation algorithm, which updates the weights using
4. Evaluation and Analysis
4.1. Evaluation Measures
4.2. Results
4.3. Axis Analysis of Activities
- Walking: Figure 9a depicts that the periodic pattern of walking activity is quite similar to Figure 9b. While walking upward and downward periodic motion can be seen as light blue strides while the forward motion can be seen in purple strides and red lines showing horizontal movement is stable. The value of the x-axis lies between , y-axis value & the value of z-axis lies between which is quite unique. These observations can be proven by Table 3 and Figure 10 depicting a combination of the different axis of the accelerometer to recognize the activities. In Table 3 the recognition rate of walking activity against axis is %, axis is %, axis is %, and is %. Hence, for walking activity, the y-axis and z-axis of the accelerometer sensor are the potential features.
- Jogging: Figure 9b depicts periodic patterns quite similar to the Figure 9a. Upward and downward motion can be seen as light blue strides while the forward motion can be seen in purple strides which are quite high than walking and red lines showing horizontal movements are stable. In Table 3, it is shown that the recognition rate of jogging activity against axis is %, axis is %, axis is %, and is %. Hence for this activity y-axis and z-axis of the accelerometer sensor are the potential features. By looking at accelerometers detected readings, it shows that the range of x-axis falls between , y-axis value and the value of z-axis lies between . In the previous case, the same type of results are obtained which further strengthen our observations.
- Upstairs: The patterns in Figure 9c are quite similar to the Figure 9b of jogging. While going upstairs, upward and downward motion can be seen as light blue strides while the forward motion can be seen in purple strides and red lines showing horizontal movements are stable. This activity is getting confused with jogging activity as the only difference between both is of the z-axis. There is a high upward positive peak and downward negative peak after a specific periodic interval which depicts that a user stepped up a stair and then suddenly it goes to the initial stage. The range of x-axis lies between , y-axis between and z-axis lies between , which is quite similar to the jogging. In Table 3, it is shown that the recognition rate of upstairs activity against axis is %, axis is %, axis is %, and is %. Hence, for this activity, y-axis and z-axis of the accelerometer sensor are the potential features.
- Downstairs: Figure 9d depicts that the periodic patterns are slightly similar to the Figure 9b. Each small peak represents movement down a single stair. The z-axis values show a similar pattern showing negative readings, reflecting the regular movement down each stair which was positive in the previous case (upstairs). While walking downstairs, downward motion can be seen as light blue strides which show a negative axis while the forward motion can be seen in purple strides and red lines, showing horizontal movements that are stable in the start but suddenly it shows a high read peak which turns a mentioned earlier in the dataset collection section. The range of x-axis falls between , y-axis between and the range of z-axis lies between , which is quite similar to the Upstairs. In Table 3, it is shown that the recognition rate of upstairs activity against axis is %, axis is %, axis is %, and is %. Hence for this activity y-axis and z-axis of the accelerometer sensor are the potential features.
- Sitting: Figure 9e depicts that all reading against each axis is, constant and stable patterns without any regular periodic pattern. This activity shows a unique behavior. By looking at accelerometers detected outputs, we observe that the range of x-axis lies between , y-axis value and the value of z-axis lies between . In Table 3, it is shown that the recognition rate of upstairs activity against axis is %, axis is %, axis is %, and is %. Hence for this activity, y-axis and z-axis of the accelerometer sensor are the potential features.
- Standing: This activity also shows a unique behavior as depicted in Figure 9f. It is seen that accelerometer readings are constant and depicts stable patterns without any regular periodic pattern. The range of x-axis lies between , y-axis value and the value of z-axis lies between . In Table 3, it is shown that the recognition rate of upstairs activity against axis is %, axis is %, axis is %, and is %. Hence, for this activity y-axis and z-axis of the accelerometer sensor are the potential features.
4.4. Comparative Analysis
5. Conclusions and Future Work
Author Contributions
Funding
Conflicts of Interest
References
- Kivimäki, M.; Singh-Manoux, A.; Pentti, J.; Sabia, S.; Nyberg, S.T.; Alfredsson, L.; Goldberg, M.; Knutsson, A.; Koskenvuo, M.; Koskinen, A.; et al. Physical inactivity, cardiometabolic disease, and risk of dementia: An individual-participant meta-analysis. BMJ 2019, 365, l1495. [Google Scholar] [CrossRef] [Green Version]
- Bao, L.; Intille, S.S. Activity recognition from user-annotated acceleration data. In International Conference on Pervasive Computing; Springer: Berlin/Heidelberg, Germany, 2004; pp. 1–17. [Google Scholar]
- Kwapisz, J.R.; Weiss, G.M.; Moore, S.A. Activity recognition using cell phone accelerometers. ACM SigKDD Explor. Newsl. 2011, 12, 74–82. [Google Scholar] [CrossRef]
- Bulling, A.; Blanke, U.; Schiele, B. A tutorial on human activity recognition using body-worn inertial sensors. ACM Comput. Surv. (CSUR) 2014, 46, 1–33. [Google Scholar] [CrossRef]
- Lockhart, J. Mobile sensor data mining. Fordham Undergrad. Res. J. 2013, 1, 11. [Google Scholar]
- Kuspa, K.; Pratkanis, T. Classification of Mobile Device Accelerometer Data for Unique Activity Identification; Technical Report; Stanford Center for Professional Development: Palo Alto, CA, USA, 2013. [Google Scholar]
- Zeng, M.; Nguyen, L.T.; Yu, B.; Mengshoel, O.J.; Zhu, J.; Wu, P.; Zhang, J. Convolutional neural networks for human activity recognition using mobile sensors. In Proceedings of the 6th International Conference on Mobile Computing, Applications and Services, Austin, TX, USA, 6–7 November 2014; pp. 197–205. [Google Scholar]
- Kolosnjaji, B.; Eckert, C. Neural network-based user-independent physical activity recognition for mobile devices. In Proceedings of the International Conference on Intelligent Data Engineering and Automated Learning, Wroclaw, Poland, 14–16 October 2015; pp. 378–386. [Google Scholar]
- Ignatov, A.D.; Strijov, V.V. Human activity recognition using quasiperiodic time series collected from a single tri-axial accelerometer. Multimed. Tools Appl. 2016, 75, 7257–7270. [Google Scholar] [CrossRef]
- Cook, D.J.; Augusto, J.C.; Jakkula, V.R. Ambient intelligence: Technologies, applications, and opportunities. Pervasive Mob. Comput. 2009, 5, 277–298. [Google Scholar] [CrossRef] [Green Version]
- Wang, L.; Gu, T.; Tao, X.; Lu, J. A hierarchical approach to real-time activity recognition in body sensor networks. Pervasive Mob. Comput. 2012, 8, 115–130. [Google Scholar] [CrossRef]
- Kumari, A.; Tanwar, S.; Tyagi, S.; Kumar, N. Fog computing for Healthcare 4.0 environment: Opportunities and challenges. Comput. Electr. Eng. 2018, 72, 1–13. [Google Scholar] [CrossRef]
- Sarwar, M.U.; Javed, A.R. Collaborative Health Care Plan through Crowdsource Data using Ambient Application. In Proceedings of the 2019 22nd International Multitopic Conference (INMIC), Islamabad, Pakistan, 29–30 November 2019; pp. 1–6. [Google Scholar]
- Wang, J.; Chen, Y.; Hao, S.; Peng, X.; Hu, L. Deep learning for sensor-based activity recognition: A survey. Pattern Recognit. Lett. 2019, 119, 3–11. [Google Scholar] [CrossRef] [Green Version]
- Ignatov, A. Real-time human activity recognition from accelerometer data using Convolutional Neural Networks. Appl. Soft Comput. 2018, 62, 915–922. [Google Scholar] [CrossRef]
- Jordao, A.; Torres, L.A.B.; Schwartz, W.R. Novel approaches to human activity recognition based on accelerometer data. Signal Image Video Process. 2018, 12, 1387–1394. [Google Scholar] [CrossRef]
- Wannenburg, J.; Malekian, R. Physical activity recognition from smartphone accelerometer data for user context awareness sensing. IEEE Trans. Syst. Man Cybern. Syst. 2016, 47, 3142–3149. [Google Scholar] [CrossRef]
- Morillo, L.M.S.; Gonzalez-Abril, L.; Ramirez, J.A.O.; la Concepcion, D.; Alvarez, M.A. Low energy physical activity recognition system on smartphones. Sensors 2015, 15, 5163–5196. [Google Scholar] [CrossRef] [PubMed] [Green Version]
- Su, X.; Tong, H.; Ji, P. Activity recognition with smartphone sensors. Tsinghua Sci. Technol. 2014, 19, 235–249. [Google Scholar]
- Javed, A.R.; Beg, M.O.; Asim, M.; Baker, T.; Al-Bayatti, A.H. AlphaLogger: Detecting motion-based side-channel attack using smartphone keystrokes. J. Ambient. Intell. Humaniz. Comput. 2020, 1–14. [Google Scholar] [CrossRef] [Green Version]
- Shoaib, M.; Bosch, S.; Incel, O.D.; Scholten, H.; Havinga, P.J. Fusion of smartphone motion sensors for physical activity recognition. Sensors 2014, 14, 10146–10176. [Google Scholar] [CrossRef]
- Pei, L.; Guinness, R.; Chen, R.; Liu, J.; Kuusniemi, H.; Chen, Y.; Chen, L.; Kaistinen, J. Human behavior cognition using smartphone sensors. Sensors 2013, 13, 1402–1424. [Google Scholar] [CrossRef]
- Du, R.; Santi, P.; Xiao, M.; Vasilakos, A.V.; Fischione, C. The sensable city: A survey on the deployment and management for smart city monitoring. IEEE Commun. Surv. Tutor. 2018, 21, 1533–1560. [Google Scholar] [CrossRef]
- Iwendi, C.; Khan, S.; Anajemba, J.H.; Bashir, A.K.; Noor, F. Realizing an Efficient IoMT-Assisted Patient Diet Recommendation System Through Machine Learning Model. IEEE Access 2020, 8, 28462–28474. [Google Scholar] [CrossRef]
- Huang, M.; Liu, A.; Xiong, N.N.; Wang, T.; Vasilakos, A.V. An Effective Service-Oriented Networking Management Architecture for 5G-Enabled Internet of Things. Comput. Netw. 2020, 173, 107208. [Google Scholar] [CrossRef]
- Chen, M.; Gonzalez, S.; Vasilakos, A.; Cao, H.; Leung, V.C. Body area networks: A survey. Mob. Networks Appl. 2011, 16, 171–193. [Google Scholar] [CrossRef]
- Wazid, M.; Das, A.K.; Kumar, N.; Conti, M.; Vasilakos, A.V. A novel authentication and key agreement scheme for implantable medical devices deployment. IEEE J. Biomed. Health Inform. 2017, 22, 1299–1309. [Google Scholar] [CrossRef] [PubMed]
- Acampora, G.; Cook, D.J.; Rashidi, P.; Vasilakos, A.V. A survey on ambient intelligence in healthcare. Proc. IEEE 2013, 101, 2470–2494. [Google Scholar] [CrossRef] [PubMed] [Green Version]
- Cao, L.; Wang, Y.; Zhang, B.; Jin, Q.; Vasilakos, A.V. GCHAR: An efficient Group-based Context—Aware human activity recognition on smartphone. J. Parallel Distrib. Comput. 2018, 118, 67–80. [Google Scholar] [CrossRef]
- Wazid, M.; Das, A.K.; Bhat, V.; Vasilakos, A.V. LAM-CIoT: Lightweight authentication mechanism in cloud-based IoT environment. J. Netw. Comput. Appl. 2020, 150, 102496. [Google Scholar] [CrossRef]
- Wisdm’s Activity Prediction Dataset. Available online: http://www.cis.fordham.edu/wisdm/dataset.php (accessed on 12 March 2020).
- Miao, F.; He, Y.; Liu, J.; Li, Y.; Ayoola, I. Identifying typical physical activity on smartphone with varying positions and orientations. Biomed. Eng. Online 2015, 14, 32. [Google Scholar] [CrossRef] [Green Version]
- Nakano, K.; Chakraborty, B. Effect of dynamic feature for human activity recognition using smartphone sensors. In Proceedings of the 2017 IEEE 8th International Conference on Awareness Science and Technology (iCAST), Taichung, Taiwan, 8–10 November 2017; pp. 539–543. [Google Scholar]
- Sheng, Z.; Yang, S.; Yu, Y.; Vasilakos, A.V.; McCann, J.A.; Leung, K.K. A survey on the ietf protocol suite for the internet of things: Standards, challenges, and opportunities. IEEE Wirel. Commun. 2013, 20, 91–98. [Google Scholar] [CrossRef]
- Wazid, M.; Das, A.K.; Vasilakos, A.V. Authenticated key management protocol for cloud-assisted body area sensor networks. J. Netw. Comput. Appl. 2018, 123, 112–126. [Google Scholar] [CrossRef]
- Chen, Z.; Zhu, Q.; Soh, Y.C.; Zhang, L. Robust human activity recognition using smartphone sensors via CT-PCA and online SVM. IEEE Trans. Ind. Inform. 2017, 13, 3070–3080. [Google Scholar] [CrossRef]
- Chen, Z.; Jiang, C.; Xie, L. A novel ensemble ELM for human activity recognition using smartphone sensors. IEEE Trans. Ind. Inform. 2018, 15, 2691–2699. [Google Scholar] [CrossRef]
- Bayat, A.; Pomplun, M.; Tran, D.A. A study on human activity recognition using accelerometer data from smartphones. Procedia Comput. Sci. 2014, 34, 450–457. [Google Scholar] [CrossRef] [Green Version]
- Gjoreski, H.; Kozina, S.; Gams, M.; Luštrek, M. RAReFall—Real-time activity recognition and fall detection system. In Proceedings of the 2014 IEEE International Conference on Pervasive Computing and Communication Workshops (PERCOM WORKSHOPS), Budapest, Hungary, 24–28 March 2014; pp. 145–147. [Google Scholar]
- Das, A.K.; Wazid, M.; Kumar, N.; Khan, M.K.; Choo, K.K.R.; Park, Y. Design of secure and lightweight authentication protocol for wearable devices environment. IEEE J. Biomed. Health Inform. 2017, 22, 1310–1322. [Google Scholar] [CrossRef] [PubMed]
- Saharan, S.; Bawa, S.; Kumar, N. Dynamic pricing techniques for Intelligent Transportation System in smart cities: A systematic review. Comput. Commun. 2019, 150, 603–625. [Google Scholar] [CrossRef]
- Chahal, R.K.; Kumar, N.; Batra, S. Trust management in social Internet of Things: A taxonomy, open issues, and challenges. Comput. Commun. 2019, 150, 13–46. [Google Scholar] [CrossRef]
- Miglani, A.; Kumar, N. Deep learning models for traffic flow prediction in autonomous vehicles: A review, solutions, and challenges. Veh. Commun. 2019, 20, 100184. [Google Scholar] [CrossRef]
- Sun, G.; Zhou, R.; Sun, J.; Yu, H.; Vasilakos, A.V. Energy-Efficient Provisioning for Service Function Chains to Support Delay-Sensitive Applications in Network Function Virtualization. IEEE Internet Things J. 2020. [Google Scholar] [CrossRef]
- Iwendi, C.; Offor, K. Alternative Protocol Implementation for Wireless Sensor Network Nodes. J. Telecommun. Syst. Manag. 2013, 2, 106. [Google Scholar]
- Mittal, M.; Iwendi, C. A Survey on Energy-Aware Wireless Sensor Routing Protocols. EAI Endorsed Trans. Energy Web 2019, 6, 24. [Google Scholar] [CrossRef]
- Eckmann, J.; Kamphorst, S.O.; Ruelle, D. Recurrence plots of dynamical systems. World Sci. Ser. Nonlinear Sci. Ser. A 1995, 16, 441–446. [Google Scholar]
- LeCun, Y.; Bengio, Y. Convolutional networks for images, speech, and time series. Handb. Brain Theory Neural Netw. 1995, 3361, 1995. [Google Scholar]
- Hassan, M.M.; Uddin, M.Z.; Mohamed, A.; Almogren, A. A robust human activity recognition system using smartphone sensors and deep learning. Future Gener. Comput. Syst. 2018, 81, 307–313. [Google Scholar] [CrossRef]
- Chawla, N.V.; Bowyer, K.W.; Hall, L.O.; Kegelmeyer, W.P. SMOTE: Synthetic minority over-sampling technique. J. Artif. Intell. Res. 2002, 16, 321–357. [Google Scholar] [CrossRef]
- Hall, M.; Frank, E.; Holmes, G.; Pfahringer, B.; Reutemann, P.; Witten, I.H. The WEKA data mining software: An update. ACM SIGKDD Explor. Newsl. 2009, 11, 10–18. [Google Scholar] [CrossRef]
- Sukor, A.A.; Zakaria, A.; Rahim, N.A. Activity recognition using accelerometer sensor and machine learning classifiers. In Proceedings of the 2018 IEEE 14th International Colloquium on Signal Processing & Its Applications (CSPA), Batu Feringghi, Malaysia, 9–10 March 2018; pp. 233–238. [Google Scholar]
j48 | LR | MLP | |
---|---|---|---|
Standing | 91.5 | 86.6 | 93.7 |
Sitting | 91.2 | 85.5 | 92.0 |
Downstairs | 65.7 | 52.1 | 71.5 |
Walking | 88.3 | 91.0 | 92.5 |
Upstairs | 75.6 | 67.5 | 79.3 |
Jogging | 96.2 | 95.3 | 94.0 |
Overall | 85.0 | 79.6 | 87.2 |
Precision | Recall | F-Score | Accuracy | |
---|---|---|---|---|
j48 | 83.2 | 85.0 | 84.0 | 85.0 |
LR | 78.1 | 79.6 | 78.1 | 79.6 |
MLP | 86.7 | 87.2 | 86.9 | 87.2 |
(x-y) axis | (x-z) axis | (y-z) axis | (x-y-z) axis | |
---|---|---|---|---|
Standing | 90.1 | 88.2 | 96.4 | 93.7 |
Sitting | 90.2 | 86.8 | 94.7 | 92.0 |
Downstairs | 70.7 | 68.5 | 87.1 | 71.5 |
Walking | 89.5 | 90.0 | 95.0 | 92.5 |
Upstairs | 79.6 | 65.5 | 89.8 | 79.3 |
Jogging | 92.2 | 94.1 | 96.5 | 94.0 |
Overall | 85.4 | 82.2 | 93.3 | 87.2 |
Activities | [3] | [8] | Proposed Approach |
---|---|---|---|
Standing | 91.9 | 94.9 | 95.7 |
Sitting | 95.0 | 93.9 | 94.0 |
Downstairs | 44.3 | 74.6 | 91.5 |
Walking | 91.7 | 86.3 | 96.5 |
Upstairs | 61.5 | 57.2 | 84.3 |
Jogging | 98.3 | N/A | 96.0 |
Overall | 80.7 | 81.4 | 93.0 |
Activities | [15] | Proposed Approach |
---|---|---|
Standing | 93.3 | 93.2 |
Sitting | 82.6 | 90.3 |
Downstairs | 87.0 | 89.1 |
Walking | 98.5 | 95.9 |
Upstairs | 72.2 | 82.8 |
Jogging | 97.8 | 95.5 |
Overall | 88.5 | 91.13 |
© 2020 by the authors. Licensee MDPI, Basel, Switzerland. This article is an open access article distributed under the terms and conditions of the Creative Commons Attribution (CC BY) license (http://creativecommons.org/licenses/by/4.0/).
Share and Cite
Javed, A.R.; Sarwar, M.U.; Khan, S.; Iwendi, C.; Mittal, M.; Kumar, N. Analyzing the Effectiveness and Contribution of Each Axis of Tri-Axial Accelerometer Sensor for Accurate Activity Recognition. Sensors 2020, 20, 2216. https://doi.org/10.3390/s20082216
Javed AR, Sarwar MU, Khan S, Iwendi C, Mittal M, Kumar N. Analyzing the Effectiveness and Contribution of Each Axis of Tri-Axial Accelerometer Sensor for Accurate Activity Recognition. Sensors. 2020; 20(8):2216. https://doi.org/10.3390/s20082216
Chicago/Turabian StyleJaved, Abdul Rehman, Muhammad Usman Sarwar, Suleman Khan, Celestine Iwendi, Mohit Mittal, and Neeraj Kumar. 2020. "Analyzing the Effectiveness and Contribution of Each Axis of Tri-Axial Accelerometer Sensor for Accurate Activity Recognition" Sensors 20, no. 8: 2216. https://doi.org/10.3390/s20082216
APA StyleJaved, A. R., Sarwar, M. U., Khan, S., Iwendi, C., Mittal, M., & Kumar, N. (2020). Analyzing the Effectiveness and Contribution of Each Axis of Tri-Axial Accelerometer Sensor for Accurate Activity Recognition. Sensors, 20(8), 2216. https://doi.org/10.3390/s20082216