Vous êtes sur la page 1sur 4

World appl. programming, Vol(4), No (12), December, 2014. pp.

237-240

TI Journals

World Applied Programming


www.tijournals.com

ISSN:
2222-2510
Copyright 2014. All rights reserved for TI Journals.

Human activity recognition using accelerometers values in different


coordinate systems
Samad Zabihi *
Shahrood University of Technology, Semnan, Iran.

Pouyan Nasrollahi
School of Electrical and Computer Engineering, Shiraz University, Shiraz, Iran.

Mohammad Bazmara
School of Electrical and Computer Engineering, Shiraz University, Shiraz, Iran.
*Corresponding author: samadzabihi@outlook.com

Keywords

Abstract

Human activity recognition


Intelligent systems
Accelerometers
Classication

Human activity recognition is a technology to recognize activities of one or more subjects from a series of
observations on the subjects body movements. It is an essential technology for service robots and intelligent
systems which are in interaction with human beings.
This paper proposes a procedure for improving human activity recognition using3-axial accelerometers data.
These accelerometers measure acceleration of body motions in three axes, x, y and z. An evaluation on a
real-world dataset shows that the quality of features can be improved by transforming accelerometers values
to different coordinate systems and extracting features from these transformed data, and then excellent
classication results outperforming recent works can be achieved.

1.

Introduction

Artificial Intelligence is a very broad area and many areas like Image Processing use the expertise of Artificial Intelligence to build systems.
Artificial Intelligence provides various methods to be applied in different areas such as really finding soccer talent and goalkeeper quality [1, 2].
Its applications in agriculture [3, 4] or selecting systems of important features [5] and also geographic information systems using fuzzy
uncertainty [6].
In modern societies, the number of the elderly who live alone is increasing. In many cases, these people need to be assisted in their daily life.
Also, with the development of intelligent systems, these systems are expected to interact well with humans. So both these necessities made it
obligatory for intelligent systems to recognize human activities. Nowadays some technologies are developing to solve these problems. Human
activity recognition algorithms have improved considerably in recent years. Image processing and use of wearable sensors are two approaches
that commonly used for HAR.
The image processing approach does not require the use of equipment in the users body, but imposes some limitations such as restricting
operation to the indoor environments, requiring camera installation in all the rooms, lighting and image quality concerns and, mainly, users
privacy [7]. The use of wearable sensors minimizes these problems, but requires the user to wear the equipment through extended periods of
time. Hence, the use of wearable sensors may lead to inconveniences with battery charges, positioning, and calibration of sensors [8].
A Dynamic Neural Networks (ANNs) approach on physical human action classification implemented in [9] based on dynamic programming
model; which makes it similar to our work. Another effort toward action classification has been demonstrated using Evidence Feed Forward
Hidden Markov Model (EFF-HMM) in [10]. The EEF-HMM has been used for the gesture recognition by generalizing the movement of people
[10][10]. A 3D Human Body-Part Tracking and Action Classification method that builds a Hierarchical Body Model has been proposed using
Hierarchical Annealing Particle Filter (H-APF) algorithm in [11]. With the purpose of reducing the use of redundant features in human activity
recognition, Mark Halls selection algorithm based on correlation was applied in [12]. Also in robotic field, a new method was proposed to
classify and choose the best action in humanoid robots using the classification algorithms and machine learning techniques [13].
In this work we present a procedure for extracting efficient features from data of wearable acceleration sensors. By selecting a suitable
coordinate system based on the anatomy of human body, recognition rate can be improved without extracting extra feature.
The paper is organized as follows: the evaluated dataset is described in Section II. Preprocessing stage will be described in Section III. The
quality of features in two of coordinate systems will be evaluated in Section IV. Feature extraction procedure is detailed in Section V and the
result of classification with neural network is presented in Section VI. Conclusions will follow in Section VII.

2.

Real-World Dataset

The In this paper, a public domain HAR dataset have been used. This dataset was provided by [12], and was collected during 8 hours of
activities, 2 hours with each one of the 4 subjects: 2 men and 2 women, all adults and healthy. The protocol was to perform each activity
separately. The profile of each subject is shown in table 1[12].
Although the number of subjects is small, the amount of data collected is reasonable (2 hours for each subject) and the profile is diverse: women,
men, young adults and one Elder. At total it was collected 165,633 samples for the study; the distribution of the samples between the classes is
illustrated in figure 1 [9].

Samad Zabihi *, Pouyan Nasrollahi, Mohammad Bazmara

238

World Applied Programming Vol(4), No (12), December, 2014.

Table1. Characteristics of the subjects

Subject

Gender

Age (years)

Height (m)

Weight (Kg)

Instances

Female

46

1.62

67

51,577

Female

28

1.58

53

49,797

Male

31

1.71

83

51,098

Male

75

1.67

67

13,161

Figure 1. Frequency of classes between collected data

3.

Preprocessing

Recorded time series data from accelerometers often contains noise of high frequency, which in many cases distorts the actual signal. Thus,
sliding-window-based average [14] or median lters [15] are applied in order to remove outliers. In this work, two stage of moving average filter
with an 8-sample span have been used to smooth each sequential group of samples separately.

4.

Comparison of the Read Values of Accelerometers in Different Coordinate System

As we know, the distance between mounted sensor and its related joint is approximately constant. This mounted sensor relative to its adjacent
joint moves approximately on the surface of a sphere. Thus, spherical coordinate system can describe the motion of a hand or foot better than
Cartesian coordinate system, because most of them have an angular motion relative to their adjacent joints.
To evaluate this, the read values of the axes, x, y and z of all accelerometers have been transformed to the spherical coordinates (r, and ).Six
similar MLP neural networks were designed with hidden layer size of 12. Half of the designed MPL was used for classifying the read values of
the axes, x, y and z, and remainder of them was used for classifying the transformed read values. All samples were randomly divided, with 70%
used for training, 15% for validation and 15% for testing. This MLP networks were trained independently. The result of these classifications is
presented in table 3.
It can be concluded from the table 3 that the read values of accelerometers in Spherical coordinates are more distinguishing than the values of the
axes, x, y and z. so it would be a reasonable approach to extract feature from the read values of accelerometers in spherical coordinates for
classifying this HAR dataset.

Hidden
Layer
Size

MLP1

12

MLP2

12

MLP3

12

MLP4

12

MLP5

12

MLP6

12

MSE (Mean
Squared
Error)

Overall
Classification rate

Classification
Rate of Test
Set

The Read
Values
in Cartesian
Coordinates

Neuron
Network

0.0066891

98.2%

98.2%

0.0060766

98.5%

98.5%

0.0080896

97.0%

96.9%

The Read
Values
in Spherical
Coordinates

Table 3. Evaluation of the read values of accelerometers in different coordinate systems by 6 MLP neural network

0.0045669

98.8%

98.7%

0.0056140

98.5%

98.4%

0.0049566

98.7%

98.7%

Input
Elements

Average
of MSEs

Average of Overall
Classification Rates

0.00695

97.90%

0.00504

98.67%

239

Human Activity Recognition Using Accelerometers Values in Different Coordinate Systems


World Applied Programming Vol(4), No (12), December, 2014.

5.

Feature Extraction

After performing preprocessing step on the read values of the axes, x, y and z of all accelerometers, they have been transformed to spherical
coordinates (r, and ). For feature extraction, sliding window approach with length of 1 second (8 sample approximately) was used, with 7
samples overlap. In each step of the sliding window approach, time-domain features such as mean, variance and standard deviation were derived
from the transformed values, generating in total 36 derived feature sets.

6.

Activity Recognition with Neural Network

For classifying HAR dataset, a multilayer perceptron neural network was designed with hidden layer size of 48. 36 derived feature and the read
values of all accelerometers in spherical coordinates (12 elements) was combined to form an input vector for neural network. This input vector
was consisted of 48 elements and 165633 samples. All samples were randomly divided, with 70% used for training, 15% for validation and 15%
for testing.
This network was trained and validation stop occurred after 1044 iteration. Training performance is presented in figure 2. The overall
recognition performance was 99.99% and classification rate of test set was 99.99%, with the following accuracies per class: sitting 100%,
sitting down 99.98%, standing 99.99%, standing up 99.92%, and walking 100%.The confusion matrix is presented in table 4.

Figure 2. Training performance of the MLP classifier

Table 4. Confusion matrix of classification result

Predicted Class

Actual Class

7.

Sitting

Sitting down

Standing

Standing up

Walking

Sitting

50631

Sitting down

11825

10

Standing

47365

Standing up

12405

Walking

43390

Conclusion

This paper provided a procedure to improve the human activity recognition using wearable accelerometers data, collected by a wearable device
consisted of 4 accelerometers. This improvement achieved by performing preprocessing stage and transforming the read values of the axes, x, y
and z of all accelerometers to spherical coordinates.
It was considered that the read values of accelerometers in Spherical coordinates are more distinguishing than the values of the axes, x, y and z.
Then the features were derived from the transformed values to improve the classication results. A multilayer perceptron neural network was
used for classifying tasks. The experimental part showed an improved recognition quality in comparison with existing work.

Samad Zabihi *, Pouyan Nasrollahi, Mohammad Bazmara

240

World Applied Programming Vol(4), No (12), December, 2014.

References
[1]
[2]
[3]
[4]
[5]
[6]
[7]
[8]
[9]
[10]
[11]
[12]
[13]
[14]
[15]

Bazmara, M. and S. Jafari, K Nearest Neighbor Algorithm for Finding Soccer Talent. Journal of Basic and Applied Scientific Research, 2013. 3(4): p. 981986.
Bazmara, M. and S. Jafari, A Fuzzy expert system for goalkeeper quality recognition. International Journal of Computer Science Issues, 2012. 9(5): p. 318322.
Azadi, H., et al., Sustainable rangeland management using fuzzy logic: A case study in Southwest Iran. Agriculture, Ecosystems & Environment, 2009.
131(3): p. 193-200.
Monga, H., Classification of Biological Species Based on Leaf Architecture-A review. International Journal of Computer Science and Information
Technology & Security, 2012. 2(2): p. 332-334.
Jamali, I., M. Bazmara, and S. Jafari, Feature Selection in Imbalance data sets. International Journal of Computer Science Issues, 2012. 9(3): p. 42-45.
Mohammadi, F. and M. Bazmara, A New Approach of Fuzzy Theory with Uncertainties in Geographic Information Systems. International Journal of
Mechatronics, Electrical and Computer Technology, 2013. 3(6): p. 1001-1014.
Gjoreski, H., Lustrek, M., Gams, M. (2011). "Accelerometer Placement for Posture Recognition and Fall Detection."7th International Conference on
Intelligent Environments.
Lei, G., Bourke, A.K., Nelson, J. (2011). "A system for activity recognition using multi-sensor fusion."Annual International Conference of the IEEE
Engineering in Medicine and Biology Society.
Theodoridis, T, and H Hu. "Action classification of 3d human models using dynamic anns for mobile robot surveillance." Robotics and Biomimetics, 2007.
ROBIO 2007. IEEE International Conference on. IEEE, 2007.
Del Rose M, C Wagner and P Frederick, Evidence feed forward hidden Markov model: a new type of hidden Markov model, International Journal of
Artificial Intelligence & Applications (IJAIA), Vol.2, No.1, Jan. 2011.
L.M. Raskin, M. Rudzsky, and E. Rivlin, 3D Human Body-Part Tracking and Action Classification Using A Hierarchical Body Model, Proc. BMVC,
2009, pp. 1-11.
Ugulino, Wallace, et al. "Wearable Computing: Accelerometers Data Classification of Body Postures and Movements." Advances in Artificial IntelligenceSBIA 2012. Springer Berlin Heidelberg, 2012.P: 52-61.
P. Nasrollahi, S. Jafari, M. Ebrahimi, & M. Ebrahimi, Action Classification of Humanoid Soccer Robots Using Machine Learning, 16th CSI International
Symposium on Artificial Intelligence and Signal Processing, Shiraz, Fars, 2012, 598-603.
Khan, Adil Mehmood, et al. "A triaxial accelerometer-based physical-activity recognition via augmented-signal features and a hierarchical recognizer."
Information Technology in Biomedicine, IEEE Transactions on 14.5 (2010): 1166-1172.
Karantonis, Dean M., et al. "Implementation of a real-time human movement classifier using a triaxial accelerometer for ambulatory monitoring."
Information Technology in Biomedicine, IEEE Transactions on 10.1 (2006): 156-167.

Vous aimerez peut-être aussi