lifespace tracking and activity monitoring on mobile...

24
Lifespace Tracking and Activity Monitoring on Mobile Phones Ian Dewancker [email protected] June 23, 2014 Ian Dewancker Mobile Lifespace June 23, 2014 1 / 24

Upload: others

Post on 13-Aug-2020

4 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Lifespace Tracking and Activity Monitoring on Mobile Phonesiandewancker.com/FILES/thesis_prez.pdf · Lifespace Tracking and Activity Monitoring on Mobile Phones Ian Dewancker idewanck@yelp.com

Lifespace Tracking andActivity Monitoring on Mobile Phones

Ian Dewancker

[email protected]

June 23, 2014

Ian Dewancker Mobile Lifespace June 23, 2014 1 / 24

Page 2: Lifespace Tracking and Activity Monitoring on Mobile Phonesiandewancker.com/FILES/thesis_prez.pdf · Lifespace Tracking and Activity Monitoring on Mobile Phones Ian Dewancker idewanck@yelp.com

Motivation

Daily patterns of behavior are a rich source of information and playan important role in a persons quality of life (mobility, socializing,eating, toileting)

Lifespace is a measure of the frequency, geographic extent andindependence of an individuals travels

While difficult to measure and record automatically, lifespace hasbeen shown to correlate to important metrics relating to physicalperformance, nutritional risk, and community engagement

Ian Dewancker Mobile Lifespace June 23, 2014 2 / 24

Page 3: Lifespace Tracking and Activity Monitoring on Mobile Phonesiandewancker.com/FILES/thesis_prez.pdf · Lifespace Tracking and Activity Monitoring on Mobile Phones Ian Dewancker idewanck@yelp.com

Motivation

Ian Dewancker Mobile Lifespace June 23, 2014 3 / 24

Page 4: Lifespace Tracking and Activity Monitoring on Mobile Phonesiandewancker.com/FILES/thesis_prez.pdf · Lifespace Tracking and Activity Monitoring on Mobile Phones Ian Dewancker idewanck@yelp.com

Goals

Highly personalized, detailed mobility traces are not only ofinterest to researchers, but also individuals motivated to learn moreabout their own trends and behaviours

System to track lifespace and monitor mobility of both ambulatingand wheelchair users with standard mobile phones

Investigation of models and methods to summarize indoor andoutdoor movement as well as activity levels. Focus on techniquesthat perform well on real sensors and in real-world environments

Ian Dewancker Mobile Lifespace June 23, 2014 4 / 24

Page 5: Lifespace Tracking and Activity Monitoring on Mobile Phonesiandewancker.com/FILES/thesis_prez.pdf · Lifespace Tracking and Activity Monitoring on Mobile Phones Ian Dewancker idewanck@yelp.com

WiFi Indoor Localization

Two main types of maps : metric and topologicalPursue topological map localization as it requires only minimal humaneffort for mapping while preserving useful semantic information

Key elements for prob. localization

P(xi | xi−1, u) = motion modelP(z | xi ) = observation model

Ian Dewancker Mobile Lifespace June 23, 2014 5 / 24

Page 6: Lifespace Tracking and Activity Monitoring on Mobile Phonesiandewancker.com/FILES/thesis_prez.pdf · Lifespace Tracking and Activity Monitoring on Mobile Phones Ian Dewancker idewanck@yelp.com

Observation Model

Vision sensors are low cost and have been well studied in this context,but mounting cameras can be awkward and impose on privacy

In most situations, GPS will not function indoors

WiFi has become highly integrated into indoor infrastructure. Signalmeasurements can be made by any mobile device equipped with WiFimodem including mobile phones

z = [RSSI0,RSSI1, · · · ,RSSIN ], xi = room i

The signal strength for an absent access point is cast to -100

Ian Dewancker Mobile Lifespace June 23, 2014 6 / 24

Page 7: Lifespace Tracking and Activity Monitoring on Mobile Phonesiandewancker.com/FILES/thesis_prez.pdf · Lifespace Tracking and Activity Monitoring on Mobile Phones Ian Dewancker idewanck@yelp.com

Naive Bayes

Naive Bayes is a generative modelthat assumes conditional

independence of feature variables

Ian Dewancker Mobile Lifespace June 23, 2014 7 / 24

Page 8: Lifespace Tracking and Activity Monitoring on Mobile Phonesiandewancker.com/FILES/thesis_prez.pdf · Lifespace Tracking and Activity Monitoring on Mobile Phones Ian Dewancker idewanck@yelp.com

Chow-Liu Trees

Chow-Liu algorithm approximates a probability distribution by the closesttree-structured Bayesian network

The topology is determined by themaximum-weight spanning tree ofthe complete graph of the N randomvariables. The weights are calculatedas the mutual information

This structure saw interest again inrobotics research in for visual appear-ance models

Ian Dewancker Mobile Lifespace June 23, 2014 8 / 24

Page 9: Lifespace Tracking and Activity Monitoring on Mobile Phonesiandewancker.com/FILES/thesis_prez.pdf · Lifespace Tracking and Activity Monitoring on Mobile Phones Ian Dewancker idewanck@yelp.com

Random Forests

Random forests are ensemble learners that use a collection of decisiontrees to classify test input. Each tree in the forest is learned on a randomsubset of the training data

Ian Dewancker Mobile Lifespace June 23, 2014 9 / 24

Page 10: Lifespace Tracking and Activity Monitoring on Mobile Phonesiandewancker.com/FILES/thesis_prez.pdf · Lifespace Tracking and Activity Monitoring on Mobile Phones Ian Dewancker idewanck@yelp.com

K-Nearest Neighbours

The k-nearest neighbour classifier is a non-parametric classifier that com-pares test input to training examples and finds the k most similar. It thenreturns the majority class label of those k training examples

It can be converted into a probabilistic model by returning the percentageof the k neighbours voting for each room

Ian Dewancker Mobile Lifespace June 23, 2014 10 / 24

Page 11: Lifespace Tracking and Activity Monitoring on Mobile Phonesiandewancker.com/FILES/thesis_prez.pdf · Lifespace Tracking and Activity Monitoring on Mobile Phones Ian Dewancker idewanck@yelp.com

Novelty Detection

Localizing to an indoor room is important, however so is knowing when toreport that a user is probably not located in one of the trained rooms

Investigation of useful distance metrics for comparing test observationvectors to the training data

Ian Dewancker Mobile Lifespace June 23, 2014 11 / 24

Page 12: Lifespace Tracking and Activity Monitoring on Mobile Phonesiandewancker.com/FILES/thesis_prez.pdf · Lifespace Tracking and Activity Monitoring on Mobile Phones Ian Dewancker idewanck@yelp.com

Novelty Detection

Nearest Neighbour Threshold

Nearest Centroid Thresholds

Observation Model Thresholds

Ian Dewancker Mobile Lifespace June 23, 2014 12 / 24

Page 13: Lifespace Tracking and Activity Monitoring on Mobile Phonesiandewancker.com/FILES/thesis_prez.pdf · Lifespace Tracking and Activity Monitoring on Mobile Phones Ian Dewancker idewanck@yelp.com

Evaluation

WiFi environments are not static andcan easily change over time. Accesspoints may be moved or shut off afterthe training data has been collected.Created five simulated datasets whereeach observation vector has 20% of itsaccess point readings set to -100

Ian Dewancker Mobile Lifespace June 23, 2014 13 / 24

Page 14: Lifespace Tracking and Activity Monitoring on Mobile Phonesiandewancker.com/FILES/thesis_prez.pdf · Lifespace Tracking and Activity Monitoring on Mobile Phones Ian Dewancker idewanck@yelp.com

Evaluation

Random forests have strong performance on both the normal dataset andthe simulated defect dataset

Parameter study for k-nearest neighbour and random forestsRandom forest (number of trees, maximum features, maximum depth)

Ian Dewancker Mobile Lifespace June 23, 2014 14 / 24

Page 15: Lifespace Tracking and Activity Monitoring on Mobile Phonesiandewancker.com/FILES/thesis_prez.pdf · Lifespace Tracking and Activity Monitoring on Mobile Phones Ian Dewancker idewanck@yelp.com

Evaluation

ROC curves are a useful visualization for information retrieval systems.They are 2D projections of a systems performance in the space of truepositive rate and false positive rates

Ian Dewancker Mobile Lifespace June 23, 2014 15 / 24

Page 16: Lifespace Tracking and Activity Monitoring on Mobile Phonesiandewancker.com/FILES/thesis_prez.pdf · Lifespace Tracking and Activity Monitoring on Mobile Phones Ian Dewancker idewanck@yelp.com

Actvity Recognition

Context awareness is an ever improving feature of assistive technologiesand ubiquitous computing. Inference of user activities and environmentalinteractions remains an important problem if only to serve higher levelgoals of a particular system or application

Actigraphy (non-invasive activity monitoring) has become a commontheme in mobile health applicationsMost of these systems have focused on ambulating users only, wheelchairusers would certainly also benefit from similar summaries.

Ian Dewancker Mobile Lifespace June 23, 2014 16 / 24

Page 17: Lifespace Tracking and Activity Monitoring on Mobile Phonesiandewancker.com/FILES/thesis_prez.pdf · Lifespace Tracking and Activity Monitoring on Mobile Phones Ian Dewancker idewanck@yelp.com

Accelerometer Features

An accelerometer is a device capable of measuringacceleration forcesMeans of controlling the user interface, sensing dis-play orientation or detecting falls for hard drive pro-tection.

Poll at 20Hz for 3 second windows

Ian Dewancker Mobile Lifespace June 23, 2014 17 / 24

Page 18: Lifespace Tracking and Activity Monitoring on Mobile Phonesiandewancker.com/FILES/thesis_prez.pdf · Lifespace Tracking and Activity Monitoring on Mobile Phones Ian Dewancker idewanck@yelp.com

Sensor Fusion

The accelerometry features seemed suitable for differentiating between thefirst three motion classes, however the classifier required a way todistinguish vehicle motion from the other profiles.

Final feature vector produced for each signal window by combininingaccelerometer features with the average GPS speed recorded during thesame time interval

Ian Dewancker Mobile Lifespace June 23, 2014 18 / 24

Page 19: Lifespace Tracking and Activity Monitoring on Mobile Phonesiandewancker.com/FILES/thesis_prez.pdf · Lifespace Tracking and Activity Monitoring on Mobile Phones Ian Dewancker idewanck@yelp.com

Evaluation

Ian Dewancker Mobile Lifespace June 23, 2014 19 / 24

Page 20: Lifespace Tracking and Activity Monitoring on Mobile Phonesiandewancker.com/FILES/thesis_prez.pdf · Lifespace Tracking and Activity Monitoring on Mobile Phones Ian Dewancker idewanck@yelp.com

Evaluation

To further validate our classifier, we compared our results with a summaryproduced by another wheelchair activity measurement system. This systemused an accelerometer mounted to a wheel.

Ian Dewancker Mobile Lifespace June 23, 2014 20 / 24

Page 21: Lifespace Tracking and Activity Monitoring on Mobile Phonesiandewancker.com/FILES/thesis_prez.pdf · Lifespace Tracking and Activity Monitoring on Mobile Phones Ian Dewancker idewanck@yelp.com

MobiSense System

Data collection on the phone with the ability to upload data to a webservice for summarizing and visualizing reports for users.The centralized processing and storage of the data streams is done on asingle Amazon EC2 instance running Ubuntu. The Tornado web server isused to handle data uploads and requests for lifespace summaries

App is a modifcation of HumanSense project. ML and Data pipeline inpython, mostly sci-kit learn

Ian Dewancker Mobile Lifespace June 23, 2014 21 / 24

Page 22: Lifespace Tracking and Activity Monitoring on Mobile Phonesiandewancker.com/FILES/thesis_prez.pdf · Lifespace Tracking and Activity Monitoring on Mobile Phones Ian Dewancker idewanck@yelp.com

Sensor Streams

The accelerometer sensor stream creates by far the most data,recorded constantly at 20Hz

The WiFi modem is polled every 10 seconds

The GPS sensor is polled once a minute

18 hour recording period with full accelerometer, WiFi and GPSlogging 15 MB of compressed sensor data collected

Files are only uploaded to the web service when WiFi connectionpresent

Summarization format per day only 100 KB

With little screen use and cell antenna disabled, MobiSense was ableto run on a single battery charge on a Nexus 4 phone for 22 hours

With antenna enabled, close to 14 hours.

Ian Dewancker Mobile Lifespace June 23, 2014 22 / 24

Page 23: Lifespace Tracking and Activity Monitoring on Mobile Phonesiandewancker.com/FILES/thesis_prez.pdf · Lifespace Tracking and Activity Monitoring on Mobile Phones Ian Dewancker idewanck@yelp.com

Demo!

Demo

Ian Dewancker Mobile Lifespace June 23, 2014 23 / 24

Page 24: Lifespace Tracking and Activity Monitoring on Mobile Phonesiandewancker.com/FILES/thesis_prez.pdf · Lifespace Tracking and Activity Monitoring on Mobile Phones Ian Dewancker idewanck@yelp.com

Questions? Comments?

Ian Dewancker Mobile Lifespace June 23, 2014 24 / 24