Skip to main content
Log in

Activity logging using lightweight classification techniques in mobile devices

  • Original Article
  • Published:
Personal and Ubiquitous Computing Aims and scope Submit manuscript

Abstract

Automated activity recognition enables a wide variety of applications related to child and elderly care, disease diagnosis and treatment, personal health or sports training, for which it is key to seamlessly determine and log the user’s motion. This work focuses on exploring the use of smartphones to perform activity recognition without interfering in the user’s lifestyle. Thus, we study how to build an activity recognition system to be continuously executed in a mobile device in background mode. The system relies on device’s sensing, processing and storing capabilities to estimate significant movements/postures (walking at different paces—slow, normal, rush, running, sitting, standing). In order to evaluate the combinations of sensors, features and algorithms, an activity dataset of 16 individuals has been gathered. The performance of a set of lightweight classifiers (Naïve Bayes, Decision Table and Decision Tree) working on different sensor data has been fully evaluated and optimized in terms of accuracy, computational cost and memory fingerprint. Results have pointed out that a priori information on the relative position of the mobile device with respect to the user’s body enhances the estimation accuracy. Results show that computational low-cost Decision Tables using the best set of features among mean and variance and considering all the sensors (acceleration, gravity, linear acceleration, magnetometer, gyroscope) may be enough to get an activity estimation accuracy of around 88 % (78 % is the accuracy of the Naïve Bayes algorithm with the same characteristics used as a baseline). To demonstrate its applicability, the activity recognition system has been used to enable a mobile application to promote active lifestyles.

This is a preview of subscription content, log in via an institution to check access.

Access this article

Price excludes VAT (USA)
Tax calculation will be finalised during checkout.

Instant access to the full article PDF.

Fig. 1
Fig. 2
Fig. 3
Fig. 4
Fig. 5

Similar content being viewed by others

Notes

  1. From Android developers: http://developer.android.com/guide/developing/debugging/debugging-tracing.html.

References

  1. Harun H (2011) Smartphone penetration in Asia set to boom. Nielsenwire. http://blog.nielsen.com/nielsenwire/global/smartphone-penetration-in-asia-set-to-boom/. Accessed 28 Sept 2011

  2. Kellogg D (2011) 40 percent of U.S. mobile users own smartphones; 40 percent are android. Nielsenwire. http://blog.nielsen.com/nielsenwire/?p=28790. Accessed 28 Sept 2011

  3. Lane N, Miluzzo E, Lu H, Peebles D, Choudhury T, Campbell A (2010) A survey of mobile phone sensing. IEEE Commun Mag 48(9):140–150. doi:10.1109/MCOM.2010.5560598

    Article  Google Scholar 

  4. MediaCT GI (2011) The mobile movement study. http://www.thinkwithgoogle.com/insights/library/studies/the-mobile-movement/

  5. Barkhuus L, Polichar VE (2011) Empowerment through seamfulness: smart phones in everyday life. Pers Ubiquitous Comput 15(6):629–639. doi:10.1007/s00779-010-0342-4

    Article  Google Scholar 

  6. Tsai CC, Lee G, Raab F, Norman GJ, Sohn T, Griswold WG, Patrick K (2007) Usability and feasibility of PmEB: a mobile phone application for monitoring real time caloric balance. Mobile Netw Appl 12(2–3):173–184. doi:10.1007/s11036-007-0014-4

    Article  Google Scholar 

  7. Bao L, Intille S (2004) Activity recognition from user-annotated acceleration data. In: Ferscha A, Mattern F (eds) Pervasive computing. Lecture notes in computer science, vol 3001. Springer Berlin/Heidelberg, pp 1–17. doi:10.1007/978-3-540-24646-6_1

  8. Martin H, Bernardos AM, Tarrio P, Casar JR (2011) Enhancing activity recognition by fusing inertial and biometric information. In: Proceedings of the 14th international conference on information fusion (FUSION 2011), Chicago, IL, USA, 5–8 July 2011. IEEE, pp 1–8

  9. Karaman S, Benois-Pineau J, Megret R, Pinquier J, Gaestel Y, Dartigues JF (2011) Activities of daily living indexing by hierarchical HMM for dementia diagnostics. In: Proceedings of the 9th international workshop on content-based multimedia indexing (CBMI 2011), Madrid, Spain, 13–15 June 2011. IEEE, pp 79–84

  10. Philipose M, Fishkin KP, Perkowitz M, Patterson DJ, Fox D, Kautz H, Hahnel D (2004) Inferring activities from interactions with objects. IEEE Pervasive Comput 3(4):50–57

    Article  Google Scholar 

  11. Blum M, Pentland A, Troster G (2006) InSense: interest-based life logging. IEEE Multimed 13(4):40–48

    Article  Google Scholar 

  12. Puangpakisiri W, Yamasaki T, Aizawa K (2008) High level activity annotation of daily experiences by a combination of a wearable device and Wi-Fi based positioning system. In: Proceedings of the IEEE international conference on multimedia and expo (ICME 2008), Hannover, Germany, 23–26 June 2008. IEEE, pp 1421–1424

  13. Matic A, Osmani V, Popleteev A, Mayora-Ibarra O (2011) Smart phone sensing to examine effects of social interactions and non-sedentary work time on mood changes-modeling and using context. In: Lecture notes in computer science, vol 6967. Springer Berlin/Heidelberg, pp 200–213. doi:10.1007/978-3-642-24279-3_21

  14. Iglesias J, Bernardos A, Tarrío P, Casar JR, Martín H (2011) Design and validation of a light inference system to support embedded context reasoning. Pers Ubiquitous Comput 1–17. doi:10.1007/s00779-011-0447-4

  15. Consolvo S, McDonald DW, Toscos T, Chen MY, Froehlich J, Harrison B, Klasnja P, LaMarca A, LeGrand L, Libby R, Smith I, Landay JA (2008) Activity sensing in the wild: a field trial of ubifit garden. In: Proceedings of the 26th annual SIGCHI conference on human factors in computing systems (CHI 2008), Florence, Italy, 5–10 April 2008. ACM, pp 1797–1806. doi:10.1145/1357054.1357335

  16. Denning T, Andrew A, Chaudhri R, Hartung C, Lester J, Borriello G, Duncan G (2009) BALANCE: towards a usable pervasive wellness application with accurate activity inference. In: Proceedings of the 10th workshop on mobile computing systems and applications (HotMobile 2009), Santa Cruz, CA, USA, 23–24 Feb 2009. ACM, pp 1–6. doi:10.1145/1514411.1514416

  17. Health Priorities (2003) The role of physical activity-public health physical activity background paper

  18. Armstrong N, Nugent C, Moore G, Finlay D (2009) Mapping user needs to smartphone services for persons with chronic disease. In: Proceedings of the 7th international conference on smart homes and health telematics: ambient assistive health and wellness management in the heart of the city (ICOST 2009), Tours, France, 1–3 July 2009. Springer, pp 25–31. doi:10.1007/978-3-642-02868-7_4

  19. Nachman L, Baxi A, Bhattacharya S, Darera V, Kodalapura N, Mageshkumar V, Rath S, Acharya R (2010) Jog falls: a pervasive healthcare platform for diabetes management. In: Proceedings of pervasive 2010, Helsinki, Finland, 17–20 May 2010. pp 94–111

  20. Arteaga SM, Kudeki M, Woodworth A (2009) Combating obesity trends in teenagers through persuasive mobile technology. Access Comput (ACM SIGACCESS) 94:17–25. doi:10.1145/1595061.1595064

    Article  Google Scholar 

  21. Barth J, Klucken J, Kugler P, Kammerer T, Steidl R, Winkler J, Hornegger J, Eskofier B (2011) Biometric and mobile gait analysis for early diagnosis and therapy monitoring in Parkinson’s disease. In: Proceedings of the annual international conference of the IEEE engineering in medicine and biology society (EMBC 2011), 30 Aug–3 Sept 2011. IEEE, pp 868–871

  22. Tacconi D, Mayora O, Lukowicz P, Arnrich B, Setz C, Troster G, Haring C (2008) Activity and emotion recognition to support early diagnosis of psychiatric diseases. In: Proceedings of the 2nd international conference on pervasive computing technologies for healthcare (PervasiveHealth 2008), Tampere, Finland, 30 Jan–1 Feb 2008. IEEE, pp 100–102

  23. Ermes M, Parkka J, Mantyjarvi J, Korhonen I (2008) Detection of daily activities and sports with wearable sensors in controlled and uncontrolled conditions. IEEE Trans Inf Technol Biomed 12(1):20–26

    Article  Google Scholar 

  24. Hamanaka M, Murakami Y, Kim D, Miura Y, Atsuta K, Lee S (2011) System for detecting kindergartners. Syst Cybern Inf 9(2):39–45

    Google Scholar 

  25. Choudhury T, Philipose M, Wyatt D, Lester J (2006) Towards activity databases: using sensors and statistical models to summarize people’s lives. IEEE Data Eng Bull 29

  26. Lindström M, Stahl A, Höök K, Sundström P, Laaksolathi J, Combetto M, Taylor A, Bresin R (2006) Affective diary: designing for bodily expressiveness and self-reflection. In: Paper presented at the CHI ‘06 extended abstracts on human factors in computing systems (CHI EA 2006), Montréal, QC, Canada, 24–27 April 2006, pp 1037–1042

  27. Bajrami G, Derawi MO, Bours P (2011) Towards an automatic gait recognition system using activity recognition (wearable based). In: Proceedings of the 3rd international workshop on in security and communication networks (IWSCN 2011), Gjovik, Norway, 18–20 May 2011

  28. Ofstad A, Nicholas E, Szcodronski R, Choudhury RR (2008) AAMPL: accelerometer augmented mobile phone localization. In: Proceedings of the 1st ACM international workshop on mobile entity localization and tracking in GPS-less environments (MELT 2008), San Francisco, CA, USA, 14–19 Sept 2008. ACM, pp 13–18. doi:10.1145/1410012.1410016

  29. Chon J, Hojung C (2011) LifeMap: a smartphone-based context provider for location-based services. IEEE Pervasive Comput 10(2):58–67

    Article  Google Scholar 

  30. Zhang S, McCullagh P, Nugent C, Zheng H (2010) Activity monitoring using a smart phone’s accelerometer with hierarchical classification. In: Proceedings of the 6th international conference on intelligent environments (IE 2010) Kuala Lumpur, Malaysia, 19–21 July 2010. IEEE, pp 158–163

  31. Sun L, Zhang D, Li B, Guo B, Li S (2010) Activity recognition on an accelerometer embedded mobile phone with varying positions and orientations. In: Ubiquitous intelligence and computing. Lecture notes in computer science, vol 6406. Springer Berlin/Heidelberg, pp 548–562. doi:10.1007/978-3-642-16355-5_42

  32. Yang J (2009) Toward physical activity diary: motion recognition using simple acceleration features with mobile phones. In: Proceedings of the 1st international workshop on interactive multimedia for consumer electronics (IMCE 2009), Beijing, China, 23 Oct 2009. ACM, pp 1–10. doi:10.1145/1631040.1631042

  33. Miluzzo E, Lane ND, Fodor K, Peterson R, Lu H, Musolesi M, Eisenman SB, Zheng X, Campbell AT (2008) Sensing meets mobile social networks: the design, implementation and evaluation of the CenceMe application. In: Proceedings of the 6th ACM conference on embedded networked sensor systems (SenSys 2008), Raleigh, NC, USA, 5–7 Nov 2008. ACM, pp 337–350. doi:10.1145/1460412.1460445

  34. Khan AM, Lee YK, Lee SY, Kim TS (2010) Human activity recognition via an accelerometer-enabled-smartphone using kernel discriminant analysis. In: Proceedings of the 5th international conference on future information technology (FutureTech 2010) Busan, Korea, 20–24 May 2010. IEEE, pp 1–6

  35. Chipchase J, Yanquing C, Ichikawa F (2007) Where’s the phone? Selected data. Survey. Nokia

  36. Android-API (2009) Sensor class. http://developer.android.com/reference/android/hardware/Sensor.html. Accessed 28 Sept 2011

  37. Xsens-Technologies (2008) MTi and MTx user manual and technical documentation

  38. John GH, Langley P (1995) Estimating continuous distributions in bayesian classifiers. In: Proceedings of the 11th conference on uncertainty in artificial intelligence (UAI 1995), Montreal, QC, Canada, 18–20 Aug 1995. Morgan Kaufmann, pp 338–345

  39. Kohavi R (1995) The power of decision tables. In: Proceedings of the 8th European conference on machine learning, Heraclion, Crete, Greece, 25–27 April 1995, pp 174–189

  40. Quinlan R (1993) C4.5: Programs for machine learning. Morgan Kaufmann, San Mateo, CA

  41. Hall M, Frank E, Holmes G, Pfahringer B, Reutemann P, Witten IH (2009) The WEKA data mining software: an update. SIGKDD Explor Newsl 11(1):10–18. doi:10.1145/1656274.1656278

    Article  Google Scholar 

  42. Myra LS, Witmer JA, Schaffner AA (2012) Statistics for the life sciences, 4th edn. Pearson Education

  43. Nations FaAOotU (2004) Human energy requirements: report of a joint FAO/WHO/UNU expert consultation. FAO food and nutrition technical report series, Rome

  44. Puyau MR, Adolph AL, Vohra FA, Zakeri I, Butte NF (2004) Prediction of activity energy expenditure using accelerometers in children. Med Sci Sports Exerc 36(9):1625–1631

    Google Scholar 

  45. Kurpad AV, Raj R, Maruthy KN, Vaz M (2006) A simple method of measuring total daily energy expenditure and physical activity level from the heart rate in adult men. Eur J Clin Nutr 60:32–40

    Article  Google Scholar 

  46. Ainsworth BE, Haskell WL, Whitt MC, Irwin ML, Swartz AM, Strath SJ, O'Brien WL, Bassett DR Jr, Schmitz KH, Emplaincourt PO, Jacobs DR Jr, Leon AS (2000) Compendium of physical activities: an update of activity codes and MET intensities. Med Sci Sports Exerc 32(9):498–504

    Google Scholar 

Download references

Acknowledgments

Authors acknowledge their lab colleagues for the help provided by the persons who have collaborated on building the activities datasets, and Jesús Cano for his help developing the Activity Monitor. Henar Martín acknowledges the Spanish Ministry of Education for her grant. This work has been supported by the Spanish Ministry for Science and Innovation under grant TIN2011-28620-C02-02 and IPT2011-1052-390000 and the Government of Madrid under grant S2009/TIC-1485 (CONTEXTS).

Author information

Authors and Affiliations

Authors

Corresponding author

Correspondence to Henar Martín.

Rights and permissions

Reprints and permissions

About this article

Cite this article

Martín, H., Bernardos, A.M., Iglesias, J. et al. Activity logging using lightweight classification techniques in mobile devices. Pers Ubiquit Comput 17, 675–695 (2013). https://doi.org/10.1007/s00779-012-0515-4

Download citation

  • Received:

  • Accepted:

  • Published:

  • Issue Date:

  • DOI: https://doi.org/10.1007/s00779-012-0515-4

Keywords

Navigation