5ImplementationImplementation PlatformHardwareProcessor: Intel Core i5RAM: 8 GBGPU: NVIDIA GEFORCEThe above requirements were satisfied, where in the training could be done on an instance that matches the necessary requirements as mentioned above.SoftwareOperating System: Windows 8 or Windows 10 (64bit)Programming Languages: Python (version 3.6.5)Tools: Numpy, Matplotlib, PandasDeep Learning Framework: Keras (version 2.1.6)Implementation Details5.2.1 Conceptual OverviewThe dataset used is a collection of accelerometer data taken from the smartphone the various people carried with them while conducting six different activities (Downstairs, Jogging, Sitting, Standing, Upstairs, Walking).
Timestamp was captured for each exercise and the acceleration for the x, y and z-axis was measured.With this available data, a neural network is trained in order to understand if a person carrying a smartphone is performing any of the six activities. After the neural network is trained on the existing data, it should be able to correctly predict the type of activity a person is conducting when given unseen data.5.2.2 Import LibrariesInitial step is to import all the necessary python libraries.
It is required to install these libraries before importing using the pip installer.After importing the libraries, some standard parameters should be set and Keras version should be printed out, which was installed.5.2.3 Load, Inspect and Transform the accelerometer dataStandard dataset should be downloaded and stored locally. The accelerometer data should be loaded from the WISDM dataset. Now it is required to convert and reformat accelerometer data into a time-sliced representation. Later, the data should be visualized and reshaped so that it is accepted by the Keras. The dataset is split into training, validation, and test data.9048756953255.2.3.1 Training datasetThe choice of dataset heavily depends on the application. The activities we are interested to recognize are sitting, standing, walking, jogging, climb upstairs, and downstairs. The dataset chosen for training is WISDM dataset, which contains readings from two sensors (Accelerometer and Gyroscope). Readings were recorded when users executed activities in no specific order, while carrying smartphones. The data can be loaded to data frame successfully and displayed.94297550666655.2.4 Create Neural Network Models in KerasNow, that the data is ready in such a format that Keras will be able to process it, a model combining CNN (Convolutional Neural Network) and RNN (Recurrent Neural Network) is proposed here. The sensor measurements given as input are split into series of data intervals along time. The representation of each data interval is fed into CNN and then to RNN. 18.104.22.168 Convolutional Neural NetworkThe CNN is capable of automatically extracting local features within the each sensor modality and merges the local features of different sensor modalities into global features hierarchically. CNNs are able to extract features from input sequences, such as accelerometer data. CNNs would be better fit for predicting the activity given a sequence of observed accelerometer data.One-dimensional CNNs have been widely used for this type of problem, with one channel for each axis of the accelerometer data. A good simple starting point would be to fit a CNN model on windows of sequence data directly.8470903971925005.2.4.2 Recurrent Neural NetworkThe RNN is capable of extracting temporal dependencies. To understand how this might be useful, existing implementations are tested by performing an activity in various positions. The LSTM (Long Short Term Memory) network model is developed for the human activity recognition dataset.The LSTM network models are a type of RNN that are able to learn and remember over long sequences of input data. They are intended for use with the data that is comprised of long sequences of data. They may be good fit for this problem. The benefit of using LSTMs for sequence classification is that they can learn from the raw time series data directly.7810502790825005.2.5 Fit the ModelPost creating the model, model is trained with the training data that was prepared earlier. Early stopping callback monitor on training accuracy is defined. The hyper parameter used for the training are quite simple: the used batch size of 400 records and will train the model for 10 epochs. For model training, we will use a 80:20 split separate training data and validation data. It is that simple.5.2.6 Model EvaluationThe data are exposed to the model while maintaining the temporal ordering of the observations. The segmentation of the dataset by subject avoids any issues related to the temporal ordering.center260032500 Accelerometer contains capacitive plates internally. Some of them are fixed, while others are attached to minuscule springs that move internally as acceleration forces act upon the sensor. As these plates move in relation to each other, the capacitance between them changes. From these changes, the acceleration can be determined.The following graphs clearly depicts the x, y and z-axis representations for each of the activities. The rate of change of velocity of an object varies for every activity. This slightly varies with the elevation. 6TestingThe movement data recorded was the x, y and z accelerometer data and the gyroscopic data from the smartphone. The pre-processed data was made available. The 80% of the data was used first for training and the 20% of the data was used as testing data. For training the batch size and the epochs were varied. Normalization was done on the x, y and z co-ordinates of the data.The expectations prove to be right, as there is a higher acceleration for activities such as jogging and walking compared to sitting.Activity-1: Climbing stairsright3181350Activity-2: Walkingleft4953000057150508635000Activity-3: JoggingActivity-4: Sittingright5429250Activity-5: Lying downrightbottom06.1 Testing InputThe testing input is given in the form 3-axis data, derived from the testing data samples. The model is checked by looking at the performance against the movements of various users.6.2 Testing outputIn the final step, the chosen model is evaluated against the hold out set/ test data set. After training the model, it is saved and made ready for testing. The output is the prediction of the activity, based on the readings from the testing input. The testing accuracy is nearly same as the training accuracy, which depicts that the model is working at its greater accuracy. The model can be stored for the future use/improvements.It was possible to obtain 98.49% accuracy from the LSTM model and 94.30% accuracy from the CNN model.
Cite this essay
Computer Research. (2019, Aug 20). Retrieved from https://studymoose.com/project_report-essay
This is just a sample. You can get your custom paper from our
Information technology has developed through the years. This has also had an impact had on modern society. The technological advancements have and are changing human kind forever. I.T. development has improved the life style of men and women all around the world. Efficiency and speed, of work and leisure is now at its highest level....
The operating system that I have actually selected is a specific service operation: the realisation of a music show. As every other organisation that produce products or services, it has an accurate os, made up by a variety of inputs, a change process and a last output. INPUTS – We must compare 2 various type...
English class has never been one of my strong aspects of life, I would say the grammar part of English I am more knowledgeable at, but when it comes to me having to write papers I am never very fond of the idea. I was required to take the class for my pre-requisites for dental...
Investigating how the concentration of sodium-thiosulphate (STS) and hydrochloric acid (HCL) affects the rate of reaction in the experiment. In addition I am also checking how different variables affect my experiment and also how I can make my test more precise, reliable and accurate. Strategy According to my results, as the concentration of STS solution...
Today I am going to tell you about my hobbies. My favourite hobbies are playing basketball, playing volleyball, drawing and listening to music. Firstly, I feel a great sense of enjoyment from playing basketball because basketball gives me lots of fun and happiness. Basketball not only releases a lot of the stress which I get...
Not Finding What You Need?
Search for essay samples now
Copying content is not allowed on this website
Ask a professional writer to help you with your text