Context-detection API for Android developed as a university project
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

final.lyx 265KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118211921202121212221232124212521262127212821292130213121322133213421352136213721382139214021412142214321442145214621472148214921502151215221532154215521562157215821592160216121622163216421652166216721682169217021712172217321742175217621772178217921802181218221832184218521862187218821892190219121922193219421952196219721982199220022012202220322042205220622072208220922102211221222132214221522162217221822192220222122222223222422252226222722282229223022312232223322342235223622372238223922402241224222432244224522462247224822492250225122522253225422552256225722582259226022612262226322642265226622672268226922702271227222732274227522762277227822792280228122822283228422852286228722882289229022912292229322942295229622972298229923002301230223032304230523062307230823092310231123122313231423152316231723182319232023212322232323242325232623272328232923302331233223332334233523362337233823392340234123422343234423452346234723482349235023512352235323542355235623572358235923602361236223632364236523662367236823692370237123722373237423752376237723782379238023812382238323842385238623872388238923902391239223932394239523962397239823992400240124022403240424052406240724082409241024112412241324142415241624172418241924202421242224232424242524262427242824292430243124322433243424352436243724382439244024412442244324442445244624472448244924502451245224532454245524562457245824592460246124622463246424652466246724682469247024712472247324742475247624772478247924802481248224832484248524862487248824892490249124922493249424952496249724982499250025012502250325042505250625072508250925102511251225132514251525162517251825192520252125222523252425252526252725282529253025312532253325342535253625372538253925402541254225432544254525462547254825492550255125522553255425552556255725582559256025612562256325642565256625672568256925702571257225732574257525762577257825792580258125822583258425852586258725882589259025912592259325942595259625972598259926002601260226032604260526062607260826092610261126122613261426152616261726182619262026212622262326242625262626272628262926302631263226332634263526362637263826392640264126422643264426452646264726482649265026512652265326542655265626572658265926602661266226632664266526662667266826692670267126722673267426752676267726782679268026812682268326842685268626872688268926902691269226932694269526962697269826992700270127022703270427052706270727082709271027112712271327142715271627172718271927202721272227232724272527262727272827292730273127322733273427352736273727382739274027412742274327442745274627472748274927502751275227532754275527562757275827592760276127622763276427652766276727682769277027712772277327742775277627772778277927802781278227832784278527862787278827892790279127922793279427952796279727982799280028012802280328042805280628072808280928102811281228132814281528162817281828192820282128222823282428252826282728282829283028312832283328342835283628372838283928402841284228432844284528462847284828492850285128522853285428552856285728582859286028612862286328642865286628672868286928702871287228732874287528762877287828792880288128822883288428852886288728882889289028912892289328942895289628972898289929002901290229032904290529062907290829092910291129122913291429152916291729182919292029212922292329242925292629272928292929302931293229332934293529362937293829392940294129422943294429452946294729482949295029512952295329542955295629572958295929602961296229632964296529662967296829692970297129722973297429752976297729782979298029812982298329842985298629872988298929902991299229932994299529962997299829993000300130023003300430053006300730083009301030113012301330143015301630173018301930203021302230233024302530263027302830293030303130323033303430353036303730383039304030413042304330443045304630473048304930503051305230533054305530563057305830593060306130623063306430653066306730683069307030713072307330743075307630773078307930803081308230833084308530863087308830893090309130923093309430953096309730983099310031013102310331043105310631073108310931103111311231133114311531163117311831193120312131223123312431253126312731283129313031313132313331343135313631373138313931403141314231433144314531463147314831493150315131523153315431553156315731583159316031613162316331643165316631673168316931703171317231733174317531763177317831793180318131823183318431853186318731883189319031913192319331943195319631973198319932003201320232033204320532063207320832093210321132123213321432153216321732183219322032213222322332243225322632273228322932303231323232333234323532363237323832393240324132423243324432453246324732483249325032513252325332543255325632573258325932603261326232633264326532663267326832693270327132723273327432753276327732783279328032813282328332843285328632873288328932903291329232933294329532963297329832993300330133023303330433053306330733083309331033113312331333143315331633173318331933203321332233233324332533263327332833293330333133323333333433353336333733383339334033413342334333443345334633473348334933503351335233533354335533563357335833593360336133623363336433653366336733683369337033713372337333743375337633773378337933803381338233833384338533863387338833893390339133923393339433953396339733983399340034013402340334043405340634073408340934103411341234133414341534163417341834193420342134223423342434253426342734283429343034313432343334343435343634373438343934403441344234433444344534463447344834493450345134523453345434553456345734583459346034613462346334643465346634673468346934703471347234733474347534763477347834793480348134823483348434853486348734883489349034913492349334943495349634973498349935003501350235033504350535063507350835093510351135123513351435153516351735183519352035213522352335243525352635273528352935303531353235333534353535363537353835393540354135423543354435453546354735483549355035513552355335543555355635573558355935603561356235633564356535663567356835693570357135723573357435753576357735783579358035813582358335843585358635873588358935903591359235933594359535963597359835993600360136023603360436053606360736083609361036113612361336143615361636173618361936203621362236233624362536263627362836293630363136323633363436353636363736383639364036413642364336443645364636473648364936503651365236533654365536563657365836593660366136623663366436653666366736683669367036713672367336743675367636773678367936803681368236833684368536863687368836893690369136923693369436953696369736983699370037013702370337043705370637073708370937103711371237133714371537163717371837193720372137223723372437253726372737283729373037313732373337343735373637373738373937403741374237433744374537463747374837493750375137523753375437553756375737583759376037613762376337643765376637673768376937703771377237733774377537763777377837793780378137823783378437853786378737883789379037913792379337943795379637973798379938003801380238033804380538063807380838093810381138123813381438153816381738183819382038213822382338243825382638273828382938303831383238333834383538363837383838393840384138423843384438453846384738483849385038513852385338543855385638573858385938603861386238633864386538663867386838693870387138723873387438753876387738783879388038813882388338843885388638873888388938903891389238933894389538963897389838993900390139023903390439053906390739083909391039113912391339143915391639173918391939203921392239233924392539263927392839293930393139323933393439353936393739383939394039413942394339443945394639473948394939503951395239533954395539563957395839593960396139623963396439653966396739683969397039713972397339743975397639773978397939803981398239833984398539863987398839893990399139923993399439953996399739983999400040014002400340044005400640074008400940104011401240134014401540164017401840194020402140224023402440254026402740284029403040314032403340344035403640374038403940404041404240434044404540464047404840494050405140524053405440554056405740584059406040614062406340644065406640674068406940704071407240734074407540764077407840794080408140824083408440854086408740884089409040914092409340944095409640974098409941004101410241034104410541064107410841094110411141124113411441154116411741184119412041214122412341244125412641274128412941304131413241334134413541364137413841394140414141424143414441454146414741484149415041514152415341544155415641574158415941604161416241634164416541664167416841694170417141724173417441754176417741784179418041814182418341844185418641874188418941904191419241934194419541964197419841994200420142024203420442054206420742084209421042114212421342144215421642174218421942204221422242234224422542264227422842294230423142324233423442354236423742384239424042414242424342444245424642474248424942504251425242534254425542564257425842594260426142624263426442654266426742684269427042714272427342744275427642774278427942804281428242834284428542864287428842894290429142924293429442954296429742984299430043014302430343044305430643074308430943104311431243134314431543164317431843194320432143224323432443254326432743284329433043314332433343344335433643374338433943404341434243434344434543464347434843494350435143524353435443554356435743584359436043614362436343644365436643674368436943704371437243734374437543764377437843794380438143824383438443854386438743884389439043914392439343944395439643974398439944004401440244034404440544064407440844094410441144124413441444154416441744184419442044214422442344244425442644274428442944304431443244334434443544364437443844394440444144424443444444454446444744484449445044514452445344544455445644574458445944604461446244634464446544664467446844694470447144724473447444754476447744784479448044814482448344844485448644874488448944904491449244934494449544964497449844994500450145024503450445054506450745084509451045114512451345144515451645174518451945204521452245234524452545264527452845294530453145324533453445354536453745384539454045414542454345444545454645474548454945504551455245534554455545564557455845594560456145624563456445654566456745684569457045714572457345744575457645774578457945804581458245834584458545864587458845894590459145924593459445954596459745984599460046014602460346044605460646074608460946104611461246134614461546164617461846194620462146224623462446254626462746284629463046314632463346344635463646374638463946404641464246434644464546464647464846494650465146524653465446554656465746584659466046614662466346644665466646674668466946704671467246734674467546764677467846794680468146824683468446854686468746884689469046914692469346944695469646974698469947004701470247034704470547064707470847094710471147124713471447154716471747184719472047214722472347244725472647274728472947304731473247334734473547364737473847394740474147424743474447454746474747484749475047514752475347544755475647574758475947604761476247634764476547664767476847694770477147724773477447754776477747784779478047814782478347844785478647874788478947904791479247934794479547964797479847994800480148024803480448054806480748084809481048114812481348144815481648174818481948204821482248234824482548264827482848294830483148324833483448354836483748384839484048414842484348444845484648474848484948504851485248534854485548564857485848594860486148624863486448654866486748684869487048714872487348744875487648774878487948804881488248834884488548864887488848894890489148924893489448954896489748984899490049014902490349044905490649074908490949104911491249134914491549164917491849194920492149224923492449254926492749284929493049314932493349344935493649374938493949404941494249434944494549464947494849494950495149524953495449554956495749584959496049614962496349644965496649674968496949704971497249734974497549764977497849794980498149824983498449854986498749884989499049914992499349944995499649974998499950005001500250035004500550065007500850095010501150125013501450155016501750185019502050215022502350245025502650275028502950305031503250335034503550365037503850395040504150425043504450455046504750485049505050515052505350545055505650575058505950605061506250635064506550665067506850695070507150725073507450755076507750785079508050815082508350845085508650875088508950905091509250935094509550965097509850995100510151025103510451055106510751085109511051115112511351145115511651175118511951205121512251235124512551265127512851295130513151325133513451355136513751385139514051415142514351445145514651475148514951505151515251535154515551565157515851595160516151625163516451655166516751685169517051715172517351745175517651775178517951805181518251835184518551865187518851895190519151925193519451955196519751985199520052015202520352045205520652075208520952105211521252135214521552165217521852195220522152225223522452255226522752285229523052315232523352345235523652375238523952405241524252435244524552465247524852495250525152525253525452555256525752585259526052615262526352645265526652675268526952705271527252735274527552765277527852795280528152825283528452855286528752885289529052915292529352945295529652975298529953005301530253035304530553065307530853095310531153125313531453155316531753185319532053215322532353245325532653275328532953305331533253335334533553365337533853395340534153425343534453455346534753485349535053515352535353545355535653575358535953605361536253635364536553665367536853695370537153725373537453755376537753785379538053815382538353845385538653875388538953905391539253935394539553965397539853995400540154025403540454055406540754085409541054115412541354145415541654175418541954205421542254235424542554265427542854295430543154325433543454355436543754385439544054415442544354445445544654475448544954505451545254535454545554565457545854595460546154625463546454655466546754685469547054715472547354745475547654775478547954805481548254835484548554865487548854895490549154925493549454955496549754985499550055015502550355045505550655075508550955105511551255135514551555165517551855195520552155225523552455255526552755285529553055315532553355345535553655375538553955405541554255435544554555465547554855495550555155525553555455555556555755585559556055615562556355645565556655675568556955705571557255735574557555765577557855795580558155825583558455855586558755885589559055915592559355945595559655975598559956005601560256035604560556065607560856095610561156125613561456155616561756185619562056215622562356245625562656275628562956305631563256335634563556365637563856395640564156425643564456455646564756485649565056515652565356545655565656575658565956605661566256635664566556665667566856695670567156725673567456755676567756785679568056815682568356845685568656875688568956905691569256935694569556965697569856995700570157025703570457055706570757085709571057115712571357145715571657175718571957205721572257235724572557265727572857295730573157325733573457355736573757385739574057415742574357445745574657475748574957505751575257535754575557565757575857595760576157625763576457655766576757685769577057715772577357745775577657775778577957805781578257835784578557865787578857895790579157925793579457955796579757985799580058015802580358045805580658075808580958105811581258135814581558165817581858195820582158225823582458255826582758285829583058315832583358345835583658375838583958405841584258435844584558465847584858495850585158525853585458555856585758585859586058615862586358645865586658675868586958705871587258735874587558765877587858795880588158825883588458855886588758885889589058915892589358945895589658975898589959005901590259035904590559065907590859095910591159125913591459155916591759185919592059215922592359245925592659275928592959305931593259335934593559365937593859395940594159425943594459455946594759485949595059515952595359545955595659575958595959605961596259635964596559665967596859695970597159725973597459755976597759785979598059815982598359845985598659875988598959905991599259935994599559965997599859996000600160026003600460056006600760086009601060116012601360146015601660176018601960206021602260236024602560266027602860296030603160326033603460356036603760386039604060416042604360446045604660476048604960506051605260536054605560566057605860596060606160626063606460656066606760686069607060716072607360746075607660776078607960806081608260836084608560866087608860896090609160926093609460956096609760986099610061016102610361046105610661076108610961106111611261136114611561166117611861196120612161226123612461256126612761286129613061316132613361346135613661376138613961406141614261436144614561466147614861496150615161526153615461556156615761586159616061616162616361646165616661676168616961706171617261736174617561766177617861796180618161826183618461856186618761886189619061916192619361946195619661976198619962006201620262036204620562066207620862096210621162126213621462156216621762186219622062216222622362246225622662276228622962306231623262336234623562366237623862396240624162426243624462456246624762486249625062516252625362546255625662576258625962606261626262636264626562666267626862696270627162726273627462756276627762786279628062816282628362846285628662876288628962906291629262936294629562966297629862996300630163026303630463056306630763086309631063116312631363146315631663176318631963206321632263236324632563266327632863296330633163326333633463356336633763386339634063416342634363446345634663476348634963506351635263536354635563566357635863596360636163626363636463656366636763686369637063716372637363746375637663776378637963806381638263836384638563866387638863896390639163926393639463956396639763986399640064016402640364046405640664076408640964106411641264136414641564166417641864196420642164226423642464256426642764286429643064316432643364346435643664376438643964406441644264436444644564466447644864496450645164526453645464556456645764586459646064616462646364646465646664676468646964706471647264736474647564766477647864796480648164826483648464856486648764886489649064916492649364946495649664976498649965006501650265036504650565066507650865096510651165126513651465156516651765186519652065216522652365246525652665276528652965306531653265336534653565366537653865396540654165426543654465456546654765486549655065516552655365546555655665576558655965606561656265636564656565666567656865696570657165726573657465756576657765786579658065816582658365846585658665876588658965906591659265936594659565966597659865996600660166026603660466056606660766086609661066116612661366146615661666176618661966206621662266236624662566266627662866296630663166326633663466356636663766386639664066416642664366446645664666476648664966506651665266536654665566566657665866596660666166626663666466656666666766686669667066716672667366746675667666776678667966806681668266836684668566866687668866896690669166926693669466956696669766986699670067016702670367046705670667076708670967106711671267136714671567166717671867196720672167226723672467256726672767286729673067316732673367346735673667376738673967406741674267436744674567466747674867496750675167526753675467556756675767586759676067616762676367646765676667676768676967706771677267736774677567766777677867796780678167826783678467856786678767886789679067916792679367946795679667976798679968006801680268036804680568066807680868096810681168126813681468156816681768186819682068216822682368246825682668276828682968306831683268336834683568366837683868396840684168426843684468456846684768486849685068516852685368546855685668576858685968606861686268636864686568666867686868696870687168726873687468756876687768786879688068816882688368846885688668876888688968906891689268936894689568966897689868996900690169026903690469056906690769086909691069116912691369146915691669176918691969206921692269236924692569266927692869296930693169326933693469356936693769386939694069416942694369446945694669476948694969506951695269536954695569566957695869596960696169626963696469656966696769686969697069716972697369746975697669776978697969806981698269836984698569866987698869896990699169926993699469956996699769986999700070017002700370047005700670077008700970107011701270137014701570167017701870197020702170227023702470257026702770287029703070317032703370347035703670377038703970407041704270437044704570467047704870497050705170527053705470557056705770587059706070617062706370647065706670677068706970707071707270737074707570767077707870797080708170827083708470857086708770887089709070917092709370947095709670977098709971007101710271037104710571067107710871097110711171127113711471157116711771187119712071217122712371247125712671277128712971307131713271337134713571367137713871397140714171427143714471457146714771487149715071517152715371547155715671577158715971607161716271637164716571667167716871697170717171727173717471757176717771787179718071817182718371847185718671877188718971907191719271937194719571967197719871997200720172027203720472057206720772087209721072117212721372147215721672177218721972207221722272237224722572267227722872297230723172327233723472357236723772387239724072417242724372447245724672477248724972507251725272537254725572567257725872597260726172627263726472657266726772687269727072717272727372747275727672777278727972807281728272837284728572867287728872897290729172927293729472957296729772987299730073017302730373047305730673077308730973107311731273137314731573167317731873197320732173227323732473257326732773287329733073317332733373347335733673377338733973407341734273437344734573467347734873497350735173527353735473557356735773587359736073617362736373647365736673677368736973707371737273737374737573767377737873797380738173827383738473857386738773887389739073917392739373947395739673977398739974007401740274037404740574067407740874097410741174127413741474157416741774187419742074217422742374247425742674277428742974307431743274337434743574367437743874397440744174427443744474457446744774487449745074517452745374547455745674577458745974607461746274637464746574667467746874697470747174727473747474757476747774787479748074817482748374847485748674877488748974907491749274937494749574967497749874997500750175027503750475057506750775087509751075117512751375147515751675177518751975207521752275237524752575267527752875297530753175327533753475357536753775387539754075417542754375447545754675477548754975507551755275537554755575567557755875597560756175627563756475657566756775687569757075717572757375747575757675777578757975807581758275837584758575867587758875897590759175927593759475957596759775987599760076017602760376047605760676077608760976107611761276137614761576167617761876197620762176227623762476257626762776287629763076317632763376347635763676377638763976407641764276437644764576467647764876497650765176527653765476557656765776587659766076617662766376647665766676677668766976707671767276737674767576767677767876797680768176827683768476857686768776887689769076917692769376947695769676977698769977007701770277037704770577067707770877097710771177127713771477157716771777187719772077217722772377247725772677277728772977307731773277337734773577367737773877397740774177427743774477457746774777487749775077517752775377547755775677577758775977607761776277637764776577667767776877697770777177727773777477757776777777787779778077817782778377847785778677877788778977907791779277937794779577967797779877997800780178027803780478057806780778087809781078117812781378147815781678177818781978207821782278237824782578267827782878297830783178327833783478357836783778387839784078417842784378447845784678477848784978507851785278537854785578567857785878597860786178627863786478657866786778687869787078717872787378747875787678777878787978807881788278837884788578867887788878897890789178927893789478957896789778987899790079017902790379047905790679077908790979107911791279137914791579167917791879197920792179227923792479257926792779287929793079317932793379347935793679377938793979407941794279437944794579467947794879497950795179527953795479557956795779587959796079617962796379647965796679677968796979707971797279737974797579767977797879797980798179827983798479857986798779887989799079917992799379947995799679977998799980008001800280038004800580068007800880098010801180128013801480158016801780188019802080218022802380248025802680278028802980308031803280338034803580368037803880398040804180428043804480458046804780488049805080518052805380548055805680578058805980608061806280638064806580668067806880698070807180728073807480758076807780788079808080818082808380848085808680878088808980908091809280938094809580968097809880998100810181028103810481058106810781088109811081118112811381148115811681178118811981208121812281238124812581268127812881298130813181328133813481358136813781388139814081418142814381448145814681478148814981508151815281538154815581568157815881598160816181628163816481658166816781688169817081718172817381748175817681778178817981808181818281838184818581868187818881898190819181928193819481958196819781988199820082018202820382048205820682078208820982108211821282138214821582168217821882198220822182228223822482258226822782288229823082318232823382348235823682378238823982408241824282438244824582468247824882498250825182528253825482558256825782588259826082618262826382648265826682678268826982708271827282738274827582768277827882798280828182828283828482858286828782888289829082918292829382948295829682978298829983008301830283038304830583068307830883098310831183128313831483158316831783188319832083218322832383248325832683278328832983308331833283338334833583368337833883398340834183428343834483458346834783488349835083518352835383548355835683578358835983608361836283638364836583668367836883698370837183728373837483758376837783788379838083818382838383848385838683878388838983908391839283938394839583968397839883998400840184028403840484058406840784088409841084118412841384148415841684178418841984208421842284238424842584268427842884298430843184328433843484358436843784388439844084418442844384448445844684478448844984508451845284538454845584568457845884598460846184628463846484658466846784688469847084718472847384748475847684778478847984808481848284838484848584868487848884898490849184928493849484958496849784988499850085018502850385048505850685078508850985108511851285138514851585168517851885198520852185228523852485258526852785288529853085318532853385348535853685378538853985408541854285438544854585468547854885498550855185528553855485558556855785588559856085618562856385648565856685678568856985708571857285738574857585768577857885798580858185828583858485858586858785888589859085918592859385948595859685978598859986008601860286038604860586068607860886098610861186128613861486158616861786188619862086218622862386248625862686278628862986308631863286338634863586368637863886398640864186428643864486458646864786488649865086518652865386548655865686578658865986608661866286638664866586668667866886698670867186728673867486758676867786788679868086818682868386848685868686878688868986908691869286938694869586968697869886998700870187028703870487058706870787088709871087118712871387148715871687178718871987208721872287238724872587268727872887298730873187328733873487358736873787388739874087418742874387448745874687478748874987508751875287538754875587568757875887598760876187628763876487658766876787688769877087718772877387748775877687778778877987808781878287838784878587868787878887898790879187928793879487958796879787988799880088018802880388048805880688078808880988108811881288138814881588168817881888198820882188228823882488258826882788288829883088318832883388348835883688378838883988408841884288438844884588468847884888498850885188528853885488558856885788588859886088618862886388648865886688678868886988708871887288738874887588768877887888798880888188828883888488858886888788888889889088918892889388948895889688978898889989008901890289038904890589068907890889098910891189128913891489158916891789188919892089218922892389248925892689278928892989308931893289338934893589368937893889398940894189428943894489458946894789488949895089518952895389548955895689578958895989608961896289638964896589668967896889698970897189728973897489758976897789788979898089818982898389848985898689878988898989908991899289938994899589968997899889999000900190029003900490059006900790089009901090119012901390149015901690179018901990209021902290239024902590269027902890299030903190329033903490359036903790389039904090419042904390449045904690479048904990509051905290539054905590569057905890599060906190629063906490659066906790689069907090719072907390749075907690779078907990809081908290839084908590869087908890899090909190929093909490959096909790989099910091019102910391049105910691079108910991109111911291139114911591169117911891199120912191229123912491259126912791289129913091319132913391349135913691379138913991409141914291439144914591469147914891499150915191529153915491559156915791589159916091619162916391649165916691679168916991709171917291739174917591769177917891799180918191829183918491859186918791889189919091919192919391949195919691979198919992009201920292039204920592069207920892099210921192129213921492159216921792189219922092219222922392249225922692279228922992309231923292339234923592369237923892399240924192429243924492459246924792489249925092519252925392549255925692579258925992609261926292639264926592669267926892699270927192729273927492759276927792789279928092819282928392849285928692879288928992909291929292939294929592969297929892999300930193029303930493059306930793089309931093119312931393149315931693179318931993209321932293239324932593269327932893299330933193329333933493359336933793389339934093419342934393449345934693479348934993509351935293539354935593569357935893599360936193629363936493659366936793689369937093719372937393749375937693779378937993809381938293839384938593869387938893899390939193929393939493959396939793989399940094019402940394049405940694079408940994109411941294139414941594169417941894199420942194229423942494259426942794289429943094319432943394349435943694379438943994409441944294439444944594469447944894499450945194529453945494559456945794589459946094619462946394649465946694679468946994709471947294739474947594769477947894799480948194829483948494859486948794889489949094919492949394949495949694979498949995009501950295039504950595069507950895099510951195129513951495159516951795189519952095219522952395249525952695279528952995309531953295339534953595369537953895399540954195429543954495459546954795489549955095519552955395549555955695579558955995609561956295639564956595669567956895699570957195729573957495759576957795789579958095819582958395849585958695879588958995909591959295939594959595969597959895999600960196029603960496059606960796089609961096119612961396149615961696179618961996209621962296239624962596269627962896299630963196329633963496359636963796389639964096419642964396449645964696479648964996509651965296539654965596569657965896599660966196629663966496659666966796689669967096719672967396749675967696779678967996809681968296839684968596869687968896899690969196929693969496959696969796989699970097019702970397049705970697079708970997109711971297139714971597169717971897199720972197229723972497259726972797289729973097319732973397349735973697379738973997409741974297439744974597469747974897499750975197529753975497559756975797589759976097619762976397649765976697679768976997709771977297739774977597769777977897799780978197829783978497859786978797889789979097919792979397949795979697979798979998009801980298039804980598069807980898099810981198129813981498159816981798189819982098219822982398249825982698279828982998309831983298339834983598369837983898399840984198429843984498459846984798489849985098519852985398549855985698579858985998609861986298639864986598669867986898699870987198729873987498759876987798789879988098819882988398849885988698879888988998909891989298939894989598969897989898999900990199029903990499059906990799089909991099119912991399149915991699179918991999209921992299239924992599269927992899299930993199329933993499359936993799389939994099419942994399449945994699479948994999509951995299539954995599569957995899599960996199629963996499659966996799689969997099719972997399749975997699779978997999809981998299839984998599869987998899899990999199929993999499959996999799989999100001000110002100031000410005100061000710008100091001010011100121001310014100151001610017100181001910020100211002210023100241002510026100271002810029100301003110032100331003410035100361003710038100391004010041100421004310044100451004610047100481004910050100511005210053100541005510056100571005810059100601006110062100631006410065100661006710068100691007010071100721007310074100751007610077100781007910080100811008210083100841008510086100871008810089100901009110092100931009410095100961009710098100991010010101101021010310104101051010610107101081010910110101111011210113101141011510116101171011810119101201012110122101231012410125101261012710128101291013010131101321013310134101351013610137101381013910140101411014210143101441014510146101471014810149101501015110152101531015410155101561015710158101591016010161101621016310164101651016610167101681016910170101711017210173101741017510176101771017810179101801018110182101831018410185101861018710188101891019010191101921019310194101951019610197101981019910200102011020210203102041020510206102071020810209102101021110212102131021410215102161021710218102191022010221102221022310224102251022610227102281022910230102311023210233102341023510236102371023810239102401024110242102431024410245102461024710248102491025010251102521025310254102551025610257102581025910260102611026210263102641026510266102671026810269102701027110272102731027410275102761027710278102791028010281102821028310284102851028610287102881028910290102911029210293102941029510296102971029810299103001030110302103031030410305103061030710308103091031010311103121031310314103151031610317103181031910320103211032210323103241032510326103271032810329103301033110332103331033410335103361033710338103391034010341103421034310344103451034610347103481034910350103511035210353103541035510356103571035810359103601036110362103631036410365103661036710368103691037010371103721037310374103751037610377103781037910380103811038210383103841038510386103871038810389103901039110392103931039410395103961039710398103991040010401104021040310404104051040610407104081040910410104111041210413104141041510416104171041810419104201042110422104231042410425104261042710428104291043010431104321043310434104351043610437104381043910440104411044210443104441044510446104471044810449104501045110452104531045410455104561045710458104591046010461104621046310464104651046610467104681046910470104711047210473104741047510476104771047810479104801048110482104831048410485104861048710488104891049010491104921049310494104951049610497104981049910500105011050210503105041050510506105071050810509105101051110512105131051410515105161051710518105191052010521105221052310524105251052610527105281052910530105311053210533105341053510536105371053810539105401054110542105431054410545105461054710548105491055010551105521055310554105551055610557105581055910560105611056210563105641056510566105671056810569105701057110572105731057410575105761057710578105791058010581105821058310584105851058610587105881058910590105911059210593105941059510596105971059810599106001060110602106031060410605106061060710608106091061010611106121061310614106151061610617106181061910620106211062210623106241062510626106271062810629106301063110632106331063410635106361063710638106391064010641106421064310644106451064610647106481064910650106511065210653106541065510656106571065810659106601066110662106631066410665106661066710668106691067010671106721067310674106751067610677106781067910680106811068210683106841068510686106871068810689106901069110692106931069410695106961069710698106991070010701107021070310704107051070610707107081070910710107111071210713107141071510716107171071810719107201072110722107231072410725107261072710728107291073010731107321073310734107351073610737107381073910740107411074210743107441074510746107471074810749107501075110752107531075410755107561075710758107591076010761107621076310764107651076610767107681076910770107711077210773107741077510776107771077810779107801078110782107831078410785107861078710788107891079010791107921079310794107951079610797107981079910800108011080210803108041080510806108071080810809108101081110812108131081410815108161081710818108191082010821108221082310824108251082610827108281082910830108311083210833108341083510836108371083810839108401084110842108431084410845108461084710848108491085010851108521085310854108551085610857108581085910860108611086210863108641086510866108671086810869108701087110872108731087410875108761087710878108791088010881108821088310884108851088610887108881088910890108911089210893108941089510896108971089810899109001090110902109031090410905109061090710908109091091010911109121091310914109151091610917109181091910920109211092210923109241092510926109271092810929109301093110932109331093410935109361093710938109391094010941109421094310944109451094610947109481094910950109511095210953109541095510956109571095810959109601096110962109631096410965109661096710968109691097010971109721097310974109751097610977109781097910980109811098210983109841098510986109871098810989109901099110992109931099410995109961099710998109991100011001110021100311004110051100611007110081100911010110111101211013110141101511016110171101811019110201102111022110231102411025110261102711028110291103011031110321103311034110351103611037110381103911040110411104211043110441104511046110471104811049110501105111052110531105411055110561105711058110591106011061110621106311064110651106611067110681106911070110711107211073110741107511076110771107811079110801108111082110831108411085110861108711088110891109011091110921109311094110951109611097110981109911100111011110211103111041110511106111071110811109111101111111112111131111411115111161111711118111191112011121111221112311124111251112611127111281112911130111311113211133111341113511136111371113811139111401114111142111431114411145111461114711148111491115011151111521115311154111551115611157111581115911160111611116211163111641116511166111671116811169111701117111172111731117411175111761117711178111791118011181111821118311184111851118611187111881118911190111911119211193111941119511196111971119811199112001120111202112031120411205112061120711208112091121011211112121121311214112151121611217112181121911220112211122211223112241122511226112271122811229112301123111232112331123411235112361123711238112391124011241112421124311244112451124611247112481124911250112511125211253112541125511256112571125811259112601126111262112631126411265112661126711268112691127011271112721127311274112751127611277112781127911280112811128211283112841128511286112871128811289112901129111292112931129411295112961129711298112991130011301113021130311304113051130611307113081130911310113111131211313113141131511316113171131811319113201132111322113231132411325113261132711328113291133011331113321133311334113351133611337113381133911340113411134211343113441134511346113471134811349113501135111352113531135411355113561135711358113591136011361113621136311364113651136611367113681136911370113711137211373113741137511376113771137811379113801138111382113831138411385113861138711388113891139011391113921139311394113951139611397113981139911400114011140211403114041140511406114071140811409114101141111412114131141411415114161141711418114191142011421114221142311424114251142611427114281142911430114311143211433114341143511436114371143811439114401144111442114431144411445114461144711448114491145011451114521145311454114551145611457114581145911460114611146211463114641146511466114671146811469114701147111472114731147411475114761147711478114791148011481114821148311484114851148611487114881148911490114911149211493114941149511496114971149811499115001150111502115031150411505115061150711508115091151011511115121151311514115151151611517115181151911520115211152211523115241152511526115271152811529115301153111532115331153411535115361153711538115391154011541115421154311544115451154611547115481154911550115511155211553115541155511556115571155811559115601156111562115631156411565115661156711568115691157011571115721157311574115751157611577115781157911580115811158211583115841158511586115871158811589115901159111592115931159411595115961159711598115991160011601116021160311604116051160611607116081160911610116111161211613116141161511616116171161811619116201162111622116231162411625116261162711628116291163011631116321163311634116351163611637116381163911640116411164211643116441164511646116471164811649116501165111652116531165411655116561165711658116591166011661116621166311664
  1. #LyX 1.6.5 created this file. For more info see http://www.lyx.org/
  2. \lyxformat 345
  3. \begin_document
  4. \begin_header
  5. \textclass paper
  6. \use_default_options true
  7. \language english
  8. \inputencoding auto
  9. \font_roman default
  10. \font_sans default
  11. \font_typewriter default
  12. \font_default_family default
  13. \font_sc false
  14. \font_osf false
  15. \font_sf_scale 100
  16. \font_tt_scale 100
  17. \graphics default
  18. \paperfontsize default
  19. \spacing single
  20. \use_hyperref false
  21. \papersize a4paper
  22. \use_geometry false
  23. \use_amsmath 1
  24. \use_esint 1
  25. \cite_engine basic
  26. \use_bibtopic false
  27. \paperorientation portrait
  28. \secnumdepth 3
  29. \tocdepth 2
  30. \paragraph_separation skip
  31. \defskip medskip
  32. \quotes_language english
  33. \papercolumns 1
  34. \papersides 1
  35. \paperpagestyle default
  36. \tracking_changes false
  37. \output_changes false
  38. \author ""
  39. \author ""
  40. \end_header
  41. \begin_body
  42. \begin_layout Title
  43. Context-Aware API for Android Devices
  44. \end_layout
  45. \begin_layout Author
  46. Chris Smith
  47. \begin_inset Newline newline
  48. \end_inset
  49. Supervisor: Naranker Dulay
  50. \end_layout
  51. \begin_layout Date
  52. Summer 2010
  53. \end_layout
  54. \begin_layout Standard
  55. \begin_inset Newpage pagebreak
  56. \end_inset
  57. \end_layout
  58. \begin_layout Abstract
  59. In recent years location-based services have seen a dramatic increase in
  60. adoption, and all modern smartphone platforms have integrated services
  61. to facilitate the creation location-aware applications.
  62. Such applications enhance the experience of users, using location to modify
  63. content or alter the behaviour of the application to better suit the circumstan
  64. ces.
  65. \end_layout
  66. \begin_layout Abstract
  67. The product of this project is a
  68. \emph on
  69. context
  70. \emph default
  71. -aware API for the Android platform.
  72. This allows applications to augment the already available location data
  73. with extra
  74. \emph on
  75. context
  76. \emph default
  77. about the user's situation - primarily their current activity.
  78. It also develops an algorithm for recognising
  79. \emph on
  80. places
  81. \emph default
  82. which are relevant to the user, and monitoring which activities are performed
  83. in
  84. \emph on
  85. journeys
  86. \emph default
  87. between those places, thus enabling predictions of the user's likely destinatio
  88. n based on their activity.
  89. \end_layout
  90. \begin_layout Abstract
  91. Research into other methods of annotating context was conducted, and it
  92. was found that most potential sources of context information either produced
  93. little or no information, or were too battery-draining to perform in a
  94. real world environment with current technology.
  95. Much effort was placed into optimising the API to have as small effect
  96. on battery life as possible.
  97. \end_layout
  98. \begin_layout Abstract
  99. A context-aware API was successfully produced, along with a collection of
  100. applications which use the API in order to demonstrate its features or
  101. provide example use cases.
  102. \end_layout
  103. \begin_layout Standard
  104. \begin_inset Newpage pagebreak
  105. \end_inset
  106. \end_layout
  107. \begin_layout LyX-Code
  108. \begin_inset CommandInset toc
  109. LatexCommand tableofcontents
  110. \end_inset
  111. \begin_inset Newpage pagebreak
  112. \end_inset
  113. \end_layout
  114. \begin_layout Standard
  115. \begin_inset FloatList figure
  116. \end_inset
  117. \end_layout
  118. \begin_layout Standard
  119. \begin_inset FloatList table
  120. \end_inset
  121. \end_layout
  122. \begin_layout LyX-Code
  123. \begin_inset Newpage pagebreak
  124. \end_inset
  125. \end_layout
  126. \begin_layout Part
  127. Introduction
  128. \end_layout
  129. \begin_layout Section
  130. Proposal
  131. \end_layout
  132. \begin_layout Quote
  133. Objective: to create an API for android applications to query the user's
  134. [probable] current activity, and to consider and implement possible uses
  135. for this API in existing applications.
  136. The user's activity would be determined based on available sensor and ambient
  137. data (e.g.
  138. time, location, orientation/movement of device, background noises, camera
  139. image, in-range bluetooth devices, etc), previous behaviour of the user,
  140. and possibly behaviour of other users which has been shared between devices.
  141. \end_layout
  142. \begin_layout Quote
  143. Motivation: Activity-awareness would be a major step forward in making mobile
  144. devices better able to adapt to what the user wants to do with them.
  145. The latest generation of mobile phones have made location-aware applications
  146. quite ubiquitous, and a lot of these could be further enhanced by making
  147. them activity aware.
  148. For example, an application which lists businesses in a certain area could
  149. not only know the search area (by merit of being location-aware), but could
  150. also make an educated guess at what you're looking for (e.g.
  151. the activity API may suggest the user is likely to be going to lunch, so
  152. the application could initially show nearby eating establishments instead
  153. of requiring the user to search for them).
  154. \end_layout
  155. \begin_layout Quote
  156. Challenges/issues: primary challenge is developing an algorithm which can
  157. make reasonable estimates as to the user's activity (or attempting and
  158. then justifying why such an algorithm is not feasible, and investigating
  159. requirements or alternatives), and would form the bulk of the project.
  160. Sub-challenges within this include: researching/implementing machine learning
  161. techniques so the algorithm can take previous behaviour into account, processin
  162. g data from 'messy' inputs such as mic/camera, and designing an API that
  163. would enable third-party app developers to easily make their applications
  164. activity aware.
  165. \end_layout
  166. \begin_layout Quote
  167. Approach: data from sensors would need to be processed (e.g.
  168. mic input processed into a figure for ambient noise level in dB).
  169. The combination of this processed data would then need to be fed into an
  170. algorithm (possibly a neural network) to determine likelihood of various
  171. activities.
  172. There would need to be some mechanism for users to correct or train the
  173. system (at least initially), and it's possible that this data could then
  174. be shared to other users of the api/application.
  175. \end_layout
  176. \begin_layout Section
  177. Aims and Motivation
  178. \end_layout
  179. \begin_layout Standard
  180. The primary aim of this project is to create an application for the Android
  181. platform that can sense the user's context in some fashion.
  182. This application will have a public interface which will allow other applicatio
  183. ns written by third party developers to read and receive updates about the
  184. user's context.
  185. \end_layout
  186. \begin_layout Standard
  187. The ease of access to location aware services in modern smartphone platforms
  188. has lead to a surge in the number of applications which improve their utility
  189. or behaviour by integrating location information.
  190. It stands to reason that if additional context information were available,
  191. developers would be able to take advantage of this and further improve
  192. the utility of their applications.
  193. This, in turn, would increase the productivity of the end-user.
  194. \end_layout
  195. \begin_layout Standard
  196. As discussed in
  197. \begin_inset CommandInset ref
  198. LatexCommand ref
  199. reference "par:Background"
  200. \end_inset
  201. , a large amount of existing research has been done on context-aware devices,
  202. and specifically on activity-aware systems.
  203. There have also been some limited implementations for smartphones.
  204. Unfortunately, the end product of most of this research is not suitable
  205. for deployment or use in practical, every-day circumstances.
  206. This project aims to produce a working prototype which can be used on a
  207. day-to-day basis on an Android smartphone without significantly degrading
  208. performance.
  209. \end_layout
  210. \begin_layout Section
  211. Issues and challenges
  212. \end_layout
  213. \begin_layout Standard
  214. One of the main challenges for this project will be accomplishing accurate
  215. and useful context-awareness without significantly hindering the battery
  216. life or performance of a typical device.
  217. Existing algorithms tend to be extremely verbose, sometimes performing
  218. upwards of thousands of calculations per classification; on a mobile device
  219. this is likely to severely cripple battery life.
  220. \end_layout
  221. \begin_layout Standard
  222. The problem of battery life affects all areas of the project - from how
  223. often data is collected, how the data is then analysed, and which sources
  224. of potential data are consulted.
  225. A large amount of time will need to be spent analysing the various potential
  226. data sources and establishing whether or not the cost in consulting them
  227. is worth the reduction in battery lifetime and any gain in the reliability
  228. or accuracy of context information.
  229. \end_layout
  230. \begin_layout Standard
  231. The aim of the application is to provide the context data to third-party
  232. applications, so another challenge will be designing an appropriate interface
  233. which will allow applications to query and receive updates about the user's
  234. context.
  235. Consideration will have to be given as to any security measures (such as
  236. access control) which may need to be applied in order to protect user privacy.
  237. \end_layout
  238. \begin_layout Section
  239. Structure
  240. \end_layout
  241. \begin_layout Standard
  242. Part
  243. \begin_inset CommandInset ref
  244. LatexCommand prettyref
  245. reference "par:Background"
  246. \end_inset
  247. summarises some of the current work in the field of context-aware systems
  248. and activity inference.
  249. Part
  250. \begin_inset CommandInset ref
  251. LatexCommand prettyref
  252. reference "par:Activity-classification"
  253. \end_inset
  254. explains in detail the techniques developed to classify user activity from
  255. accelerometer data, applications developed to facilitate this, and analyses
  256. data collected from users to determine the accuracy of the activity classificat
  257. ion algorithms.
  258. Parts
  259. \begin_inset CommandInset ref
  260. LatexCommand prettyref
  261. reference "par:Other-sensors"
  262. \end_inset
  263. and
  264. \begin_inset CommandInset ref
  265. LatexCommand prettyref
  266. reference "par:Places"
  267. \end_inset
  268. deal with potential context information from other sensors such as microphones
  269. and cameras, and the contextual value of the user's location, and how interesti
  270. ng places can be inferred.
  271. \end_layout
  272. \begin_layout Standard
  273. Part
  274. \begin_inset CommandInset ref
  275. LatexCommand prettyref
  276. reference "par:The-Context-Analyser"
  277. \end_inset
  278. introduces the Context Analyser, the primary output of this proejct, and
  279. its suite of related applications.
  280. The project is evaluated in part
  281. \begin_inset CommandInset ref
  282. LatexCommand prettyref
  283. reference "par:Evaluation"
  284. \end_inset
  285. and conclusions drawn and future work considered in part
  286. \begin_inset CommandInset ref
  287. LatexCommand prettyref
  288. reference "par:Conclusion"
  289. \end_inset
  290. .
  291. \end_layout
  292. \begin_layout Standard
  293. \begin_inset Newpage pagebreak
  294. \end_inset
  295. \end_layout
  296. \begin_layout Part
  297. Background
  298. \begin_inset CommandInset label
  299. LatexCommand label
  300. name "par:Background"
  301. \end_inset
  302. \end_layout
  303. \begin_layout Standard
  304. Context- or Activity-Aware devices is an area currently under lots of research.
  305. There are many and varied applications of activity-aware devices, ranging
  306. from personal fitness and healthcare to training factory workers or merely
  307. playing music.
  308. \end_layout
  309. \begin_layout Standard
  310. While this research is going on, there has been a huge expansion in the
  311. ownership, use and power of mobile telephones.
  312. Mobile telephones are so ubiquitous and now come with such a large sensor
  313. platform that they are the obvious choice for implementing activity-aware
  314. technologies for use in day-to-day life.
  315. \end_layout
  316. \begin_layout Standard
  317. This project aims to make a context-aware API available on an open mobile
  318. platform, which will enable developers to start adding context-aware functional
  319. ity to their applications without the extremely large overhead of writing
  320. a logger and classifier themselves, or re-engineering the application to
  321. use an existing context-aware framework if one is available.
  322. \end_layout
  323. \begin_layout Section
  324. Applications
  325. \end_layout
  326. \begin_layout Standard
  327. There are many documented applications of activity-aware systems, and current
  328. research efforts which bring the technology to mobile telephones will only
  329. serve to lengthen this list.
  330. \end_layout
  331. \begin_layout Standard
  332. The canonical example for activity-awareness, especially on mobile telephones,
  333. is modeling the user's
  334. \begin_inset Quotes eld
  335. \end_inset
  336. interruptibility
  337. \begin_inset Quotes erd
  338. \end_inset
  339. \begin_inset CommandInset citation
  340. LatexCommand cite
  341. key "Siewiorek2003,Raento2005"
  342. \end_inset
  343. .
  344. This allows the software to know whether it's appropriate (or "polite")
  345. to disturb the user, and can advise the user's contacts when they are busy.
  346. It can also be used to create a
  347. \begin_inset Quotes eld
  348. \end_inset
  349. smart answering machine
  350. \begin_inset Quotes erd
  351. \end_inset
  352. \begin_inset CommandInset citation
  353. LatexCommand cite
  354. key "Hudson2003"
  355. \end_inset
  356. which can selectively direct calls straight to an answering machine if
  357. the user is engaged in an "uninterpretable" activity and the call does
  358. not appear to be important.
  359. These allow the user's mobile telephone to better approximate human behaviour
  360. - when approaching someone in person it is normally quite easy to determine
  361. whether it would be polite or necessary to disturb them, based on their
  362. demeanour, activity, and the urgency of your request; when picking up the
  363. telephone it is not possible at all without assistance from an activity-aware
  364. system.
  365. \end_layout
  366. \begin_layout Standard
  367. The current implementations of these ideas have several problems, however.
  368. The more interesting research
  369. \begin_inset CommandInset citation
  370. LatexCommand cite
  371. key "Hudson2003"
  372. \end_inset
  373. requires a static camera fixed in an office to observe user behaviour,
  374. instead of implementing it directly on a telephone, which obviously constrains
  375. its usefulness.
  376. Of the two solutions actually targeted at mobile telephones, one
  377. \begin_inset CommandInset citation
  378. LatexCommand cite
  379. key "Siewiorek2003"
  380. \end_inset
  381. requires bulky custom hardware which the user must carry on their belt,
  382. and the other
  383. \begin_inset CommandInset citation
  384. LatexCommand cite
  385. key "Raento2005"
  386. \end_inset
  387. does not expose an API to other applications and only surfaces the context-aware
  388. functionality in two small applications whose focus is on social interaction
  389. rather than improving the user's experience of the telephone locally.
  390. This project will aim to bring the ideas of these to generic hardware (an
  391. Android mobile telephone), and to provide an API which other applications
  392. can harness.
  393. \end_layout
  394. \begin_layout Standard
  395. One use particularly suitable for mobile phones is dynamic adaptation of
  396. the device's settings based on the user's current activity and context
  397. \begin_inset CommandInset citation
  398. LatexCommand cite
  399. key "Schmidt1999"
  400. \end_inset
  401. .
  402. When a user is walking the device can dynamically increase the font size
  403. to make it easier to read with an unsteady hand, and correspondingly decrease
  404. it when the user is stationary.
  405. In a similar fashion, the brightness of the backlight can be altered based
  406. on the ambient light level, and the ringer volume altered according to
  407. the noise level.
  408. Unfortunately this research did not progress beyond a feasibility study
  409. and was implemented on a Nokia 6110, which is severely outdated by today's
  410. standards.
  411. \end_layout
  412. \begin_layout Standard
  413. Another popular area for activity-aware systems is in healthcare.
  414. Such systems can be used to monitor vulnerable people as they go about
  415. day to day activities to ensure that they're not in trouble - several systems
  416. \begin_inset CommandInset citation
  417. LatexCommand cite
  418. key "Song2005,Maurer2006"
  419. \end_inset
  420. can be used to monitor elderly persons and summon help if it is detected
  421. that they have fallen.
  422. Another healthcare application
  423. \begin_inset CommandInset citation
  424. LatexCommand cite
  425. key "Tentori2008"
  426. \end_inset
  427. allows nurses to remotely monitor the activities of their patients in a
  428. hospital ward, allowing them to respond to problems and keep up-to-date
  429. with their patients' well-being while not physically present.
  430. Activity-aware applications have also been used to try to encourage users
  431. to be more healthy; one novel application records the day-to-day fitness
  432. activities a user performs and uses this as a basis for a virtual
  433. \begin_inset Quotes eld
  434. \end_inset
  435. garden
  436. \begin_inset Quotes erd
  437. \end_inset
  438. that blossoms or wilts according to how much the user works out in a week
  439. \begin_inset CommandInset citation
  440. LatexCommand cite
  441. key "Consolvo2008"
  442. \end_inset
  443. .
  444. \end_layout
  445. \begin_layout Standard
  446. As well as monitoring activities which the user is familiar with, activity-aware
  447. systems can also be used to assist users in learning new activities.
  448. One application
  449. \begin_inset CommandInset citation
  450. LatexCommand cite
  451. key "Stiefmeier2008"
  452. \end_inset
  453. monitors the activities of trainee workers in a car manufacturing plant,
  454. and helps to provide a link between theoretical classroom-based training
  455. and practical work.
  456. The activity-aware system can offer advice to the workers that's directly
  457. related to the current task they're performing, and can even monitor their
  458. activities for compliance with procedures and give them a score afterwards.
  459. \end_layout
  460. \begin_layout Standard
  461. While the research into healthcare and training applications present novel
  462. uses of activity-aware systems, the applications themselves are not really
  463. applicable to a mobile device or the scope of this project.
  464. The research does, however, describe the techniques used in those applications
  465. for activity classification and should prove useful in that respect.
  466. \end_layout
  467. \begin_layout Standard
  468. Other areas of research include making activity-aware suggestions to the
  469. user
  470. \begin_inset CommandInset citation
  471. LatexCommand cite
  472. key "Bellotti2008"
  473. \end_inset
  474. , or issuing reminders or alerts based on the user's activity
  475. \begin_inset CommandInset citation
  476. LatexCommand cite
  477. key "Schilit1994"
  478. \end_inset
  479. .
  480. One example of the latter is an activity-aware system that detects when
  481. the user is making coffee, and plays a sound on a remote computer to alert
  482. thirsty coworkers to the fact.
  483. Sound isn't only limited to alerts, however: the
  484. \noun on
  485. XPOD
  486. \noun default
  487. \begin_inset CommandInset citation
  488. LatexCommand cite
  489. key "Dornbush2005"
  490. \end_inset
  491. project is an activity-aware music player, which tailors the music being
  492. played to the user's current activity based on their past ratings.
  493. This type of activity-aware device presents a much greater level of personalisa
  494. tion than previously possible, and making this type of customisation available
  495. to mobile telephone users and application developers will surely result
  496. in many new applications.
  497. \end_layout
  498. \begin_layout Section
  499. Inferring activity
  500. \end_layout
  501. \begin_layout Standard
  502. There are three general phases in most context-aware systems: a sensing
  503. component, which reads or receives raw sensor data relating to the user's
  504. environment or activity; a feature extraction component, which analysis
  505. the sensor data and identifies a set of features from that data; and a
  506. classification component, which uses the extracted features to reason about
  507. the user's activity
  508. \begin_inset CommandInset citation
  509. LatexCommand cite
  510. key "Choudhury2008"
  511. \end_inset
  512. .
  513. Each of these components will be expanded on below.
  514. Depending on the method of classification, some initial or continuous training
  515. may be required, and this is also considered below.
  516. \end_layout
  517. \begin_layout Subsection
  518. Sensors and devices
  519. \end_layout
  520. \begin_layout Standard
  521. At the basis of activity-recognition are the physical hardware sensors.
  522. The most commonly used sensor is the accelerometer, which outputs the accelerat
  523. ion of the sensor
  524. \begin_inset Foot
  525. status collapsed
  526. \begin_layout Plain Layout
  527. and thus the device to which it's attached, and therefore the person using
  528. the device
  529. \end_layout
  530. \end_inset
  531. along a certain axis.
  532. There is extensive research on using accelerometers to classify activities
  533. such as walking
  534. \begin_inset CommandInset citation
  535. LatexCommand cite
  536. key "Mathie2004,Garakani2009"
  537. \end_inset
  538. (including whether or not the subject is walking on flat ground or up and
  539. down stairs
  540. \begin_inset CommandInset citation
  541. LatexCommand cite
  542. key "Caros2005"
  543. \end_inset
  544. ), running
  545. \begin_inset CommandInset citation
  546. LatexCommand cite
  547. key "Garakani2009"
  548. \end_inset
  549. , falling
  550. \begin_inset CommandInset citation
  551. LatexCommand cite
  552. key "Mathie2004"
  553. \end_inset
  554. , sitting
  555. \begin_inset CommandInset citation
  556. LatexCommand cite
  557. key "Mathie2004,Garakani2009"
  558. \end_inset
  559. , cycling
  560. \begin_inset CommandInset citation
  561. LatexCommand cite
  562. key "Garakani2009"
  563. \end_inset
  564. , etc.
  565. \end_layout
  566. \begin_layout Standard
  567. Smartphones also come equipped with a microphone and GSM stack (prerequisites
  568. for a telephone conversation!), and commonly a camera, geolocation API
  569. (usually backed by GPS) and Bluetooth stack.
  570. With the exception of the latter two, these types of sensors are not particular
  571. ly well explored for their use in context-aware systems at present.
  572. It is easy to reason how each would be useful - a microphone can reveal
  573. the ambient noise, which could indicate the difference between sitting
  574. in a library and a bar; the camera likewise can reveal the lighting conditions
  575. (if the device is not in a pocket or bag).
  576. The GSM stack can provide rough location information and also a signal
  577. strength to one or more cell towers; the signal strength will vary both
  578. with the user's proximity to the cell tower and the environment around
  579. them - being inside will degrade the signal more than being in open air,
  580. for example - so may provide vital clues to a context-aware system.
  581. One aspect of this project will be to research how the microphone, camera
  582. and GSM stack can be used to enhance existing activity classification algorithm
  583. s.
  584. \end_layout
  585. \begin_layout Standard
  586. Current research on location information and Bluetooth device proximity
  587. is summarised in section
  588. \begin_inset CommandInset ref
  589. LatexCommand ref
  590. reference "sec:Location-analysis"
  591. \end_inset
  592. (p
  593. \begin_inset CommandInset ref
  594. LatexCommand pageref
  595. reference "sec:Location-analysis"
  596. \end_inset
  597. ) and
  598. \begin_inset CommandInset ref
  599. LatexCommand ref
  600. reference "sec:Bluetooth-1"
  601. \end_inset
  602. (p
  603. \begin_inset CommandInset ref
  604. LatexCommand pageref
  605. reference "sec:Bluetooth-1"
  606. \end_inset
  607. ) respectively.
  608. \end_layout
  609. \begin_layout Subsection
  610. Feature detection
  611. \end_layout
  612. \begin_layout Standard
  613. It is not possible to reason directly about raw sensor inputs, so the next
  614. step in inferring activities is to extract useful
  615. \emph on
  616. features
  617. \emph default
  618. from the raw input.
  619. Features are usually mathematical properties of the input data, such as
  620. the difference between the minimum and maximum data point in a given time
  621. frame.
  622. Most classifiers use an extremely large number of features -
  623. \begin_inset CommandInset citation
  624. LatexCommand citet
  625. key "Hein2008"
  626. \end_inset
  627. detect 562 different features from their inputs.
  628. \end_layout
  629. \begin_layout Standard
  630. Some of the more commonly used features in activity-recognition systems
  631. are: mean, standard deviation, energy, entropy, correlation between axis,
  632. and discrete FFT coefficients
  633. \begin_inset CommandInset citation
  634. LatexCommand cite
  635. key "Huynh2005"
  636. \end_inset
  637. .
  638. Obviously, not all features are of equal value.
  639. FFT coefficients are generally very good indicators of activity, but the
  640. ideal coefficients and window sizes vary depending on the exact activity
  641. that is being detected.
  642. Likewise, the choice of other features to give the best recognition rate
  643. varies depending on the activity being detected
  644. \begin_inset CommandInset citation
  645. LatexCommand cite
  646. key "Huynh2005"
  647. \end_inset
  648. .
  649. \end_layout
  650. \begin_layout Standard
  651. As the sensor data is received continuously, it needs to be partitioned
  652. somehow before features are extracted.
  653. Most implementations use a sliding window approach with a 50% overlap between
  654. windows
  655. \begin_inset CommandInset citation
  656. LatexCommand cite
  657. key "Bao2004"
  658. \end_inset
  659. .
  660. A window size of 10 seconds with a 50% overlap would result in one set
  661. of features being computed every 5 seconds.
  662. The window size is normally selected to correspond to a pre-defined number
  663. of samples to enable fast computation of certain features - most notably
  664. FFTs
  665. \begin_inset CommandInset citation
  666. LatexCommand cite
  667. key "Bao2004"
  668. \end_inset
  669. .
  670. \end_layout
  671. \begin_layout Standard
  672. One challenge will be determining a set of features that are robust enough
  673. to perform activity analysis on, but are sufficiently inexpensive to calculate
  674. continually on a mobile device, where CPU speed is limited and excessive
  675. usage results in undesirable higher battery consumption.
  676. \end_layout
  677. \begin_layout Subsection
  678. Training
  679. \end_layout
  680. \begin_layout Standard
  681. In order to meaningfully classify and label activities, some kind of training
  682. generally needs to be performed beforehand.
  683. The choice of classifier affects how much offline analysis has to be done
  684. on the training set, and whether or not it can be adapted at run-time.
  685. \end_layout
  686. \begin_layout Standard
  687. One might expect that training would best be performed in a controlled environme
  688. nt, to reduce external influences on the user, but subjects in a laboratory
  689. setting are much more self-conscious about their movements, and this manifests
  690. itself in the data collected.
  691. Walking in a laboratory tends to produce acceleration data showing a consistent
  692. gait cycle which can be split into distinct phases, whereas walking in
  693. an uncontrolled setting produces data showing large fluctuations in gait
  694. phases and length.
  695. This means that classifiers trained on laboratory data may achieve a much
  696. lower accuracy when deployed in natural conditions
  697. \begin_inset CommandInset citation
  698. LatexCommand cite
  699. key "Bao2004"
  700. \end_inset
  701. .
  702. \end_layout
  703. \begin_layout Subsection
  704. Classification
  705. \end_layout
  706. \begin_layout Standard
  707. The classification step involves feeding the features for frame into some
  708. kind of machine learning algorithm which can, using training data
  709. \begin_inset Foot
  710. status collapsed
  711. \begin_layout Plain Layout
  712. and any offline analysis made of that data
  713. \end_layout
  714. \end_inset
  715. , determine which activity the feature-set most like represents.
  716. There are many different algorithms that can be used to perform the classificat
  717. ion, some of which are discussed below.
  718. \end_layout
  719. \begin_layout Subsubsection
  720. Decision trees
  721. \end_layout
  722. \begin_layout Standard
  723. Decision trees are possibly one of the simplest approaches possible
  724. \begin_inset CommandInset citation
  725. LatexCommand cite
  726. key "Hudson2003"
  727. \end_inset
  728. .
  729. A tree is constructed such that each node contains a test function, with
  730. branches for each possible discrete outcome of the function.
  731. This allows data to be classified with a
  732. \begin_inset Quotes eld
  733. \end_inset
  734. divide and conquer
  735. \begin_inset Quotes erd
  736. \end_inset
  737. approach.
  738. While high accuracy is possible in some circumstances
  739. \begin_inset CommandInset citation
  740. LatexCommand cite
  741. key "Hudson2003"
  742. \end_inset
  743. , there are several drawbacks to decision trees: a plain decision tree has
  744. no way to model uncertainty - in an activity-aware system there will always
  745. be a degree of uncertainty as to the classification, and being able to
  746. measure this is an important tool.
  747. They also have an inductive bias which leads to a preference for the most
  748. general solution, and in most cases this generalisation causes many false
  749. results
  750. \begin_inset CommandInset citation
  751. LatexCommand cite
  752. key "Shen2004"
  753. \end_inset
  754. .
  755. \end_layout
  756. \begin_layout Standard
  757. Decision trees require the structure of the tree and the test functions
  758. for each node to be determined during training.
  759. They do not lend themselves to minor on-the-fly modifications or new activities
  760. that are not part of the training set.
  761. \end_layout
  762. \begin_layout Subsubsection
  763. Neural networks
  764. \end_layout
  765. \begin_layout Standard
  766. Neural networks are based on an extremely simplified model of the brain.
  767. The network consists of layers of neurons, and each neuron performs a simple
  768. arithmetic operation on its inputs.
  769. This normally consists of taking each of its inputs, multiplying it by
  770. a weight, and then summing all of the weighted inputs together; the resulting
  771. figure then becomes the neuron's output, and the input to one or more nodes
  772. in the next layer.
  773. \end_layout
  774. \begin_layout Standard
  775. A network consists of a layer of input neurons, a layer containing one or
  776. more output neurons, and one or more layers of
  777. \begin_inset Quotes eld
  778. \end_inset
  779. hidden
  780. \begin_inset Quotes erd
  781. \end_inset
  782. neurons in between.
  783. The number of
  784. \begin_inset Quotes eld
  785. \end_inset
  786. hidden
  787. \begin_inset Quotes erd
  788. \end_inset
  789. layers, and the number of neurons within those layers must be chosen before
  790. training of the network begins.
  791. The training process will then determine the weights for each link in the
  792. network.
  793. The choice of number of layers poses a problem when designing a network,
  794. as too small a number can cripple the power of the network, but too large
  795. can cause it to be too expensive to evaluate and can possibly lead to it
  796. memorising erroneous data
  797. \begin_inset CommandInset citation
  798. LatexCommand cite
  799. key "Dornbush2005"
  800. \end_inset
  801. .
  802. \end_layout
  803. \begin_layout Standard
  804. Neural networks, however, do provide good accuracy and could potentially
  805. (although not easily) be modified on-the-fly to cope with new activities.
  806. \end_layout
  807. \begin_layout Subsubsection
  808. Genetic algorithms
  809. \end_layout
  810. \begin_layout Standard
  811. Genetic algorithms use the principle of natural selection to 'evolve' a
  812. solution to a problem.
  813. A set of random solutions are created, and a pre-defined fitness function
  814. is used to determine their relative worth.
  815. The best solutions are then combined together to produce the next generation
  816. of solutions, in a manner roughly analogous to reproduction in animals.
  817. Small
  818. \begin_inset Quotes eld
  819. \end_inset
  820. mutations
  821. \begin_inset Quotes erd
  822. \end_inset
  823. are also introduced into each generation to counter the effect of local
  824. maxima being reached.
  825. \end_layout
  826. \begin_layout Standard
  827. Genetic algorithms can be combined with other techniques such as neural
  828. networks - the weights in the neural network can be
  829. \begin_inset Quotes eld
  830. \end_inset
  831. evolved
  832. \begin_inset Quotes erd
  833. \end_inset
  834. using genetic algorithms to create a neural network which is good as satisfying
  835. the fitness function.
  836. \end_layout
  837. \begin_layout Standard
  838. The drawback of genetic algorithms is the need for a fitness function -
  839. the network will only ever be as good as the fitness function, and if you
  840. have a way to define what makes a good network you could in most cases
  841. hardcode the solution instead of evolving a network to satisfy it.
  842. \end_layout
  843. \begin_layout Subsubsection
  844. Instance-based learning
  845. \end_layout
  846. \begin_layout Standard
  847. Instance-based learning (IBL)
  848. \begin_inset CommandInset citation
  849. LatexCommand cite
  850. key "Witten2000"
  851. \end_inset
  852. algorithms are a class of
  853. \begin_inset Quotes eld
  854. \end_inset
  855. lazy
  856. \begin_inset Quotes erd
  857. \end_inset
  858. algorithms.
  859. They perform classification based on previously observed instances that
  860. have already been classified.
  861. There is no training required for IBLs, they're extremely adept at adapting
  862. to new scenarios, and they have a very low error rate
  863. \begin_inset CommandInset citation
  864. LatexCommand cite
  865. key "Dornbush2005"
  866. \end_inset
  867. which makes them ideal for activity-recognition.
  868. \end_layout
  869. \begin_layout Standard
  870. One particular type of IBL algorithm which is frequently seen in activity-aware
  871. research is the K-Nearest Neighbour (KNN) algorithm
  872. \begin_inset CommandInset citation
  873. LatexCommand cite
  874. key "Han2006"
  875. \end_inset
  876. .
  877. With the KNN algorithm, each sample is treated as a vector, and the distance
  878. \begin_inset Foot
  879. status collapsed
  880. \begin_layout Plain Layout
  881. the euclidean distance is usually used, but any metric will suffice
  882. \end_layout
  883. \end_inset
  884. between the sample and the existing instances is calculated.
  885. The sample is then classified according to the classification of the majority
  886. of its
  887. \begin_inset Formula $k$
  888. \end_inset
  889. nearest neighbours.
  890. \end_layout
  891. \begin_layout Standard
  892. One drawback of IBLs is that each new instance tends to be remembered for
  893. future use, which eventually results in large amounts of memory consumption
  894. and complexity when comparing distances of new samples.
  895. This can be partially overcome by only storing instances which would affect
  896. the classification of new samples
  897. \begin_inset CommandInset citation
  898. LatexCommand cite
  899. key "Witten2000"
  900. \end_inset
  901. .
  902. \end_layout
  903. \begin_layout Standard
  904. The KNN algorithm can be easily extended to support dynamic classification
  905. of new types of activities - if a sample is not within a certain distance
  906. of sufficient other samples, it can be classified as a new type of activity.
  907. \end_layout
  908. \begin_layout Subsubsection
  909. Conclusion
  910. \end_layout
  911. \begin_layout Standard
  912. There are numerous machine learning algorithms available and suitable for
  913. use in activity classification tasks.
  914. There has been a lot of research into their use, and all of the algorithms
  915. discussed have produced good results.
  916. Because of the lack of need for any training, however, the K-Nearest Neighbour
  917. algorithm appears to be the most promising for a mobile device.
  918. Any algorithm that needs explicit training prior to classification would
  919. almost certainly require a desktop application or a remote service to analyse
  920. the data, as it typically requires large amounts of memory and expensive
  921. computations.
  922. This either makes the application extremely cumbersome for the user (they
  923. have to connect their phone to a computer, transfer a file, obtain and
  924. run a separate application, then transfer some file back), or puts a large
  925. resource burden onto the distributor (having to remotely analyse all of
  926. the data from all users would require dedicated hardware for any more than
  927. a few users).
  928. \end_layout
  929. \begin_layout Section
  930. Mobile telephones
  931. \end_layout
  932. \begin_layout Standard
  933. It's hard to overstate the ubiquity of mobile telephones at present.
  934. In 2003, over a billion mobile telephones were sold - six times as many
  935. as the number of personal computers
  936. \begin_inset CommandInset citation
  937. LatexCommand cite
  938. key "Eagle2004"
  939. \end_inset
  940. .
  941. In 2007, this same figure describes the number of cameraphones sold
  942. \begin_inset CommandInset citation
  943. LatexCommand cite
  944. key "Reynolds2008"
  945. \end_inset
  946. , clearly representing a substantial growth in sales and advancements in
  947. the technology.
  948. In fact, mobile telephones are the fastest adopted technology in human
  949. history
  950. \begin_inset CommandInset citation
  951. LatexCommand cite
  952. key "Eagle2004"
  953. \end_inset
  954. .
  955. This ubiquity, coupled with the fact that mobile telephones are comfortably
  956. carried around on a daily basis by most of their users, makes them a very
  957. attractive alternative to more traditional platforms used for activity-aware
  958. research, which typically involved bulky or inconvenient apparatus that
  959. was expensive to manufacture
  960. \begin_inset CommandInset citation
  961. LatexCommand cite
  962. key "Schmidt2008"
  963. \end_inset
  964. and made users very self-conscious.
  965. \end_layout
  966. \begin_layout Subsection
  967. iPhone
  968. \end_layout
  969. \begin_layout Standard
  970. There have been several published works related to activity-recognition
  971. on the iPhone.
  972. The similarity between iPhone and Android platforms means that many of
  973. the concepts developed for or used on the iPhone are applicable to both.
  974. \end_layout
  975. \begin_layout Subsubsection
  976. iLearn
  977. \end_layout
  978. \begin_layout Standard
  979. \noun on
  980. iLearn
  981. \noun default
  982. \begin_inset CommandInset citation
  983. LatexCommand cite
  984. key "Schmidt2008"
  985. \end_inset
  986. is a suite of three tools -
  987. \noun on
  988. iLog
  989. \noun default
  990. ,
  991. \noun on
  992. iModel,
  993. \noun default
  994. and
  995. \noun on
  996. iClassify
  997. \noun default
  998. - which together allow for real-time classification of low-level activities.
  999. \noun on
  1000. iLog
  1001. \noun default
  1002. is run on the user's iPhone and allows the user to specify which activity
  1003. they will be performing.
  1004. The application then records raw sensor data from the iPhone's three-axis
  1005. accelerometer and 124 features computed from this data in real-time.
  1006. The data is then stored on the device, annotated with the selected activity.
  1007. \end_layout
  1008. \begin_layout Standard
  1009. The training data collected by
  1010. \noun on
  1011. iLog
  1012. \noun default
  1013. is then transferred to a desktop computer where
  1014. \noun on
  1015. iModel
  1016. \noun default
  1017. uses a Naïve Bayesian Network (NBN) to create a model which can be used
  1018. to classify future input.
  1019. The choice of NBNs was based on their ability to classify a set of trial
  1020. data correctly, and the low computational cost of classifying data once
  1021. the model has been generated.
  1022. \end_layout
  1023. \begin_layout Standard
  1024. Once the model has been created, it is transferred back to the device where
  1025. it is used by
  1026. \noun on
  1027. iClassify
  1028. \noun default
  1029. .
  1030. This provides an API for other applications, and allows them to register
  1031. for a callback which it publishes the user's current activity to every
  1032. second.
  1033. \end_layout
  1034. \begin_layout Standard
  1035. Unfortunately, neither the source code nor the API are published.
  1036. The inability to run background processes on the iPhone suggests that any
  1037. \begin_inset Quotes eld
  1038. \end_inset
  1039. API
  1040. \begin_inset Quotes erd
  1041. \end_inset
  1042. would have to be more like a framework where the third-party developer
  1043. has to re-engineer their application to use the
  1044. \noun on
  1045. iClassify
  1046. \noun default
  1047. application as a base.
  1048. This is undesirable as it makes it extremely difficult to adapt existing
  1049. applications to use the activity-aware API, and is a very cumbersome way
  1050. of providing what could be a very minor piece of functionality for the
  1051. application.
  1052. \end_layout
  1053. \begin_layout Subsubsection
  1054. Evaluation
  1055. \end_layout
  1056. \begin_layout Standard
  1057. \begin_inset CommandInset citation
  1058. LatexCommand citet
  1059. key "Miluzzo2009"
  1060. \end_inset
  1061. present an evaluation of the iPhone for use in
  1062. \begin_inset Quotes eld
  1063. \end_inset
  1064. people-centric sensing applications
  1065. \begin_inset Quotes erd
  1066. \end_inset
  1067. .
  1068. One of the major drawbacks highlighted is that the iPhone does not support
  1069. applications which run in the background.
  1070. This means that any application wishing to perform continuous real-time
  1071. activity detection would need to run as a foreground process, preventing
  1072. the user from using the device for any other function.
  1073. \end_layout
  1074. \begin_layout Standard
  1075. The research also shows that the computational compatibility of the iPhone
  1076. is more than sufficient to perform the necessary calculations for a typical
  1077. activity-recognising application, which suggests that any modern smart
  1078. phone would be capable of these.
  1079. \end_layout
  1080. \begin_layout Subsubsection
  1081. Multitasking
  1082. \end_layout
  1083. \begin_layout Standard
  1084. Since the evaluation presented above was written, Apple have announced a
  1085. new version of the iPhone OS which supports pseudo multi-tasking.
  1086. However, this form of multi-tasking only allows a limited set of predefined
  1087. functions to be performed, such as playing audio or monitoring location.
  1088. This still prevents continuous real-time activity detection from taking
  1089. place in a useful fashion.
  1090. \end_layout
  1091. \begin_layout Standard
  1092. Further, because of the homogeneous hardware and memory model employed by
  1093. the iPhone, applications typically make assumptions about the amount of
  1094. free memory that will be available to them.
  1095. This prevents any real implementation of multi-tasking, as background apps
  1096. would infringe on this fixed amount of free memory.
  1097. It is therefore unlikely that future updates will enable true, uninhibited
  1098. multi-tasking, as it would break compatibility with a lot of existing applicati
  1099. ons.
  1100. \end_layout
  1101. \begin_layout Subsection
  1102. Android
  1103. \end_layout
  1104. \begin_layout Standard
  1105. While the Android platform is relatively new, it is rapidly gaining market
  1106. share on the more established mobile operating systems.
  1107. A December 2009 survey
  1108. \begin_inset CommandInset citation
  1109. LatexCommand cite
  1110. key "ChangeWave2010"
  1111. \end_inset
  1112. shows that 21% of respondents want their next smartphone purchase to run
  1113. Android, a 350% increase from the same survey conducted three months prior.
  1114. This is compared to the iPhone, which dropped 4% to 28% in the same time
  1115. period.
  1116. Gartner, a respected IT research firm, predicts that by 2012, Android will
  1117. be the second most popular mobile operating system globally
  1118. \begin_inset CommandInset citation
  1119. LatexCommand cite
  1120. key "ComputerWorld2010"
  1121. \end_inset
  1122. .
  1123. \end_layout
  1124. \begin_layout Standard
  1125. In addition to its rapidly increasing popularity, the Android platform offers
  1126. several advantages over the iPhone platform.
  1127. Most notably is the ability to run background processes (called
  1128. \noun on
  1129. services
  1130. \noun default
  1131. ), which will allow a classifier application to run without interfering
  1132. with the user's normal use of their mobile telephone.
  1133. In addition, the Android OS provides access to the Bluetooth and GSM stacks,
  1134. allowing for data from both to be used for activity detection.
  1135. \end_layout
  1136. \begin_layout Standard
  1137. The ability to run a background process will enable a proper API for sharing
  1138. activity data with other applications, which will allow third-party developers
  1139. to make their applications context-aware with relatively little work on
  1140. their part.
  1141. This is extremely desirable as it will allow rapid prototyping of applications,
  1142. which will hopefully lead to innovative new uses of activity classification.
  1143. \end_layout
  1144. \begin_layout Standard
  1145. While it is purported
  1146. \begin_inset CommandInset citation
  1147. LatexCommand cite
  1148. key "Garakani2009"
  1149. \end_inset
  1150. that there is research being done on bringing activity-awareness to Android
  1151. platforms, there does not seem to be any work published on this matter
  1152. or any applications available to support it.
  1153. While there a small number of self-proclaimed
  1154. \begin_inset Quotes eld
  1155. \end_inset
  1156. context-aware
  1157. \begin_inset Quotes erd
  1158. \end_inset
  1159. applications for Android, this context is almost exclusively limited to
  1160. geolocation.
  1161. This project will therefore produce one of the first publicly available
  1162. activity-aware applications for the Android platform.
  1163. \end_layout
  1164. \begin_layout Section
  1165. Location analysis
  1166. \begin_inset CommandInset label
  1167. LatexCommand label
  1168. name "sec:Location-analysis"
  1169. \end_inset
  1170. \end_layout
  1171. \begin_layout Standard
  1172. Location-based services are currently undergoing an
  1173. \begin_inset Quotes eld
  1174. \end_inset
  1175. explosion
  1176. \begin_inset Quotes erd
  1177. \end_inset
  1178. \begin_inset CommandInset citation
  1179. LatexCommand cite
  1180. key "Bellavista2008"
  1181. \end_inset
  1182. , thanks to improvements in technology, and greater openness on the part
  1183. of service providers and handset manufacturers.
  1184. All modern smartphone platforms have a geolocation stack, usually backed
  1185. by a GPS chipset and in most cases augmented with either a database of
  1186. known cell tower locations, or a map of known WiFi network identifiers
  1187. and locations, or both.
  1188. The two databases allow for rough geolocation when GPS is not available,
  1189. or for greatly decreased lookup time when a GPS lock is available.
  1190. \end_layout
  1191. \begin_layout Standard
  1192. However, while the geolocation stack is a rich source of data, it is a poor
  1193. source of information.
  1194. A latitude/longitude pair may describe the user's exact location, but a
  1195. user would be hard-pressed to tell the difference between the latitude/longitud
  1196. e of their home, place of work, or of somewhere in between the two with
  1197. no real significance.
  1198. A great deal of research has therefore been devoted to detecting meaningful
  1199. locations from GPS traces.
  1200. \end_layout
  1201. \begin_layout Standard
  1202. \begin_inset Quotes eld
  1203. \end_inset
  1204. Place recognition
  1205. \begin_inset Quotes erd
  1206. \end_inset
  1207. has two phases: learning and recognising.
  1208. An initial learning phase analyses a sensor log and segments the data into
  1209. places where the device is stable (stationary), and designates this as
  1210. a
  1211. \begin_inset Quotes eld
  1212. \end_inset
  1213. waypoint
  1214. \begin_inset Quotes erd
  1215. \end_inset
  1216. .
  1217. It then merges
  1218. \begin_inset Quotes eld
  1219. \end_inset
  1220. waypoints
  1221. \begin_inset Quotes erd
  1222. \end_inset
  1223. that appear to identify the same place being visited multiple times.
  1224. The second phase uses these learned waypoints to recognise when the device
  1225. is revisiting a place, and therefore also when the device is not visiting
  1226. a previously known place (for example when it is moving between two)
  1227. \begin_inset CommandInset citation
  1228. LatexCommand cite
  1229. key "Hightower2005"
  1230. \end_inset
  1231. .
  1232. \end_layout
  1233. \begin_layout Standard
  1234. Unfortunately, quite a lot of research into location analysis uses GPS
  1235. \begin_inset Quotes eld
  1236. \end_inset
  1237. blackspots
  1238. \begin_inset Quotes erd
  1239. \end_inset
  1240. to identify useful places
  1241. \begin_inset CommandInset citation
  1242. LatexCommand cite
  1243. key "Nurmi2006,Liao2007b"
  1244. \end_inset
  1245. .
  1246. With older GPS chipsets, the satellite signal would be lost when the user
  1247. entered a building, and this allowed an inference that the current location
  1248. was probably a place of interest.
  1249. However, modern GPS chipsets receive a signal in most indoor locations.
  1250. It is possible that a decrease in signal strength or number of locked satellite
  1251. s may still occur, or that GSM signal strength could be used instead, but
  1252. these ideas have not been widely explored at present.
  1253. \end_layout
  1254. \begin_layout Standard
  1255. There is, however, plenty of research relating to the use of location data
  1256. outdoors.
  1257. One application
  1258. \begin_inset CommandInset citation
  1259. LatexCommand cite
  1260. key "Liao2007b"
  1261. \end_inset
  1262. learns not only the user's frequently visited places, but the method of
  1263. transport used between them and the typical routes taken.
  1264. It can then offer instructions showing the user how to go from place to
  1265. place, or issue alerts if the user appears to be going the wrong way (by
  1266. getting on the wrong bus, for instance).
  1267. The ability to correctly infer the user's destination would be extremely
  1268. useful in a context-aware system: a user walking to do their grocery shopping
  1269. is almost certainly going to want to interact with their phone differently
  1270. than a user on a bus going to work.
  1271. \end_layout
  1272. \begin_layout Section
  1273. Bluetooth
  1274. \begin_inset CommandInset label
  1275. LatexCommand label
  1276. name "sec:Bluetooth"
  1277. \end_inset
  1278. \end_layout
  1279. \begin_layout Standard
  1280. The user's context depends on not only what they are doing, where they are
  1281. doing it, but also who they are with.
  1282. Sitting and eating lunch with a manager is quite a different context to
  1283. sitting and eating lunch with a spouse.
  1284. It would therefore be desirable to be able to identify between different
  1285. people when performing context analysis.
  1286. \end_layout
  1287. \begin_layout Standard
  1288. One of the few ways that a mobile telephone can identify other people is
  1289. by searching for
  1290. \emph on
  1291. their
  1292. \emph default
  1293. mobile telephones.
  1294. This can be done by scanning for Bluetooth devices, which involves broadcasting
  1295. a
  1296. \begin_inset Quotes eld
  1297. \end_inset
  1298. device inquiry
  1299. \begin_inset Quotes erd
  1300. \end_inset
  1301. message; if a device chooses to answer the inquiry, it discloses its unique
  1302. MAC address and device class
  1303. \begin_inset Foot
  1304. status collapsed
  1305. \begin_layout Plain Layout
  1306. the device class tells us whether the device is a computer or a mobile telephone
  1307. , for example
  1308. \end_layout
  1309. \end_inset
  1310. .
  1311. Unfortunately, this requires the person to not only be carrying a mobile
  1312. telephone, but a Bluetooth-enabled model, and for them to have configured
  1313. their device to have Bluetooth enabled and to be
  1314. \begin_inset Quotes eld
  1315. \end_inset
  1316. visible
  1317. \begin_inset Quotes erd
  1318. \end_inset
  1319. .
  1320. A study in 2004
  1321. \begin_inset CommandInset citation
  1322. LatexCommand cite
  1323. key "Eagle2004"
  1324. \end_inset
  1325. found that only 1 in 150 people had such a configured device on a university
  1326. campus.
  1327. This figure will undoubtedly be greater now, and may well be greater when
  1328. in public, but it highlights that only a handful of people may be detectable
  1329. via their Bluetooth devices.
  1330. \end_layout
  1331. \begin_layout Standard
  1332. A study in 2006
  1333. \begin_inset CommandInset citation
  1334. LatexCommand cite
  1335. key "Nicolai2006"
  1336. \end_inset
  1337. used a similar technique to monitor the social context of the user, introducing
  1338. the idea of
  1339. \begin_inset Quotes eld
  1340. \end_inset
  1341. familiar
  1342. \begin_inset Quotes erd
  1343. \end_inset
  1344. people,
  1345. \begin_inset Quotes eld
  1346. \end_inset
  1347. unfamiliar
  1348. \begin_inset Quotes erd
  1349. \end_inset
  1350. people and
  1351. \begin_inset Quotes eld
  1352. \end_inset
  1353. familiar strangers
  1354. \begin_inset Quotes erd
  1355. \end_inset
  1356. .
  1357. These labels were applied based on the number of times their Bluetooth
  1358. devices were detected
  1359. \begin_inset Foot
  1360. status collapsed
  1361. \begin_layout Plain Layout
  1362. and by extension the number of times the user had come into contact with
  1363. them
  1364. \end_layout
  1365. \end_inset
  1366. .
  1367. While the definition of
  1368. \begin_inset Quotes eld
  1369. \end_inset
  1370. familiar
  1371. \begin_inset Quotes erd
  1372. \end_inset
  1373. and
  1374. \begin_inset Quotes eld
  1375. \end_inset
  1376. unfamiliar
  1377. \begin_inset Quotes erd
  1378. \end_inset
  1379. are quite obvious,
  1380. \begin_inset Quotes eld
  1381. \end_inset
  1382. familiar strangers
  1383. \begin_inset Quotes erd
  1384. \end_inset
  1385. is a new class of people used to describe those who the user encounters
  1386. repeatedly, but doesn't interact with.
  1387. This may include neighbours that are passed on the street, or fellow commuters
  1388. on a journey into work.
  1389. The number of people in each of those groups (and any changes in those
  1390. numbers) can be used to infer how
  1391. \begin_inset Quotes eld
  1392. \end_inset
  1393. comfortable
  1394. \begin_inset Quotes erd
  1395. \end_inset
  1396. the user feels with their social context, and whether their current activity
  1397. is part of a normal routine or is novel.
  1398. \end_layout
  1399. \begin_layout Standard
  1400. This research has, to date, not been readily combined with activity-aware
  1401. applications, and this project will aim to integrate the results of Bluetooth
  1402. scanning with
  1403. \begin_inset Quotes eld
  1404. \end_inset
  1405. classical
  1406. \begin_inset Quotes erd
  1407. \end_inset
  1408. activity classification techniques and to evaluate whether it provides
  1409. any benefit.
  1410. \end_layout
  1411. \begin_layout Section
  1412. Power management
  1413. \begin_inset CommandInset label
  1414. LatexCommand label
  1415. name "sec:Power-management"
  1416. \end_inset
  1417. \end_layout
  1418. \begin_layout Standard
  1419. One major consideration when deploying an application on a mobile device
  1420. is the amount of power it will use.
  1421. An application constantly polling any one sensor can reduce battery life
  1422. significantly, and an application which kept all available sensors active
  1423. (in addition to doing CPU-heavy analysis on them) would drain the battery
  1424. in a typical smartphone in a matter of hours.
  1425. A context-aware application is not very useful for a user if they can only
  1426. use their telephone for an hour or two before it needs recharging!
  1427. \end_layout
  1428. \begin_layout Standard
  1429. One solution
  1430. \begin_inset CommandInset citation
  1431. LatexCommand cite
  1432. key "Wang2009"
  1433. \end_inset
  1434. is to only use one or two sensors to monitor the user's activity until it
  1435. appears to be transitioning.
  1436. For example, if the user is believed to be walking, the application only
  1437. needs to periodically check either the accelerometer (to confirm the user
  1438. is still making walking motions) or GPS (to confirm the distance traveled
  1439. is still consistent with walking) to know that their activity has not changed.
  1440. As soon as the user's behaviour becomes inconsistent with walking, the
  1441. application can bring other sensors online until it has successfully reclassifi
  1442. ed the activity, and then resume monitoring with minimal sensors.
  1443. \end_layout
  1444. \begin_layout Standard
  1445. Another option
  1446. \begin_inset CommandInset citation
  1447. LatexCommand cite
  1448. key "Wang2009"
  1449. \end_inset
  1450. (which can be used in conjunction) is to only enable sensors for a short
  1451. amount of time, and then sleep for a period before reactivating them.
  1452. The
  1453. \begin_inset Quotes eld
  1454. \end_inset
  1455. duty cycle
  1456. \begin_inset Quotes erd
  1457. \end_inset
  1458. suggested for accelerometers is 6 second of sensing followed by 10 seconds
  1459. of sleeping.
  1460. The six second window is enough time to allow for capturing a full range
  1461. of motion (several complete strides) if the user is walking or running,
  1462. and then the ten second sleep stops the accelerometer using battery power
  1463. until the next cycle.
  1464. This process obviously means that a sudden switch in activity will not
  1465. be noticed immediately, but a delay of a few seconds is acceptable as most
  1466. activities will last for minutes or longer.
  1467. \end_layout
  1468. \begin_layout Standard
  1469. The battery life on modern smartphones rarely exceeds 24 hours of typical
  1470. use, so it is extremely important that any applications developed for this
  1471. project does not significantly reduce this.
  1472. A balance between prompt detection and notification of activity changes
  1473. and battery use by sensors and processing algorithms will need to be found.
  1474. \end_layout
  1475. \begin_layout Standard
  1476. \begin_inset Newpage pagebreak
  1477. \end_inset
  1478. \end_layout
  1479. \begin_layout Part
  1480. \begin_inset CommandInset label
  1481. LatexCommand label
  1482. name "par:Activity-classification"
  1483. \end_inset
  1484. Activity classification
  1485. \end_layout
  1486. \begin_layout Section
  1487. Sensor Logger application
  1488. \end_layout
  1489. \begin_layout Standard
  1490. The primary component of context that this project aims to expose is the
  1491. user's activity.
  1492. The main factor in determining a user's activity is the data retrieved
  1493. from the device's accelerometers.
  1494. This gave rise to the project's first published application, titled
  1495. \noun on
  1496. Sensor Logger
  1497. \noun default
  1498. .
  1499. The first version of
  1500. \noun on
  1501. Sensor Logger
  1502. \noun default
  1503. consisted of a single activity containing a large amount of text describing
  1504. the project, an editable text field where the user could name their activity,
  1505. and a button which initiated logging.
  1506. \end_layout
  1507. \begin_layout Standard
  1508. \begin_inset Float figure
  1509. wide false
  1510. sideways false
  1511. status collapsed
  1512. \begin_layout Plain Layout
  1513. \begin_inset Graphics
  1514. filename components.png
  1515. width 60page%
  1516. \end_inset
  1517. \end_layout
  1518. \begin_layout Plain Layout
  1519. \begin_inset Caption
  1520. \begin_layout Plain Layout
  1521. Sensor Logger component diagram
  1522. \begin_inset CommandInset label
  1523. LatexCommand label
  1524. name "fig:Sensor-Logger-component"
  1525. \end_inset
  1526. \end_layout
  1527. \end_inset
  1528. \end_layout
  1529. \end_inset
  1530. Once the user tapped the 'Start' button, the application launched a service
  1531. which registered with the device's SensorManager and requested fast updates
  1532. from both the accelerometer and the magnetic field sensor.
  1533. Every 50ms the last value received from each axis on each sensor was written
  1534. along with a timestamp to a file on the device.
  1535. After 1024 samples were collected (a total of around 51 seconds), the service
  1536. launched an uploader service and terminated itself.
  1537. The uploader service read the file from the device's flash memory, opened
  1538. a HTTP connection to the project website, and submitted the data to a PHP
  1539. script.
  1540. The PHP script in turn stored the data in a MySQL database.
  1541. \begin_inset CommandInset ref
  1542. LatexCommand prettyref
  1543. reference "fig:Sensor-Logger-component"
  1544. \end_inset
  1545. shows the relationship between the various components involved in the Sensor
  1546. Logger application.
  1547. \end_layout
  1548. \begin_layout Subsection
  1549. Market and user input
  1550. \begin_inset CommandInset label
  1551. LatexCommand label
  1552. name "sub:Market-and-user"
  1553. \end_inset
  1554. \end_layout
  1555. \begin_layout Standard
  1556. The Sensor Logger application was made available on the Android Market,
  1557. under the name 'Sensor Logger Test'.
  1558. The description briefly outlined the aim of the project and emphasised
  1559. that the Sensor Logger was a data gathering tool and didn't really provide
  1560. any utility to end users.
  1561. Despite this, over 1,000 submissions were received from anonymous users.
  1562. While some of these did not provide any use for the reasons discussed in
  1563. \begin_inset CommandInset ref
  1564. LatexCommand prettyref
  1565. reference "sec:Manual-classification"
  1566. \end_inset
  1567. , a number were manually classified and used to generate the model used
  1568. in the final application.
  1569. \end_layout
  1570. \begin_layout Standard
  1571. \begin_inset Float figure
  1572. wide false
  1573. sideways false
  1574. status open
  1575. \begin_layout Plain Layout
  1576. \begin_inset Graphics
  1577. filename analysis_of_user-submitted_sensor_logger_data_sets.png
  1578. width 60page%
  1579. \end_inset
  1580. \end_layout
  1581. \begin_layout Plain Layout
  1582. \begin_inset Caption
  1583. \begin_layout Plain Layout
  1584. Analysis of user-submitted Sensor Logger results
  1585. \begin_inset CommandInset label
  1586. LatexCommand label
  1587. name "fig:Analysis-of-user-submitted"
  1588. \end_inset
  1589. \end_layout
  1590. \end_inset
  1591. \end_layout
  1592. \begin_layout Plain Layout
  1593. \end_layout
  1594. \end_inset
  1595. Version 0.2.0 of the Sensor Logger application introduced functionality where
  1596. it classified the activity on the device before asking the user to name
  1597. it (see
  1598. \begin_inset CommandInset ref
  1599. LatexCommand prettyref
  1600. reference "sec:On-device-classification"
  1601. \end_inset
  1602. ).
  1603. This allowed the submitted data to be augmented with an extra field saying
  1604. what the activity classification algorithm thought the activity was.
  1605. If the user confirmed that the activity was correct, the manual activity
  1606. annotation was set to 'UNCLASSIFIED/NOTCORRECTED'.
  1607. \end_layout
  1608. \begin_layout Standard
  1609. \begin_inset CommandInset ref
  1610. LatexCommand prettyref
  1611. reference "fig:Analysis-of-user-submitted"
  1612. \end_inset
  1613. shows a breakdown of all the results that were received from version 0.2.0
  1614. or later of the application.
  1615. The raw data is included in
  1616. \begin_inset CommandInset ref
  1617. LatexCommand prettyref
  1618. reference "sec:User-annotated-Sensor-Logger"
  1619. \end_inset
  1620. .
  1621. Nearly half of all the submissions were classified correctly, and only
  1622. 15% were classified incorrectly.
  1623. A large proportion of the submissions either had no text at all or had
  1624. an activity that didn't make sense, such as
  1625. \begin_inset Quotes eld
  1626. \end_inset
  1627. sjxjxgzog
  1628. \begin_inset Quotes erd
  1629. \end_inset
  1630. or
  1631. \begin_inset Quotes eld
  1632. \end_inset
  1633. it is a cat!
  1634. \begin_inset Quotes erd
  1635. \end_inset
  1636. .
  1637. There were also 30 submissions where the user had annotated the data with
  1638. an activity that makes sense, but which isn't supported by the Sensor Logger.
  1639. The majority of these were 'Sleeping' - but it is unclear in these circumstance
  1640. s what the user is actually doing with their device; if it is left on a
  1641. bedside table, for example, then there is no way to distinguish the actual
  1642. activity of the user.
  1643. \end_layout
  1644. \begin_layout Standard
  1645. \begin_inset Float figure
  1646. wide false
  1647. sideways false
  1648. status open
  1649. \begin_layout Plain Layout
  1650. \begin_inset Graphics
  1651. filename breakdown_of_incorrect_results.png
  1652. width 60page%
  1653. \end_inset
  1654. \end_layout
  1655. \begin_layout Plain Layout
  1656. \begin_inset Caption
  1657. \begin_layout Plain Layout
  1658. Breakdown of incorrect results
  1659. \begin_inset CommandInset label
  1660. LatexCommand label
  1661. name "fig:Breakdown-of-incorrect"
  1662. \end_inset
  1663. \end_layout
  1664. \end_inset
  1665. \end_layout
  1666. \begin_layout Plain Layout
  1667. \end_layout
  1668. \end_inset
  1669. \begin_inset CommandInset ref
  1670. LatexCommand prettyref
  1671. reference "fig:Breakdown-of-incorrect"
  1672. \end_inset
  1673. shows a breakdown of the results deemed incorrect.
  1674. A large majority of these incorrect results occurred when the user was
  1675. sitting down, and the Sensor Logger incorrectly classified them as being
  1676. in a vehicle of some sort.
  1677. Of the remaining incorrect entries, 15% correctly classified the correct
  1678. top level in the hierarchy (such as 'VEHICLE' or 'WALKING') but then misclassif
  1679. ied further levels; the remaining 25% incorrectly classified this top level
  1680. as well.
  1681. \end_layout
  1682. \begin_layout Subsection
  1683. Exception handling
  1684. \end_layout
  1685. \begin_layout Standard
  1686. Early user feedback on the Android Market indicated that the Sensor Logger
  1687. application was
  1688. \begin_inset Quotes eld
  1689. \end_inset
  1690. Force Closing
  1691. \begin_inset Quotes erd
  1692. \end_inset
  1693. .
  1694. This is a reference to the dialog that appears when an application throws
  1695. an unhandled exception and stops running.
  1696. The Market provides no facilities to engage with users, and there were
  1697. no force close issues present on either the Android emulator or several
  1698. physical devices the application was tested on, so it was difficult to
  1699. determine the cause.
  1700. \end_layout
  1701. \begin_layout Standard
  1702. In order to gain more data on this issue, an
  1703. \noun on
  1704. UncaughtExceptionHandler
  1705. \noun default
  1706. was written and appropriately registered with the application's thread.
  1707. The exception handler is invoked by the
  1708. \noun on
  1709. Thread
  1710. \noun default
  1711. class any time a thread dies due to an unhandled exception.
  1712. The implementation for the Sensor Logger application copied the details
  1713. of any exception (including the reason and full stack trace) into a file,
  1714. and then uploaded the file with some meta-data to the same website which
  1715. was setup to handle uploading of accelerometer data.
  1716. \end_layout
  1717. \begin_layout Standard
  1718. Soon after an updated version of the Sensor Logger was published including
  1719. the new exception handler a report was uploaded.
  1720. The stack trace indicated that the problem was a
  1721. \noun on
  1722. NumberFormatException
  1723. \noun default
  1724. when trying to convert the device's IMEI number into a
  1725. \noun on
  1726. long
  1727. \noun default
  1728. .
  1729. After some brief research it became apparent that CDMA devices do not use
  1730. IMEI numbers, but instead MEIDs (Mobile Equipment Identifier).
  1731. MEIDs are hexadecimal instead of numerical, so obviously cannot be converted
  1732. directly to a numeric type.
  1733. The code was adjusted to decode MEIDs properly and a new version of the
  1734. application published, and the error reports ceased.
  1735. \end_layout
  1736. \begin_layout Standard
  1737. From a development perspective, the utility of being notified directly of
  1738. exceptions is immense.
  1739. It is very difficult for users to find the details of an exception following
  1740. a force close, so extremely unlikely that anyone will report problems in
  1741. sufficient detail for them to be fixed.
  1742. The exception handling code was therefore abstracted into a common class,
  1743. and included in every application released as part of this project.
  1744. \end_layout
  1745. \begin_layout Section
  1746. Manual classification
  1747. \begin_inset CommandInset label
  1748. LatexCommand label
  1749. name "sec:Manual-classification"
  1750. \end_inset
  1751. \end_layout
  1752. \begin_layout Standard
  1753. \begin_inset Float figure
  1754. wide false
  1755. sideways false
  1756. status collapsed
  1757. \begin_layout Plain Layout
  1758. \begin_inset Graphics
  1759. filename website-windows.png
  1760. height 70pheight%
  1761. rotateAngle 90
  1762. \end_inset
  1763. \end_layout
  1764. \begin_layout Plain Layout
  1765. \begin_inset Caption
  1766. \begin_layout Plain Layout
  1767. Website for manually classifying windows
  1768. \begin_inset CommandInset label
  1769. LatexCommand label
  1770. name "fig:Website-for-manually"
  1771. \end_inset
  1772. \end_layout
  1773. \end_inset
  1774. \end_layout
  1775. \begin_layout Plain Layout
  1776. \end_layout
  1777. \end_inset
  1778. Once the sensor data was logged in the database, a web interface provided
  1779. a graphical representation of the acceleration and magnetic field readings.
  1780. It also allowed a handful of authenticated users to manually classify overlappi
  1781. ng
  1782. \begin_inset Quotes eld
  1783. \end_inset
  1784. windows
  1785. \begin_inset Quotes erd
  1786. \end_inset
  1787. of 128 data points.
  1788. The classification portion of the website is shown in
  1789. \begin_inset CommandInset ref
  1790. LatexCommand prettyref
  1791. reference "fig:Website-for-manually"
  1792. \end_inset
  1793. ; it shows the first six overlapping windows for one submission, with the
  1794. third window highlighted because the user's cursor is over the corresponding
  1795. dropdown.
  1796. Users of this system could define activities in a hierarchical fashion,
  1797. starting with two root nodes - 'CLASSIFIED' and 'UNCLASSIFIED'.
  1798. Early data submitted resulted in a classification hierarchy of:
  1799. \end_layout
  1800. \begin_layout Itemize
  1801. UNCLASSIFIED
  1802. \end_layout
  1803. \begin_deeper
  1804. \begin_layout Itemize
  1805. PENDING (not yet manually assigned)
  1806. \end_layout
  1807. \begin_layout Itemize
  1808. UNKNOWN (unable to determine actual activity from user label)
  1809. \end_layout
  1810. \begin_layout Itemize
  1811. DNI (short for
  1812. \begin_inset Quotes eld
  1813. \end_inset
  1814. Do Not Include
  1815. \begin_inset Quotes erd
  1816. \end_inset
  1817. , for windows which appear erroneous)
  1818. \end_layout
  1819. \end_deeper
  1820. \begin_layout Itemize
  1821. CLASSIFIED
  1822. \end_layout
  1823. \begin_deeper
  1824. \begin_layout Itemize
  1825. WALKING
  1826. \end_layout
  1827. \begin_deeper
  1828. \begin_layout Itemize
  1829. STAIRS (not used in itself)
  1830. \end_layout
  1831. \begin_deeper
  1832. \begin_layout Itemize
  1833. UP
  1834. \end_layout
  1835. \begin_layout Itemize
  1836. DOWN
  1837. \end_layout
  1838. \end_deeper
  1839. \end_deeper
  1840. \begin_layout Itemize
  1841. IDLE (not used in itself)
  1842. \end_layout
  1843. \begin_deeper
  1844. \begin_layout Itemize
  1845. SITTING
  1846. \end_layout
  1847. \begin_layout Itemize
  1848. STANDING
  1849. \end_layout
  1850. \end_deeper
  1851. \begin_layout Itemize
  1852. VEHICLE (not used in itself)
  1853. \end_layout
  1854. \begin_deeper
  1855. \begin_layout Itemize
  1856. CAR
  1857. \end_layout
  1858. \begin_layout Itemize
  1859. BUS
  1860. \end_layout
  1861. \end_deeper
  1862. \begin_layout Itemize
  1863. DANCING
  1864. \end_layout
  1865. \end_deeper
  1866. \begin_layout Standard
  1867. It was observed that many samples had erroneous data either at the start
  1868. or the end of the recording.
  1869. This was a result of the user putting the device away in a pocket (as instructe
  1870. d) or picking it back up to check the results.
  1871. A classification of 'DNI', short for 'Do Not Include' was therefore introduced
  1872. which allowed the erroneous windows to be summarily excluded from later
  1873. analysis.
  1874. Later iterations of the Sensor Logger application included a 10 second
  1875. delay at the start to give the user time to put the device away, and sounded
  1876. an audible alert at the end, which reduced the number of records submitted
  1877. with bad data.
  1878. \end_layout
  1879. \begin_layout Standard
  1880. Another problem with the user submitted data was that some activity descriptions
  1881. didn't make sense.
  1882. With the earliest versions of the Sensor Logger, a significant number of
  1883. users entered their own name or a nonsensical string into the textbox labeled
  1884. \begin_inset Quotes eld
  1885. \end_inset
  1886. Activity name
  1887. \begin_inset Quotes erd
  1888. \end_inset
  1889. .
  1890. This suggested that users were either not reading or misunderstanding the
  1891. instructions.
  1892. A classification for 'UNKNOWN' was introduced to facilitate removal of
  1893. the records where classifications couldn't be inferred from the activity
  1894. name.
  1895. \end_layout
  1896. \begin_layout Section
  1897. Feature extraction
  1898. \end_layout
  1899. \begin_layout Standard
  1900. Once a reasonable sample of data had been recorded, the PHP script was modified
  1901. to allow exporting of all classified windows.
  1902. It produced a plain text file containing the sensor readings and timestamp
  1903. for each of the 128 points in each window, as well as the manually-applied
  1904. classification.
  1905. It did not include information as to which windows were from the same sample,
  1906. or the original user-supplied activity name.
  1907. A small sample of this data is included in Appendix
  1908. \begin_inset CommandInset ref
  1909. LatexCommand prettyref
  1910. reference "sec:Extract-from-export"
  1911. \end_inset
  1912. .
  1913. \end_layout
  1914. \begin_layout Standard
  1915. A Java program was written which imported the exported data.
  1916. A series of 'feature extractors' were written.
  1917. These calculated the:
  1918. \end_layout
  1919. \begin_layout Itemize
  1920. maximum
  1921. \end_layout
  1922. \begin_layout Itemize
  1923. minimum
  1924. \end_layout
  1925. \begin_layout Itemize
  1926. range
  1927. \end_layout
  1928. \begin_layout Itemize
  1929. median
  1930. \end_layout
  1931. \begin_layout Itemize
  1932. mean
  1933. \end_layout
  1934. \begin_layout Standard
  1935. Each of these extractors was run over the set of 128 data points from each
  1936. axis on each sensor, giving a total of 30 features.
  1937. It was planned to add further features including Fast Fourier Transforms
  1938. and energy, as suggested by multiple papers consulted in background research.
  1939. \end_layout
  1940. \begin_layout Standard
  1941. The program was modified to export the features and classification of each
  1942. window in ARFF
  1943. \begin_inset Note Note
  1944. status open
  1945. \begin_layout Plain Layout
  1946. ref
  1947. \end_layout
  1948. \end_inset
  1949. (Attribute Relation File Format).
  1950. This is a format used by Weka
  1951. \begin_inset Note Note
  1952. status open
  1953. \begin_layout Plain Layout
  1954. ref
  1955. \end_layout
  1956. \end_inset
  1957. , a popular data mining suite developed by the University of Waikato.
  1958. A small sample of the ARFF data is included in Appendix
  1959. \begin_inset CommandInset ref
  1960. LatexCommand prettyref
  1961. reference "sec:Extract-from-ARFF"
  1962. \end_inset
  1963. .
  1964. The ARFF file was imported into Weka and analysed.
  1965. \end_layout
  1966. \begin_layout Standard
  1967. Inspection of a graphical representation of the correlation between mean
  1968. and activity showed that in some samples the mean was negated but of a
  1969. similar magnitude to other samples.
  1970. This can be explained by the device being orientated in a different manner
  1971. when the samples were taken - a static device would record a downwards
  1972. acceleration of 9.8m/s if it is upright, but -9.8m/s if it is upside down.
  1973. An extra feature extractor was therefore added which calculated the
  1974. \emph on
  1975. absolute mean
  1976. \emph default
  1977. .
  1978. \end_layout
  1979. \begin_layout Standard
  1980. With these features, it was found that Weka could correctly classify activities
  1981. with an accuracy of in excess of 95% (measured by holding back
  1982. \begin_inset Formula $\frac{1}{3}$
  1983. \end_inset
  1984. of the training data) using a K-Nearest Network algorithm with K = 1.
  1985. It was therefore apparent that more complicated feature extraction techniques
  1986. such as Fast Fourier Transforms or Energy would not be necessary to achieve
  1987. a very high classification rate.
  1988. \end_layout
  1989. \begin_layout Standard
  1990. A lot of time was spent attempting to reduce the already small set of features
  1991. further.
  1992. Every feature that had to be calculated would result in more CPU usage
  1993. when implemented on the device, which would in turn reduce battery life
  1994. by a greater amount.
  1995. This was done by a combination of experimentation based on educated guesses
  1996. and assumption, and Weka's built in
  1997. \begin_inset Quotes eld
  1998. \end_inset
  1999. select attributes
  2000. \begin_inset Quotes erd
  2001. \end_inset
  2002. functionality.
  2003. \end_layout
  2004. \begin_layout Standard
  2005. In the end, a similar accuracy was achieved using only four features.
  2006. These were the absolute mean and range of the X and Y axes of the accelerometer.
  2007. No data at all was used from the magnetic field sensor or the Z axis of
  2008. the accelerometer.
  2009. This is an very useful result as the features are extremely cheap to calculate,
  2010. and almost trivial to implement on the device.
  2011. No libraries are needed to perform advanced mathematical functions, and
  2012. individual samples do not need to be stored in memory until a complete
  2013. window is obtained - the minimum, maximum and total of samples from the
  2014. two axes simply have to be recorded.
  2015. This is, perhaps, the first time activity inference has been performed
  2016. successfully with such a small number of features.
  2017. \end_layout
  2018. \begin_layout Standard
  2019. The application was again modified to read the exported data, calculate
  2020. the four interesting features, and create a mapping of data points to activity.
  2021. This map was serialised into a file using an
  2022. \noun on
  2023. ObjectWriter
  2024. \noun default
  2025. , which allows it to be read on both desktop platforms running a standard
  2026. JVM, and the Android platform which contains compatible serialisation technolog
  2027. y.
  2028. \end_layout
  2029. \begin_layout Section
  2030. On-device classification
  2031. \begin_inset CommandInset label
  2032. LatexCommand label
  2033. name "sec:On-device-classification"
  2034. \end_inset
  2035. \end_layout
  2036. \begin_layout Standard
  2037. The serialised model was bundled with a new version of the Sensor Logger
  2038. application, along with a completely redesigned user interface.
  2039. The application now consisted of a series of activities: on opening the
  2040. application, the user is presented with an introduction activity which
  2041. explains what the application does and the aims of the project; when they
  2042. click the 'next' button a 10 second countdown is displayed with the instruction
  2043. to put the phone away repeated.
  2044. During the data collection period an animated pattern of dots is displayed
  2045. so the user knows the application is still working if they look at it.
  2046. When data collection is completed, the device adds a notification with
  2047. sound and vibrate settings, and displays another progress screen while
  2048. a background service analyses the data.
  2049. The result of the classification is then displayed prominently and the
  2050. user is presented with two buttons - one to confirm the classification
  2051. and one to reject and correct it.
  2052. The on-device classification (and any correction made to it) is submitted
  2053. along with all the data previously submitted.
  2054. Finally, the user is then presented with a 'Thank you' message, and a unique
  2055. link to the project website where they can view graphs of their activities.
  2056. \begin_inset Note Note
  2057. status open
  2058. \begin_layout Plain Layout
  2059. Mess!
  2060. \end_layout
  2061. \end_inset
  2062. \end_layout
  2063. \begin_layout Section
  2064. Activity Recorder application
  2065. \end_layout
  2066. \begin_layout Standard
  2067. \begin_inset Note Note
  2068. status open
  2069. \begin_layout Plain Layout
  2070. Screenshot
  2071. \end_layout
  2072. \end_inset
  2073. \end_layout
  2074. \begin_layout Standard
  2075. The Activity Recorder application was the second application published on
  2076. the market.
  2077. In contrast to the sensor logger, it only records the two relevant axes
  2078. of the accelerometer, and all data is kept in memory instead of being written
  2079. to a file.
  2080. \end_layout
  2081. \begin_layout Standard
  2082. The activity recorder consists of a background service which records 128
  2083. samples of sensor data once every 30 seconds.
  2084. At all other times, the accelerometer is not accessed to conserve battery
  2085. power.
  2086. The samples are then classified using the same model as the Sensor Logger
  2087. application, and the resulting activity is appended to a list.
  2088. Consecutive samples which are classified as the same activity are merged
  2089. together.
  2090. \end_layout
  2091. \begin_layout Standard
  2092. The user interface displays a list of activities, along with their start
  2093. time and duration in minutes or hours.
  2094. \end_layout
  2095. \begin_layout Subsection
  2096. Acquiring data while screen is off
  2097. \begin_inset CommandInset label
  2098. LatexCommand label
  2099. name "sub:Acquiring-data-while"
  2100. \end_inset
  2101. \end_layout
  2102. \begin_layout Standard
  2103. The activity recorder brought to light a problem that was discovered to
  2104. be present in the sensor logger as we, but hadn't been noticed at the time.
  2105. When the device's screen was turned off, both applications stopped receiving
  2106. sensor events.
  2107. Some research and experimentation revealed that in order to continue receiving
  2108. sensor data when the device went to
  2109. \begin_inset Quotes eld
  2110. \end_inset
  2111. sleep
  2112. \begin_inset Quotes erd
  2113. \end_inset
  2114. , the application had to acquire a partial wake lock from the system's power
  2115. manager.
  2116. A full wake lock keeps the device fully awake with the screen on, whereas
  2117. a partial wake lock allows background processing to continue while the
  2118. screen is deactivated.
  2119. \end_layout
  2120. \begin_layout Standard
  2121. Once the applications were modified to acquire a partial wake lock, they
  2122. both received sensor data as expected with the screen off.
  2123. However, testing on Android 2.0 (
  2124. \begin_inset Quotes eld
  2125. \end_inset
  2126. Eclair
  2127. \begin_inset Quotes erd
  2128. \end_inset
  2129. ) devices still showed the original problem.
  2130. The cause of this was a change in the functionality of the sensor manager
  2131. introduced between 1.6 and 2.0 which prevents sensor data being received
  2132. when the device is sleeping, regardless of any wake locks held.
  2133. An issue raised on their official issue tracker revealed that the Android
  2134. developers considered this a bug, and that it would be rectified in a future
  2135. version.
  2136. When Android 2.2 (
  2137. \begin_inset Quotes eld
  2138. \end_inset
  2139. Froyo
  2140. \begin_inset Quotes erd
  2141. \end_inset
  2142. ) was released, testing revealed that the issue was indeed fixed, and all
  2143. applications worked as expected.
  2144. There therefore exists an incompatibility with handsets running Android
  2145. 2.0 and 2.1.
  2146. \end_layout
  2147. \begin_layout Subsection
  2148. Aggregating classifications to smooth results
  2149. \begin_inset CommandInset label
  2150. LatexCommand label
  2151. name "sub:Aggregating-classifications-to"
  2152. \end_inset
  2153. \end_layout
  2154. \begin_layout Standard
  2155. Another problem raised by the Activity Recorder application is that of occasiona
  2156. l incorrect results.
  2157. Because each data was only sampled for five seconds once a minute, it is
  2158. possible that during those five seconds the activity being performed does
  2159. not lend itself to proper classification of the user's actual, medium-term
  2160. activity.
  2161. For example, if a user is walking for 20 minutes and happens to stop several
  2162. times to cross roads, samples while the user is stopped will (correctly)
  2163. indicate that they are standing still, but for all practical purposes they
  2164. are still engaged in the act of walking.
  2165. Similarly, when traveling in a car it is possible for occasional samples
  2166. to be misclassified as traveling by bus, or vice-versa.
  2167. \end_layout
  2168. \begin_layout Standard
  2169. To combat this problem, an activity
  2170. \begin_inset Quotes eld
  2171. \end_inset
  2172. aggregator
  2173. \begin_inset Quotes erd
  2174. \end_inset
  2175. was introduced.
  2176. This accepts classifications and uses them to adjust a set of internal
  2177. probabilities for each possible (sub-)classification.
  2178. The algorithm increases the likelihood score of each component in a classificat
  2179. ion by a constant amount, and reduces all other components by a fixed ratio.
  2180. This smooths out results, and allows for classifications not directly supported
  2181. by the model when the data is unclear and alternating.
  2182. This behaviour is most useful when traveling by vehicle and classifications
  2183. alter between
  2184. \begin_inset Quotes eld
  2185. \end_inset
  2186. car
  2187. \begin_inset Quotes erd
  2188. \end_inset
  2189. and
  2190. \begin_inset Quotes eld
  2191. \end_inset
  2192. bus
  2193. \begin_inset Quotes erd
  2194. \end_inset
  2195. - both contributed positively to the likelihood of
  2196. \begin_inset Quotes eld
  2197. \end_inset
  2198. CLASSIFIED/VEHICLE
  2199. \begin_inset Quotes erd
  2200. \end_inset
  2201. , and this ends up being the result presented by the aggregator.
  2202. \end_layout
  2203. \begin_layout Standard
  2204. \begin_inset Newpage pagebreak
  2205. \end_inset
  2206. \end_layout
  2207. \begin_layout Part
  2208. \begin_inset CommandInset label
  2209. LatexCommand label
  2210. name "par:Other-sensors"
  2211. \end_inset
  2212. Other sensors
  2213. \end_layout
  2214. \begin_layout Section
  2215. Bluetooth
  2216. \begin_inset CommandInset label
  2217. LatexCommand label
  2218. name "sec:Bluetooth-1"
  2219. \end_inset
  2220. \end_layout
  2221. \begin_layout Standard
  2222. Being able to identify who the user is accompanied by would be extremely
  2223. beneficial in a context-aware system.
  2224. One of the few ways to do this at present is to monitor the presence of
  2225. other user's mobile telephones by scanning for visible Bluetooth devices.
  2226. As discussed in
  2227. \begin_inset CommandInset ref
  2228. LatexCommand prettyref
  2229. reference "sec:Bluetooth"
  2230. \end_inset
  2231. , if sufficient devices are visible, users can be classified according to
  2232. whether they are familiar, strangers, or familiar strangers.
  2233. This provides a great deal of context to the user's activity.
  2234. \end_layout
  2235. \begin_layout Standard
  2236. Before this Bluetooth algorithm can be implemented, it needs to be determined
  2237. whether there are a sufficient number of discoverable devices to make it
  2238. worthwhile.
  2239. As with any radio transceiver, a lot of battery power is consumed when
  2240. Bluetooth is enabled and the device is actively scanning for others.
  2241. This means that if there are insufficient discoverable devices, the cost
  2242. of enabling and scanning for Bluetooth devices would outweigh the benefits.
  2243. As mentioned previously, there is no use in a very accurate context API
  2244. if the user's battery only lasts for a few hours.
  2245. \end_layout
  2246. \begin_layout Standard
  2247. To determine the utility of scanning for Bluetooth devices, a group of three
  2248. volunteers were asked to manually enable Bluetooth and scan for devices
  2249. using the built in functionality exposed in Android's settings screens.
  2250. It was planned to create an application which could scan and classify devices
  2251. appropriately but the Bluetooth API is only exposed to user-space applications
  2252. in version 5 of the Android SDK, which corresponds to the
  2253. \begin_inset Quotes eld
  2254. \end_inset
  2255. Eclair
  2256. \begin_inset Quotes erd
  2257. \end_inset
  2258. or 2.0 release; at the time of the experiment, only one of the three volunteers
  2259. was using a device for which Eclair was available.
  2260. This also means that adding Bluetooth support would have a further cost
  2261. of having to either limit access to pre-2.0 users, maintain two separate
  2262. versions of the application, or spend extra time developing a solution
  2263. which would attempt to use the Bluetooth API if and only if it is available.
  2264. \end_layout
  2265. \begin_layout Standard
  2266. \begin_inset Float table
  2267. placement h
  2268. wide false
  2269. sideways false
  2270. status open
  2271. \begin_layout Plain Layout
  2272. \begin_inset Tabular
  2273. <lyxtabular version="3" rows="13" columns="7">
  2274. <features>
  2275. <column alignment="center" valignment="top" width="0">
  2276. <column alignment="center" valignment="top" width="0">
  2277. <column alignment="center" valignment="top" width="0">
  2278. <column alignment="center" valignment="top" width="0">
  2279. <column alignment="center" valignment="top" width="0">
  2280. <column alignment="center" valignment="top" width="0">
  2281. <column alignment="center" valignment="top" width="0">
  2282. <row>
  2283. <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
  2284. \begin_inset Text
  2285. \begin_layout Plain Layout
  2286. Environment
  2287. \end_layout
  2288. \end_inset
  2289. </cell>
  2290. <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
  2291. \begin_inset Text
  2292. \begin_layout Plain Layout
  2293. Devices
  2294. \end_layout
  2295. \end_inset
  2296. </cell>
  2297. <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
  2298. \begin_inset Text
  2299. \begin_layout Plain Layout
  2300. People
  2301. \end_layout
  2302. \end_inset
  2303. </cell>
  2304. <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
  2305. \begin_inset Text
  2306. \begin_layout Plain Layout
  2307. Discoverable
  2308. \end_layout
  2309. \end_inset
  2310. </cell>
  2311. <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
  2312. \begin_inset Text
  2313. \begin_layout Plain Layout
  2314. Familiar
  2315. \end_layout
  2316. \end_inset
  2317. </cell>
  2318. <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
  2319. \begin_inset Text
  2320. \begin_layout Plain Layout
  2321. Familiar Strangers
  2322. \end_layout
  2323. \end_inset
  2324. </cell>
  2325. <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
  2326. \begin_inset Text
  2327. \begin_layout Plain Layout
  2328. Strangers
  2329. \end_layout
  2330. \end_inset
  2331. </cell>
  2332. </row>
  2333. <row>
  2334. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  2335. \begin_inset Text
  2336. \begin_layout Plain Layout
  2337. Car
  2338. \end_layout
  2339. \end_inset
  2340. </cell>
  2341. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  2342. \begin_inset Text
  2343. \begin_layout Plain Layout
  2344. 0
  2345. \end_layout
  2346. \end_inset
  2347. </cell>
  2348. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  2349. \begin_inset Text
  2350. \begin_layout Plain Layout
  2351. 1
  2352. \end_layout
  2353. \end_inset
  2354. </cell>
  2355. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  2356. \begin_inset Text
  2357. \begin_layout Plain Layout
  2358. 0%
  2359. \end_layout
  2360. \end_inset
  2361. </cell>
  2362. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  2363. \begin_inset Text
  2364. \begin_layout Plain Layout
  2365. 1
  2366. \end_layout
  2367. \end_inset
  2368. </cell>
  2369. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  2370. \begin_inset Text
  2371. \begin_layout Plain Layout
  2372. 0
  2373. \end_layout
  2374. \end_inset
  2375. </cell>
  2376. <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  2377. \begin_inset Text
  2378. \begin_layout Plain Layout
  2379. 0
  2380. \end_layout
  2381. \end_inset
  2382. </cell>
  2383. </row>
  2384. <row>
  2385. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  2386. \begin_inset Text
  2387. \begin_layout Plain Layout
  2388. Bus
  2389. \end_layout
  2390. \end_inset
  2391. </cell>
  2392. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  2393. \begin_inset Text
  2394. \begin_layout Plain Layout
  2395. 1
  2396. \end_layout
  2397. \end_inset
  2398. </cell>
  2399. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  2400. \begin_inset Text
  2401. \begin_layout Plain Layout
  2402. 20
  2403. \end_layout
  2404. \end_inset
  2405. </cell>
  2406. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  2407. \begin_inset Text
  2408. \begin_layout Plain Layout
  2409. 5%
  2410. \end_layout
  2411. \end_inset
  2412. </cell>
  2413. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  2414. \begin_inset Text
  2415. \begin_layout Plain Layout
  2416. 0
  2417. \end_layout
  2418. \end_inset
  2419. </cell>
  2420. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  2421. \begin_inset Text
  2422. \begin_layout Plain Layout
  2423. 0
  2424. \end_layout
  2425. \end_inset
  2426. </cell>
  2427. <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  2428. \begin_inset Text
  2429. \begin_layout Plain Layout
  2430. 20
  2431. \end_layout
  2432. \end_inset
  2433. </cell>
  2434. </row>
  2435. <row>
  2436. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  2437. \begin_inset Text
  2438. \begin_layout Plain Layout
  2439. Street
  2440. \end_layout
  2441. \end_inset
  2442. </cell>
  2443. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  2444. \begin_inset Text
  2445. \begin_layout Plain Layout
  2446. 2
  2447. \end_layout
  2448. \end_inset
  2449. </cell>
  2450. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  2451. \begin_inset Text
  2452. \begin_layout Plain Layout
  2453. 15
  2454. \end_layout
  2455. \end_inset
  2456. </cell>
  2457. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  2458. \begin_inset Text
  2459. \begin_layout Plain Layout
  2460. 13%
  2461. \end_layout
  2462. \end_inset
  2463. </cell>
  2464. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  2465. \begin_inset Text
  2466. \begin_layout Plain Layout
  2467. 0
  2468. \end_layout
  2469. \end_inset
  2470. </cell>
  2471. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  2472. \begin_inset Text
  2473. \begin_layout Plain Layout
  2474. 0
  2475. \end_layout
  2476. \end_inset
  2477. </cell>
  2478. <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  2479. \begin_inset Text
  2480. \begin_layout Plain Layout
  2481. 15
  2482. \end_layout
  2483. \end_inset
  2484. </cell>
  2485. </row>
  2486. <row>
  2487. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  2488. \begin_inset Text
  2489. \begin_layout Plain Layout
  2490. Bar
  2491. \end_layout
  2492. \end_inset
  2493. </cell>
  2494. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  2495. \begin_inset Text
  2496. \begin_layout Plain Layout
  2497. 2
  2498. \end_layout
  2499. \end_inset
  2500. </cell>
  2501. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  2502. \begin_inset Text
  2503. \begin_layout Plain Layout
  2504. 12
  2505. \end_layout
  2506. \end_inset
  2507. </cell>
  2508. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  2509. \begin_inset Text
  2510. \begin_layout Plain Layout
  2511. 17%
  2512. \end_layout
  2513. \end_inset
  2514. </cell>
  2515. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  2516. \begin_inset Text
  2517. \begin_layout Plain Layout
  2518. 1
  2519. \end_layout
  2520. \end_inset
  2521. </cell>
  2522. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  2523. \begin_inset Text
  2524. \begin_layout Plain Layout
  2525. 1
  2526. \end_layout
  2527. \end_inset
  2528. </cell>
  2529. <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  2530. \begin_inset Text
  2531. \begin_layout Plain Layout
  2532. 10
  2533. \end_layout
  2534. \end_inset
  2535. </cell>
  2536. </row>
  2537. <row>
  2538. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  2539. \begin_inset Text
  2540. \begin_layout Plain Layout
  2541. Office
  2542. \end_layout
  2543. \end_inset
  2544. </cell>
  2545. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  2546. \begin_inset Text
  2547. \begin_layout Plain Layout
  2548. 0
  2549. \end_layout
  2550. \end_inset
  2551. </cell>
  2552. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  2553. \begin_inset Text
  2554. \begin_layout Plain Layout
  2555. 6
  2556. \end_layout
  2557. \end_inset
  2558. </cell>
  2559. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  2560. \begin_inset Text
  2561. \begin_layout Plain Layout
  2562. 0%
  2563. \end_layout
  2564. \end_inset
  2565. </cell>
  2566. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  2567. \begin_inset Text
  2568. \begin_layout Plain Layout
  2569. 5
  2570. \end_layout
  2571. \end_inset
  2572. </cell>
  2573. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  2574. \begin_inset Text
  2575. \begin_layout Plain Layout
  2576. 1
  2577. \end_layout
  2578. \end_inset
  2579. </cell>
  2580. <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  2581. \begin_inset Text
  2582. \begin_layout Plain Layout
  2583. 0
  2584. \end_layout
  2585. \end_inset
  2586. </cell>
  2587. </row>
  2588. <row>
  2589. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  2590. \begin_inset Text
  2591. \begin_layout Plain Layout
  2592. Office
  2593. \end_layout
  2594. \end_inset
  2595. </cell>
  2596. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  2597. \begin_inset Text
  2598. \begin_layout Plain Layout
  2599. 0
  2600. \end_layout
  2601. \end_inset
  2602. </cell>
  2603. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  2604. \begin_inset Text
  2605. \begin_layout Plain Layout
  2606. 4
  2607. \end_layout
  2608. \end_inset
  2609. </cell>
  2610. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  2611. \begin_inset Text
  2612. \begin_layout Plain Layout
  2613. 0%
  2614. \end_layout
  2615. \end_inset
  2616. </cell>
  2617. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  2618. \begin_inset Text
  2619. \begin_layout Plain Layout
  2620. 4
  2621. \end_layout
  2622. \end_inset
  2623. </cell>
  2624. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  2625. \begin_inset Text
  2626. \begin_layout Plain Layout
  2627. 0
  2628. \end_layout
  2629. \end_inset
  2630. </cell>
  2631. <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  2632. \begin_inset Text
  2633. \begin_layout Plain Layout
  2634. 0
  2635. \end_layout
  2636. \end_inset
  2637. </cell>
  2638. </row>
  2639. <row>
  2640. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  2641. \begin_inset Text
  2642. \begin_layout Plain Layout
  2643. Home
  2644. \end_layout
  2645. \end_inset
  2646. </cell>
  2647. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  2648. \begin_inset Text
  2649. \begin_layout Plain Layout
  2650. 0
  2651. \end_layout
  2652. \end_inset
  2653. </cell>
  2654. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  2655. \begin_inset Text
  2656. \begin_layout Plain Layout
  2657. 1
  2658. \end_layout
  2659. \end_inset
  2660. </cell>
  2661. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  2662. \begin_inset Text
  2663. \begin_layout Plain Layout
  2664. 0%
  2665. \end_layout
  2666. \end_inset
  2667. </cell>
  2668. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  2669. \begin_inset Text
  2670. \begin_layout Plain Layout
  2671. 1
  2672. \end_layout
  2673. \end_inset
  2674. </cell>
  2675. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  2676. \begin_inset Text
  2677. \begin_layout Plain Layout
  2678. 0
  2679. \end_layout
  2680. \end_inset
  2681. </cell>
  2682. <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  2683. \begin_inset Text
  2684. \begin_layout Plain Layout
  2685. 0
  2686. \end_layout
  2687. \end_inset
  2688. </cell>
  2689. </row>
  2690. <row>
  2691. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  2692. \begin_inset Text
  2693. \begin_layout Plain Layout
  2694. Home
  2695. \end_layout
  2696. \end_inset
  2697. </cell>
  2698. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  2699. \begin_inset Text
  2700. \begin_layout Plain Layout
  2701. 0
  2702. \end_layout
  2703. \end_inset
  2704. </cell>
  2705. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  2706. \begin_inset Text
  2707. \begin_layout Plain Layout
  2708. 2
  2709. \end_layout
  2710. \end_inset
  2711. </cell>
  2712. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  2713. \begin_inset Text
  2714. \begin_layout Plain Layout
  2715. 0%
  2716. \end_layout
  2717. \end_inset
  2718. </cell>
  2719. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  2720. \begin_inset Text
  2721. \begin_layout Plain Layout
  2722. 2
  2723. \end_layout
  2724. \end_inset
  2725. </cell>
  2726. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  2727. \begin_inset Text
  2728. \begin_layout Plain Layout
  2729. 0
  2730. \end_layout
  2731. \end_inset
  2732. </cell>
  2733. <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  2734. \begin_inset Text
  2735. \begin_layout Plain Layout
  2736. 0
  2737. \end_layout
  2738. \end_inset
  2739. </cell>
  2740. </row>
  2741. <row>
  2742. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  2743. \begin_inset Text
  2744. \begin_layout Plain Layout
  2745. Lecture
  2746. \end_layout
  2747. \end_inset
  2748. </cell>
  2749. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  2750. \begin_inset Text
  2751. \begin_layout Plain Layout
  2752. 5
  2753. \end_layout
  2754. \end_inset
  2755. </cell>
  2756. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  2757. \begin_inset Text
  2758. \begin_layout Plain Layout
  2759. 80
  2760. \end_layout
  2761. \end_inset
  2762. </cell>
  2763. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  2764. \begin_inset Text
  2765. \begin_layout Plain Layout
  2766. 6%
  2767. \end_layout
  2768. \end_inset
  2769. </cell>
  2770. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  2771. \begin_inset Text
  2772. \begin_layout Plain Layout
  2773. 10
  2774. \end_layout
  2775. \end_inset
  2776. </cell>
  2777. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  2778. \begin_inset Text
  2779. \begin_layout Plain Layout
  2780. 70
  2781. \end_layout
  2782. \end_inset
  2783. </cell>
  2784. <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  2785. \begin_inset Text
  2786. \begin_layout Plain Layout
  2787. 0
  2788. \end_layout
  2789. \end_inset
  2790. </cell>
  2791. </row>
  2792. <row>
  2793. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  2794. \begin_inset Text
  2795. \begin_layout Plain Layout
  2796. Meeting
  2797. \end_layout
  2798. \end_inset
  2799. </cell>
  2800. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  2801. \begin_inset Text
  2802. \begin_layout Plain Layout
  2803. 1
  2804. \end_layout
  2805. \end_inset
  2806. </cell>
  2807. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  2808. \begin_inset Text
  2809. \begin_layout Plain Layout
  2810. 6
  2811. \end_layout
  2812. \end_inset
  2813. </cell>
  2814. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  2815. \begin_inset Text
  2816. \begin_layout Plain Layout
  2817. 17%
  2818. \end_layout
  2819. \end_inset
  2820. </cell>
  2821. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  2822. \begin_inset Text
  2823. \begin_layout Plain Layout
  2824. 6
  2825. \end_layout
  2826. \end_inset
  2827. </cell>
  2828. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  2829. \begin_inset Text
  2830. \begin_layout Plain Layout
  2831. 0
  2832. \end_layout
  2833. \end_inset
  2834. </cell>
  2835. <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  2836. \begin_inset Text
  2837. \begin_layout Plain Layout
  2838. 0
  2839. \end_layout
  2840. \end_inset
  2841. </cell>
  2842. </row>
  2843. <row>
  2844. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  2845. \begin_inset Text
  2846. \begin_layout Plain Layout
  2847. Restaurant
  2848. \end_layout
  2849. \end_inset
  2850. </cell>
  2851. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  2852. \begin_inset Text
  2853. \begin_layout Plain Layout
  2854. 2
  2855. \end_layout
  2856. \end_inset
  2857. </cell>
  2858. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  2859. \begin_inset Text
  2860. \begin_layout Plain Layout
  2861. 22
  2862. \end_layout
  2863. \end_inset
  2864. </cell>
  2865. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  2866. \begin_inset Text
  2867. \begin_layout Plain Layout
  2868. 9%
  2869. \end_layout
  2870. \end_inset
  2871. </cell>
  2872. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  2873. \begin_inset Text
  2874. \begin_layout Plain Layout
  2875. 1
  2876. \end_layout
  2877. \end_inset
  2878. </cell>
  2879. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  2880. \begin_inset Text
  2881. \begin_layout Plain Layout
  2882. 2
  2883. \end_layout
  2884. \end_inset
  2885. </cell>
  2886. <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  2887. \begin_inset Text
  2888. \begin_layout Plain Layout
  2889. 19
  2890. \end_layout
  2891. \end_inset
  2892. </cell>
  2893. </row>
  2894. <row>
  2895. <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
  2896. \begin_inset Text
  2897. \begin_layout Plain Layout
  2898. Supermarket
  2899. \end_layout
  2900. \end_inset
  2901. </cell>
  2902. <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
  2903. \begin_inset Text
  2904. \begin_layout Plain Layout
  2905. 2
  2906. \end_layout
  2907. \end_inset
  2908. </cell>
  2909. <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
  2910. \begin_inset Text
  2911. \begin_layout Plain Layout
  2912. 1
  2913. \end_layout
  2914. \end_inset
  2915. </cell>
  2916. <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
  2917. \begin_inset Text
  2918. \begin_layout Plain Layout
  2919. 200%
  2920. \end_layout
  2921. \end_inset
  2922. </cell>
  2923. <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
  2924. \begin_inset Text
  2925. \begin_layout Plain Layout
  2926. 0
  2927. \end_layout
  2928. \end_inset
  2929. </cell>
  2930. <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
  2931. \begin_inset Text
  2932. \begin_layout Plain Layout
  2933. 0
  2934. \end_layout
  2935. \end_inset
  2936. </cell>
  2937. <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
  2938. \begin_inset Text
  2939. \begin_layout Plain Layout
  2940. 1
  2941. \end_layout
  2942. \end_inset
  2943. </cell>
  2944. </row>
  2945. </lyxtabular>
  2946. \end_inset
  2947. \end_layout
  2948. \begin_layout Plain Layout
  2949. \begin_inset Caption
  2950. \begin_layout Plain Layout
  2951. Bluetooth scanning results
  2952. \begin_inset CommandInset label
  2953. LatexCommand label
  2954. name "tab:Bluetooth-scanning-results"
  2955. \end_inset
  2956. \end_layout
  2957. \end_inset
  2958. \end_layout
  2959. \begin_layout Plain Layout
  2960. \end_layout
  2961. \end_inset
  2962. For the experiment, the users were asked to record the number of visible
  2963. Bluetooth devices, their environment and the estimated number of people
  2964. around them.
  2965. They were also asked to classify the people into rough groups of
  2966. \begin_inset Quotes eld
  2967. \end_inset
  2968. familiar
  2969. \begin_inset Quotes erd
  2970. \end_inset
  2971. (such as co-workers, family and friends),
  2972. \begin_inset Quotes eld
  2973. \end_inset
  2974. familiar strangers
  2975. \begin_inset Quotes erd
  2976. \end_inset
  2977. (people they see regularly but are not particularly familiar with), or
  2978. \begin_inset Quotes eld
  2979. \end_inset
  2980. strangers
  2981. \begin_inset Quotes erd
  2982. \end_inset
  2983. .
  2984. The results are itemised in
  2985. \begin_inset CommandInset ref
  2986. LatexCommand prettyref
  2987. reference "tab:Bluetooth-scanning-results"
  2988. \end_inset
  2989. .
  2990. \end_layout
  2991. \begin_layout Standard
  2992. The results show that in general there is a very poor proportion of devices
  2993. that are visible.
  2994. The results also suggest that Bluetooth would be a poor method for finding
  2995. \begin_inset Quotes eld
  2996. \end_inset
  2997. familiar
  2998. \begin_inset Quotes erd
  2999. \end_inset
  3000. people, as the situations with very few strangers generally had almost
  3001. no discoverable devices.
  3002. There are several possible reasons for the low proportion of devices: modern
  3003. phones tend to default to having Bluetooth switched off for reasons of
  3004. battery life and user privacy, and even when enabled the devices tend to
  3005. default to being non-discoverable.
  3006. In fact, Android devices will only allow the user to make the device discoverab
  3007. le for 30 seconds at a time - the setting is automatically reverted after
  3008. this period.
  3009. Another consideration is that the three volunteers are all involved in
  3010. extremely technology-focused settings: one was a student studying a computing
  3011. course, one a software engineer, and one a systems administrator.
  3012. Whether or not these technology-rich settings would artificially inflate
  3013. results (more technology means more discoverable devices) or deflate them
  3014. (more tech-savvy users mean fewer needlessly enabling Bluetooth discovery)
  3015. is unclear.
  3016. \end_layout
  3017. \begin_layout Section
  3018. Microphone
  3019. \begin_inset CommandInset label
  3020. LatexCommand label
  3021. name "sec:Microphone"
  3022. \end_inset
  3023. \end_layout
  3024. \begin_layout Standard
  3025. Reading raw data from the Microphone on Android is relatively straight forward
  3026. thanks to the built-in
  3027. \noun on
  3028. AudioRecord
  3029. \noun default
  3030. class.
  3031. This allows raw data to be retrieved directly into an array of bytes, where
  3032. it can then be analysed.
  3033. A class was written which constructs an
  3034. \noun on
  3035. AudioRecord
  3036. \noun default
  3037. instance, retrieves a sample of data, and calculates the sound pressure
  3038. level (SPL).
  3039. The SPL can be used to measure the ambient volume of the environment the
  3040. device is in - for example, a quiet room would typically have an SPL of
  3041. 20-30 dB, a television might raise that to the level of 60 dB, and a busy
  3042. road could be up to 90 dB.
  3043. SPL is calculated using the formula
  3044. \begin_inset Formula $L_{p}=20log_{10}(\frac{p_{rms}}{p_{ref}})$
  3045. \end_inset
  3046. .
  3047. \begin_inset Formula $p_{ref}$
  3048. \end_inset
  3049. is the reference sound level and is usually taken to be 20 micropascals,
  3050. which is the limit of human hearing;
  3051. \begin_inset Formula $p_{rms}$
  3052. \end_inset
  3053. is the root mean square pressure being measured.
  3054. \end_layout
  3055. \begin_layout Standard
  3056. While the class was able to correctly calculate the SPL, it is not used
  3057. in any of the published applications.
  3058. The original intention was to use SPL to assist in activity inference,
  3059. but as shown in
  3060. \begin_inset CommandInset ref
  3061. LatexCommand prettyref
  3062. reference "sub:Market-and-user"
  3063. \end_inset
  3064. the accelerometer alone achieves a satisfactory classification rate on
  3065. its own.
  3066. The large majority of incorrect classifications revolved around the user
  3067. sitting down and, as sitting is such a universal activity (i.e., it's performed
  3068. everywhere), knowing the ambient SPL will not help in this classification.
  3069. \end_layout
  3070. \begin_layout Standard
  3071. While there are certainly use cases for knowing the SPL (the most obvious
  3072. being increasing or decreasing the ringer volume in proportion to the SPL
  3073. to ensure it can be heard), most of them do not involve any other form
  3074. of context that this project is aiming to expose.
  3075. It was therefore decided to not include the SPL data in the main context
  3076. API.
  3077. \end_layout
  3078. \begin_layout Section
  3079. Camera
  3080. \begin_inset CommandInset label
  3081. LatexCommand label
  3082. name "sec:Camera"
  3083. \end_inset
  3084. \end_layout
  3085. \begin_layout Standard
  3086. The aim of incorporating data from the device's camera was to determine
  3087. the ambient lighting conditions.
  3088. It could possibly then be inferred whether the user was in natural or artificia
  3089. l light, or in darkness.
  3090. However on consultation with a group of five prospective users it became
  3091. clear that at the times at which the device would be classifying context,
  3092. it would almost always be inside a pocket or a bag.
  3093. The only times the device would be able to detect lighting conditions would
  3094. be as the user was using it (which is too late as the device should have
  3095. already adapted to the user's context) or when the device had been left
  3096. on a desk or shelf.
  3097. It was therefore decided to not include camera data at this stage of the
  3098. project.
  3099. \end_layout
  3100. \begin_layout Standard
  3101. \begin_inset Newpage pagebreak
  3102. \end_inset
  3103. \end_layout
  3104. \begin_layout Part
  3105. \begin_inset CommandInset label
  3106. LatexCommand label
  3107. name "par:Places"
  3108. \end_inset
  3109. Places
  3110. \end_layout
  3111. \begin_layout Section
  3112. Use of GPS/GSM blackspots
  3113. \begin_inset CommandInset label
  3114. LatexCommand label
  3115. name "sec:Use-of-GPS/GSM"
  3116. \end_inset
  3117. \end_layout
  3118. \begin_layout Standard
  3119. As discussed in
  3120. \begin_inset CommandInset ref
  3121. LatexCommand prettyref
  3122. reference "sec:Location-analysis"
  3123. \end_inset
  3124. a lot of existing research into identifying interesting places relied on
  3125. the fact that with hardware that is now 5-10 years old, you could not reliably
  3126. get a GPS signal indoors.
  3127. Thus whenever the user remained somewhere without a GPS signal it was likely
  3128. that they were spending time indoors, and therefore their current location
  3129. would be noteworthy.
  3130. \end_layout
  3131. \begin_layout Standard
  3132. Unfortunately, modern GPS hardware is much more sensitive and can quite
  3133. easily get a signal indoors in most circumstances.
  3134. One possible solution to this was to monitor the strength of either the
  3135. GPS lock or the GSM signal, and attempt to determine whether or not a differenc
  3136. e was noticeable.
  3137. An experiment was therefore conducted to record the GPS and GSM status
  3138. for multiple indoor and outdoor locations.
  3139. \end_layout
  3140. \begin_layout Standard
  3141. \begin_inset Float table
  3142. placement bh
  3143. wide false
  3144. sideways false
  3145. status collapsed
  3146. \begin_layout Plain Layout
  3147. \begin_inset Tabular
  3148. <lyxtabular version="3" rows="9" columns="4">
  3149. <features>
  3150. <column alignment="center" valignment="top" width="0">
  3151. <column alignment="center" valignment="top" width="0">
  3152. <column alignment="center" valignment="top" width="0">
  3153. <column alignment="center" valignment="top" width="0">
  3154. <row>
  3155. <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
  3156. \begin_inset Text
  3157. \begin_layout Plain Layout
  3158. Location
  3159. \end_layout
  3160. \end_inset
  3161. </cell>
  3162. <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
  3163. \begin_inset Text
  3164. \begin_layout Plain Layout
  3165. GSM strength
  3166. \end_layout
  3167. \end_inset
  3168. </cell>
  3169. <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
  3170. \begin_inset Text
  3171. \begin_layout Plain Layout
  3172. GPS satellites
  3173. \end_layout
  3174. \end_inset
  3175. </cell>
  3176. <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
  3177. \begin_inset Text
  3178. \begin_layout Plain Layout
  3179. GPS time to fix
  3180. \end_layout
  3181. \end_inset
  3182. </cell>
  3183. </row>
  3184. <row>
  3185. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  3186. \begin_inset Text
  3187. \begin_layout Plain Layout
  3188. Indoors
  3189. \end_layout
  3190. \end_inset
  3191. </cell>
  3192. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  3193. \begin_inset Text
  3194. \begin_layout Plain Layout
  3195. -101 dBm
  3196. \end_layout
  3197. \end_inset
  3198. </cell>
  3199. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  3200. \begin_inset Text
  3201. \begin_layout Plain Layout
  3202. 10
  3203. \end_layout
  3204. \end_inset
  3205. </cell>
  3206. <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  3207. \begin_inset Text
  3208. \begin_layout Plain Layout
  3209. <1 sec
  3210. \end_layout
  3211. \end_inset
  3212. </cell>
  3213. </row>
  3214. <row>
  3215. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  3216. \begin_inset Text
  3217. \begin_layout Plain Layout
  3218. Outdoors
  3219. \end_layout
  3220. \end_inset
  3221. </cell>
  3222. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  3223. \begin_inset Text
  3224. \begin_layout Plain Layout
  3225. -101 dBm
  3226. \end_layout
  3227. \end_inset
  3228. </cell>
  3229. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  3230. \begin_inset Text
  3231. \begin_layout Plain Layout
  3232. 8
  3233. \end_layout
  3234. \end_inset
  3235. </cell>
  3236. <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  3237. \begin_inset Text
  3238. \begin_layout Plain Layout
  3239. <1 sec
  3240. \end_layout
  3241. \end_inset
  3242. </cell>
  3243. </row>
  3244. <row>
  3245. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  3246. \begin_inset Text
  3247. \begin_layout Plain Layout
  3248. Indoors
  3249. \end_layout
  3250. \end_inset
  3251. </cell>
  3252. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  3253. \begin_inset Text
  3254. \begin_layout Plain Layout
  3255. -71 dBm
  3256. \end_layout
  3257. \end_inset
  3258. </cell>
  3259. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  3260. \begin_inset Text
  3261. \begin_layout Plain Layout
  3262. 6
  3263. \end_layout
  3264. \end_inset
  3265. </cell>
  3266. <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  3267. \begin_inset Text
  3268. \begin_layout Plain Layout
  3269. 2 sec
  3270. \end_layout
  3271. \end_inset
  3272. </cell>
  3273. </row>
  3274. <row>
  3275. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  3276. \begin_inset Text
  3277. \begin_layout Plain Layout
  3278. Outdoors
  3279. \end_layout
  3280. \end_inset
  3281. </cell>
  3282. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  3283. \begin_inset Text
  3284. \begin_layout Plain Layout
  3285. -67 dBm
  3286. \end_layout
  3287. \end_inset
  3288. </cell>
  3289. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  3290. \begin_inset Text
  3291. \begin_layout Plain Layout
  3292. 7
  3293. \end_layout
  3294. \end_inset
  3295. </cell>
  3296. <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  3297. \begin_inset Text
  3298. \begin_layout Plain Layout
  3299. 2 sec
  3300. \end_layout
  3301. \end_inset
  3302. </cell>
  3303. </row>
  3304. <row>
  3305. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  3306. \begin_inset Text
  3307. \begin_layout Plain Layout
  3308. Indoors
  3309. \end_layout
  3310. \end_inset
  3311. </cell>
  3312. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  3313. \begin_inset Text
  3314. \begin_layout Plain Layout
  3315. -67 dBm
  3316. \end_layout
  3317. \end_inset
  3318. </cell>
  3319. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  3320. \begin_inset Text
  3321. \begin_layout Plain Layout
  3322. 11
  3323. \end_layout
  3324. \end_inset
  3325. </cell>
  3326. <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  3327. \begin_inset Text
  3328. \begin_layout Plain Layout
  3329. <1 sec
  3330. \end_layout
  3331. \end_inset
  3332. </cell>
  3333. </row>
  3334. <row>
  3335. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  3336. \begin_inset Text
  3337. \begin_layout Plain Layout
  3338. Outdoors
  3339. \end_layout
  3340. \end_inset
  3341. </cell>
  3342. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  3343. \begin_inset Text
  3344. \begin_layout Plain Layout
  3345. -67 dBm
  3346. \end_layout
  3347. \end_inset
  3348. </cell>
  3349. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  3350. \begin_inset Text
  3351. \begin_layout Plain Layout
  3352. 10
  3353. \end_layout
  3354. \end_inset
  3355. </cell>
  3356. <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  3357. \begin_inset Text
  3358. \begin_layout Plain Layout
  3359. 3 secs
  3360. \end_layout
  3361. \end_inset
  3362. </cell>
  3363. </row>
  3364. <row>
  3365. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  3366. \begin_inset Text
  3367. \begin_layout Plain Layout
  3368. Indoors
  3369. \end_layout
  3370. \end_inset
  3371. </cell>
  3372. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  3373. \begin_inset Text
  3374. \begin_layout Plain Layout
  3375. -67 dBm
  3376. \end_layout
  3377. \end_inset
  3378. </cell>
  3379. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  3380. \begin_inset Text
  3381. \begin_layout Plain Layout
  3382. 10
  3383. \end_layout
  3384. \end_inset
  3385. </cell>
  3386. <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  3387. \begin_inset Text
  3388. \begin_layout Plain Layout
  3389. <1 sec
  3390. \end_layout
  3391. \end_inset
  3392. </cell>
  3393. </row>
  3394. <row>
  3395. <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
  3396. \begin_inset Text
  3397. \begin_layout Plain Layout
  3398. Outdoors
  3399. \end_layout
  3400. \end_inset
  3401. </cell>
  3402. <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
  3403. \begin_inset Text
  3404. \begin_layout Plain Layout
  3405. -43 dBm
  3406. \end_layout
  3407. \end_inset
  3408. </cell>
  3409. <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
  3410. \begin_inset Text
  3411. \begin_layout Plain Layout
  3412. 10
  3413. \end_layout
  3414. \end_inset
  3415. </cell>
  3416. <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
  3417. \begin_inset Text
  3418. \begin_layout Plain Layout
  3419. <1 sec
  3420. \end_layout
  3421. \end_inset
  3422. </cell>
  3423. </row>
  3424. </lyxtabular>
  3425. \end_inset
  3426. \end_layout
  3427. \begin_layout Plain Layout
  3428. \begin_inset Caption
  3429. \begin_layout Plain Layout
  3430. GPS and GSM strengths
  3431. \begin_inset CommandInset label
  3432. LatexCommand label
  3433. name "tab:GPS-and-GSM"
  3434. \end_inset
  3435. \end_layout
  3436. \end_inset
  3437. \end_layout
  3438. \begin_layout Plain Layout
  3439. \end_layout
  3440. \end_inset
  3441. At four separate indoor locations, the third-party
  3442. \noun on
  3443. GPS Status
  3444. \noun default
  3445. application was used to observe the number of satellites the device was
  3446. receiving a signal from, and the amount of time it took to acquire a fix
  3447. on all of those satellites.
  3448. The GSM signal strength as reported by the device's built in debugging
  3449. tools was also recorded.
  3450. The device was then moved outdoors to the nearest appropriate open area
  3451. (footpath, outdoor seating area, etc), and the process was repeated.
  3452. The results are summarised in
  3453. \begin_inset CommandInset ref
  3454. LatexCommand prettyref
  3455. reference "tab:GPS-and-GSM"
  3456. \end_inset
  3457. .
  3458. \end_layout
  3459. \begin_layout Standard
  3460. While the indoor GSM strength is lower than the corresponding outdoor strength
  3461. in two out of the four samples, it is still significantly stronger than
  3462. the weakest recorded indoor or outdoor signal.
  3463. In the other two cases the signal strength was the same for both indoors
  3464. and outdoors.
  3465. The GSM signal strength therefore seems to be a poor indicator of whether
  3466. or not the user is indoors - it would have to be continually monitored
  3467. to detect a drop in signal strength, and the (limited) experimental data
  3468. shows that this would have a 50% false negative rate.
  3469. The experiment does not allow us to reason about false positives, but it
  3470. is easy to imagine that many circumstances would give rise to drops in
  3471. signal strength - the most obvious being moving away from the cell tower.
  3472. \end_layout
  3473. \begin_layout Standard
  3474. The GPS results show even less correlation between indoor and outdoor readings.
  3475. In two out of the four locations, the indoor test identified more satellites
  3476. than the outdoor test - the opposite to what would be expected.
  3477. This could be because the indoor locations were typically above ground
  3478. level - the extra altitude may be more beneficial to obtaining a lock than
  3479. the obstruction of the building itself.
  3480. It seems more likely, however, that the numbers are not correlated in any
  3481. way, and a larger experiment would reveal it to be random variance.
  3482. Similarly, the time taken to lock the satellites is typically very small,
  3483. but in a few situations there is a noticeable delay.
  3484. The location which resulted in a three second lock time was repeated after
  3485. a thirty second pause and obtained a sub-second lock time, but the original
  3486. data was included in the results.
  3487. \end_layout
  3488. \begin_layout Standard
  3489. The experiment, although extremely limited in size, shows that it is unlikely
  3490. that GSM strength or GPS metadata would be useful in determining interesting
  3491. places.
  3492. Alternative methods therefore had to be considered.
  3493. \end_layout
  3494. \begin_layout Section
  3495. Detecting places by time spent
  3496. \end_layout
  3497. \begin_layout Standard
  3498. Without information about whether or not the user is indoors, the next best
  3499. method to detect interesting places is by monitoring the amount of time
  3500. the user spends there.
  3501. It stands to reason that a location where the user is only present fleetingly
  3502. as they pass through is less important than somewhere they spend half a
  3503. day.
  3504. \end_layout
  3505. \begin_layout Standard
  3506. The Android operating system provides two methods of determining the user's
  3507. location -
  3508. \begin_inset Quotes eld
  3509. \end_inset
  3510. coarse
  3511. \begin_inset Quotes erd
  3512. \end_inset
  3513. , which uses a cell tower and WiFi access point database, and
  3514. \begin_inset Quotes eld
  3515. \end_inset
  3516. fine
  3517. \begin_inset Quotes erd
  3518. \end_inset
  3519. which uses the device's GPS chipset.
  3520. While
  3521. \begin_inset Quotes eld
  3522. \end_inset
  3523. coarse
  3524. \begin_inset Quotes erd
  3525. \end_inset
  3526. is less accurate than using GPS, it also uses significantly less battery
  3527. power.
  3528. Brief testing revealed that while GPS regularly obtained accuracies of
  3529. below five metres,
  3530. \begin_inset Quotes eld
  3531. \end_inset
  3532. network
  3533. \begin_inset Quotes erd
  3534. \end_inset
  3535. location (using cell tower IDs and a built-in database) obtained accuracies
  3536. in the region of 500 metres.
  3537. Network location augmented with the built-in database of WiFi access point
  3538. locations obtained accuracies in the same region as GPS.
  3539. However, WiFi augmentation only works when the user has elected to enable
  3540. WiFi on their device, and this puts a large drain on the battery.
  3541. \end_layout
  3542. \begin_layout Standard
  3543. As the most important places a user typically visits will be much greater
  3544. than 500 metres apart,
  3545. \begin_inset Quotes eld
  3546. \end_inset
  3547. coarse
  3548. \begin_inset Quotes erd
  3549. \end_inset
  3550. location will was used for all location-related tasks in the project.
  3551. Because of this large inaccuracy, places could not be represented by a
  3552. single point but must have a radius to compensate for the inaccuracy.
  3553. Based on earlier experimentation, this radius was fixed at 500 metres.
  3554. \end_layout
  3555. \begin_layout Standard
  3556. A new
  3557. \begin_inset Quotes eld
  3558. \end_inset
  3559. place
  3560. \begin_inset Quotes erd
  3561. \end_inset
  3562. is identified when the user remains within 500 metres of a point for at
  3563. least 3 minutes.
  3564. This figure is, hopefully, long enough to eliminate places where the user
  3565. is temporarily held up (such as traffic lights), but short enough to include
  3566. places the user visits but doesn't remain for a long length of time (such
  3567. as supermarkets).
  3568. When implementing this algorithm, care was taken to ensure that the length
  3569. of time was defined as a constant and so could easily be changed if experimenta
  3570. l data showed that it was either too long or too short.
  3571. \end_layout
  3572. \begin_layout Standard
  3573. \begin_inset Newpage pagebreak
  3574. \end_inset
  3575. \end_layout
  3576. \begin_layout Part
  3577. \begin_inset CommandInset label
  3578. LatexCommand label
  3579. name "par:The-Context-Analyser"
  3580. \end_inset
  3581. The
  3582. \noun on
  3583. Context Analyser
  3584. \noun default
  3585. and applications
  3586. \end_layout
  3587. \begin_layout Standard
  3588. The primary output of this project is the
  3589. \noun on
  3590. Context Analyser
  3591. \noun default
  3592. application, and several further applications which use the services exposed
  3593. by the
  3594. \noun on
  3595. Context Analyser.
  3596. \noun default
  3597. \end_layout
  3598. \begin_layout Section
  3599. The
  3600. \noun on
  3601. Context Analyser
  3602. \end_layout
  3603. \begin_layout Standard
  3604. The
  3605. \noun on
  3606. Context Analyser
  3607. \noun default
  3608. itself is an application with a single service, a single activity, and
  3609. four content providers.
  3610. Its purpose is to monitor the user's context, analyse it as necessary,
  3611. and expose the data to other applications which will actually do something
  3612. useful with it.
  3613. It reuses components developed for the
  3614. \noun on
  3615. Activity Recorder
  3616. \noun default
  3617. application to retrieve and process accelerometer input, and a
  3618. \noun on
  3619. LocationMonitor
  3620. \noun default
  3621. class which wraps around Android's built in location services.
  3622. Persistent data such as places is stored in a
  3623. \noun on
  3624. SQLite
  3625. \noun default
  3626. database, with logic in a custom helper class which handles creation and
  3627. maintenance of tables and allows interaction with the database without
  3628. exposing SQL to the rest of the application.
  3629. \end_layout
  3630. \begin_layout Subsection
  3631. Accelerometer and location components
  3632. \end_layout
  3633. \begin_layout Standard
  3634. \begin_inset Float figure
  3635. wide false
  3636. sideways false
  3637. status collapsed
  3638. \begin_layout Plain Layout
  3639. \begin_inset Graphics
  3640. filename uml-accel.png
  3641. scale 50
  3642. rotateAngle 90
  3643. \end_inset
  3644. \end_layout
  3645. \begin_layout Plain Layout
  3646. \begin_inset Caption
  3647. \begin_layout Plain Layout
  3648. Accelerometer component class diagram
  3649. \begin_inset CommandInset label
  3650. LatexCommand label
  3651. name "fig:Accelerometer-component-class"
  3652. \end_inset
  3653. \end_layout
  3654. \end_inset
  3655. \end_layout
  3656. \begin_layout Plain Layout
  3657. \end_layout
  3658. \end_inset
  3659. \begin_inset CommandInset ref
  3660. LatexCommand prettyref
  3661. reference "fig:Accelerometer-component-class"
  3662. \end_inset
  3663. shows the key components used in the activity inference portion of the
  3664. \noun on
  3665. Context Analyser.
  3666. \noun default
  3667. The
  3668. \noun on
  3669. accel
  3670. \noun default
  3671. package handles low-level collection of accelerometer readings.
  3672. The
  3673. \noun on
  3674. RealAccelReader
  3675. \noun default
  3676. class registers itself to receive sensor events and then makes the received
  3677. data available through a public method.
  3678. It also handles acquiring of a wake lock as discussed in
  3679. \begin_inset CommandInset ref
  3680. LatexCommand prettyref
  3681. reference "sub:Acquiring-data-while"
  3682. \end_inset
  3683. to keep the device sufficiently 'awake' to collect sensor data.
  3684. \noun on
  3685. AccelReader
  3686. \noun default
  3687. s are constructed by a factory so that they can be swapped out for test
  3688. implementations if required, or when using an emulator which lacks real
  3689. acceleration sensors.
  3690. \end_layout
  3691. \begin_layout Standard
  3692. The
  3693. \noun on
  3694. Sampler
  3695. \noun default
  3696. class handles automatic, timed sampling of a reader.
  3697. Once started, it starts its
  3698. \noun on
  3699. AccelReader
  3700. \noun default
  3701. and then records a sample every 50ms until it has obtained 128 samples.
  3702. As it retrieves each sample, it computes the minimum, maximum and sum of
  3703. both axes that are needed for classification.
  3704. When 128 samples have been recorded, it executes the
  3705. \noun on
  3706. run
  3707. \noun default
  3708. method of a
  3709. \noun on
  3710. Runnable
  3711. \noun default
  3712. provided at construction, so the owner can retrieve the results and analyse
  3713. them appropriately.
  3714. \end_layout
  3715. \begin_layout Standard
  3716. The
  3717. \noun on
  3718. Classifier
  3719. \noun default
  3720. is identical to that used in both the
  3721. \noun on
  3722. Sensor Logger
  3723. \noun default
  3724. and
  3725. \noun on
  3726. Activity Recorder
  3727. \noun default
  3728. applications, and applies the K-Nearest Network algorithm to its given
  3729. input and model.
  3730. The
  3731. \noun on
  3732. ModelReader
  3733. \noun default
  3734. is a utility class which reads and deserialises the model bundled with
  3735. the application.
  3736. \end_layout
  3737. \begin_layout Standard
  3738. The
  3739. \noun on
  3740. Aggregator
  3741. \noun default
  3742. handles aggregation of a stream of classifications, smoothing out occasional
  3743. spurious results as discussed in
  3744. \begin_inset CommandInset ref
  3745. LatexCommand prettyref
  3746. reference "sub:Aggregating-classifications-to"
  3747. \end_inset
  3748. .
  3749. The
  3750. \noun on
  3751. AutoAggregator
  3752. \noun default
  3753. is an extension of this which automatically uses a
  3754. \noun on
  3755. Sampler
  3756. \noun default
  3757. and a
  3758. \noun on
  3759. Classifier
  3760. \noun default
  3761. to obtain the classifications itself.
  3762. As with
  3763. \noun on
  3764. AccelReader
  3765. \noun default
  3766. s, it is constructed by a factory so it can be swapped out for a stubbed
  3767. implementation with ease.
  3768. The factory will provide a
  3769. \noun on
  3770. FakeAutoAggregator
  3771. \noun default
  3772. if it detects it is running on the Android Emulator; this implementation
  3773. simply cycles through a list of pre-defined activities to allow mocking
  3774. of the entire activity inference procedure.
  3775. \end_layout
  3776. \begin_layout Standard
  3777. Together, these components are capable of inferring and aggregating the
  3778. user's current activity from accelerometer data.
  3779. The factory classes facilitate injection of deterministic classes which
  3780. can be used to test the system or to eliminate the system from any testing
  3781. entirely.
  3782. \end_layout
  3783. \begin_layout Standard
  3784. The location handling package consists of one interface, a factory, and
  3785. two concrete implementations.
  3786. The
  3787. \noun on
  3788. LocationMonitor
  3789. \noun default
  3790. interface simply specifies methods to retrieve the current latitude, longitude
  3791. and accuracy.
  3792. A concrete
  3793. \noun on
  3794. RealLocationMonitor
  3795. \noun default
  3796. implements this by registering for location events with Android's built
  3797. in
  3798. \noun on
  3799. LocationManager
  3800. \noun default
  3801. service, while the
  3802. \noun on
  3803. FakeLocationMonitor
  3804. \noun default
  3805. merely cycles through a pre-defined list of latitude and longitude pairs.
  3806. A factory class determines which implementation to return based on whether
  3807. or not the code is being executed on an emulator.
  3808. \end_layout
  3809. \begin_layout Subsection
  3810. The
  3811. \noun on
  3812. ContextAnalyserService
  3813. \end_layout
  3814. \begin_layout Standard
  3815. The
  3816. \noun on
  3817. ContextAnalyserService
  3818. \noun default
  3819. is an Android
  3820. \noun on
  3821. Service
  3822. \noun default
  3823. that handles periodic querying of the accelerometer and location components
  3824. described above, and other assorted tasks related to that data.
  3825. When it starts, the service creates a new
  3826. \noun on
  3827. AutoAggregator
  3828. \noun default
  3829. , a new
  3830. \noun on
  3831. DataHelper
  3832. \noun default
  3833. , an instance of Android's built in
  3834. \noun on
  3835. Geocoder
  3836. \noun default
  3837. class, and a
  3838. \noun on
  3839. LocationMonitor
  3840. \noun default
  3841. .
  3842. It also retrieves a list of place names which have not yet been geocoded,
  3843. registers a listener for an application preferences setting titled
  3844. \begin_inset Quotes eld
  3845. \end_inset
  3846. run
  3847. \begin_inset Quotes erd
  3848. \end_inset
  3849. , and schedules its polling method to be called after a sixty second delay.
  3850. \end_layout
  3851. \begin_layout Standard
  3852. Every sixty seconds, the service then:
  3853. \end_layout
  3854. \begin_layout Itemize
  3855. Retrieves the current latitude and longitude from its
  3856. \noun on
  3857. LocationMonitor
  3858. \end_layout
  3859. \begin_layout Itemize
  3860. Computes the distance between the last stored location and the new position
  3861. \end_layout
  3862. \begin_deeper
  3863. \begin_layout Itemize
  3864. If the distance is less than 500m, there is no known Place associated with
  3865. the current location, and this location has been observed at least three
  3866. times:
  3867. \end_layout
  3868. \begin_deeper
  3869. \begin_layout Itemize
  3870. Creates a new place with the latitude and longitude as a name
  3871. \end_layout
  3872. \begin_layout Itemize
  3873. Tells the data helper to add the place to the database
  3874. \end_layout
  3875. \begin_layout Itemize
  3876. Adds the place to the list of place names needing geocoding
  3877. \end_layout
  3878. \end_deeper
  3879. \begin_layout Itemize
  3880. If the distance is greater than 500m:
  3881. \end_layout
  3882. \begin_deeper
  3883. \begin_layout Itemize
  3884. Update the stored latitude and longitude to the new values
  3885. \end_layout
  3886. \begin_layout Itemize
  3887. If the previous location had an associated Place, tell the data helper to
  3888. record the visit
  3889. \end_layout
  3890. \end_deeper
  3891. \begin_layout Itemize
  3892. In both cases:
  3893. \end_layout
  3894. \begin_deeper
  3895. \begin_layout Itemize
  3896. Ask the data helper to find a Place corresponding to the new location, if
  3897. a place is found:
  3898. \end_layout
  3899. \begin_layout Itemize
  3900. Record the current time as the start time for this visit
  3901. \end_layout
  3902. \begin_layout Itemize
  3903. If a place had been visited previously, tell the data helper to record a
  3904. new journey with the activity log
  3905. \end_layout
  3906. \begin_layout Itemize
  3907. If the place is different to the last know place, send a broadcast intent
  3908. \end_layout
  3909. \end_deeper
  3910. \end_deeper
  3911. \begin_layout Itemize
  3912. Attempts to geocode any places with latitude/longitude names
  3913. \end_layout
  3914. \begin_layout Itemize
  3915. Starts the auto aggregator
  3916. \end_layout
  3917. \begin_layout Standard
  3918. When the auto aggregator finishes, the service retrieves the new aggregated
  3919. classification.
  3920. If the user is not at a known place, but has been to one in the past, the
  3921. activity is added to the activity log and the service checks for predictions.
  3922. If the activity is different to the last known activity, a broadcast intent
  3923. is sent.
  3924. \end_layout
  3925. \begin_layout Standard
  3926. Predictions work by checking for journeys which begin with similar activities
  3927. to those recorded in the activity log.
  3928. The data helper retrieves all known journeys originating at the user's
  3929. last known location.
  3930. Each journey is then analysed to determine if it is compatible with the
  3931. current activity log.
  3932. This involves comparing the activities in the journey to make sure that
  3933. they're the same as those logged, and the amount of time spent doing that
  3934. activity is reasonably close.
  3935. The current implementation allows for a ±50% variance in the number of
  3936. repetitions of an activity.
  3937. The activity log is also allowed to be a subset of the journey being tested,
  3938. as long as the subset includes the beginning of the journey (that is, the
  3939. activity log is allowed to be incomplete).
  3940. If the activity log is found to be compatible with the journey, the journey
  3941. is added to a list.
  3942. \end_layout
  3943. \begin_layout Standard
  3944. Once a list of compatible journeys has been found, they are grouped by destinati
  3945. on and the number of times each journey was made is summed into a
  3946. \begin_inset Quotes eld
  3947. \end_inset
  3948. score
  3949. \begin_inset Quotes erd
  3950. \end_inset
  3951. for each destination.
  3952. The best destination is then included in a broadcast intent, and all of
  3953. the predicted destinations are cached for use by the predictions content
  3954. provider.
  3955. \end_layout
  3956. \begin_layout Standard
  3957. The
  3958. \noun on
  3959. ContextAnalyserService
  3960. \noun default
  3961. exposes a
  3962. \noun on
  3963. Bindable
  3964. \noun default
  3965. interface with methods for retrieving the current activity and any predictions.
  3966. This is used for intra-process communication: content providers for the
  3967. activity and predictions can
  3968. \emph on
  3969. bind
  3970. \emph default
  3971. to the service and request the data they need directly.
  3972. Other content providers simply access the shared SQLite database themselves,
  3973. so do not need to communicate directly with the service.
  3974. \end_layout
  3975. \begin_layout Subsection
  3976. The public API
  3977. \end_layout
  3978. \begin_layout Standard
  3979. The primary purpose of the
  3980. \noun on
  3981. ContextAnalyser
  3982. \noun default
  3983. application is to expose the contextual information to third-party developers
  3984. in an easy-to-user manner.
  3985. To cater to different types of applications, two distinct methods are provided
  3986. that expose data: a set of
  3987. \emph on
  3988. broadcast intents
  3989. \emph default
  3990. which notify interested parties as and when a change occurs, and a collection
  3991. of
  3992. \emph on
  3993. content providers
  3994. \emph default
  3995. that allow contextual data to be queried as it is needed.
  3996. \end_layout
  3997. \begin_layout Subsubsection*
  3998. Broadcast Intents
  3999. \end_layout
  4000. \begin_layout Standard
  4001. As mentioned above, the
  4002. \noun on
  4003. ContextAnalyserService
  4004. \noun default
  4005. fires broadcast intents on certain occasions, namely:
  4006. \end_layout
  4007. \begin_layout Itemize
  4008. whenever the (aggregated) activity changes
  4009. \end_layout
  4010. \begin_layout Itemize
  4011. whenever the place associated with the user's location changes
  4012. \end_layout
  4013. \begin_layout Itemize
  4014. whenever predictions are calculated
  4015. \end_layout
  4016. \begin_layout Standard
  4017. Third-party applications create
  4018. \noun on
  4019. BroadcastReceivers
  4020. \noun default
  4021. which can receive these intents.
  4022. \noun on
  4023. BroadcastReceivers
  4024. \noun default
  4025. can be registered in code or in the application's manifest file; in the
  4026. latter case, their creation and maintenance is handled by the OS itself,
  4027. so there is very little overhead in terms of memory or CPU usage for the
  4028. application.
  4029. Each of the broadcast intents include relevant data such as the new activity,
  4030. new place ID, or most likely predicted destination.
  4031. This allows applications to implement a lightweight receiver which is able
  4032. to check conditions and launch a service or activity in response to the
  4033. user's context.
  4034. \end_layout
  4035. \begin_layout Subsubsection*
  4036. Content providers
  4037. \end_layout
  4038. \begin_layout Standard
  4039. For applications which need more detailed information, or wish to poll the
  4040. current state instead of receiving it asynchronously, the
  4041. \noun on
  4042. ContextAnalyser
  4043. \noun default
  4044. defines a set of Android content providers.
  4045. An activity or service can query a content provider by simply providing
  4046. its URI, and optionally a projection, selection, and custom ordering.
  4047. In return, it receives a Cursor object which can be used to iterate over
  4048. and retrieve all the results of the query.
  4049. Content providers are used extensively by the Android OS, for example for
  4050. accessing contacts, e-mail and SMS messages.
  4051. \end_layout
  4052. \begin_layout Standard
  4053. Two content providers - journeys and places - simply pass queries directly
  4054. on to the backend database, which retrieves data from (or modifies data
  4055. in) the journey, journeysteps and locations tables.
  4056. This is extremely simple to implement as the Android
  4057. \noun on
  4058. SQLiteDatabase
  4059. \noun default
  4060. class has a query method with the same signature as that implemented by
  4061. content providers.
  4062. \end_layout
  4063. \begin_layout Standard
  4064. A further two content providers - activities and predictions - are backed
  4065. by data retrieved from the
  4066. \noun on
  4067. ContextAnalyserService
  4068. \noun default
  4069. via its bindable interface, as discussed previously.
  4070. The retrieved data is added to a
  4071. \noun on
  4072. MatrixCursor
  4073. \noun default
  4074. and returned to the caller.
  4075. These two providers, at present, do not allow the caller to specify a projectio
  4076. n, selection arguments, or an ordering.
  4077. These parameters are all biased towards a SQL-like model, and there is
  4078. no simple way to apply them to a
  4079. \noun on
  4080. MatrixCursor.
  4081. \noun default
  4082. Some built-in Android content providers, such as the
  4083. \noun on
  4084. gmail-ls
  4085. \noun default
  4086. provider which facilitates access to the user's gmail account, also do
  4087. not implement projection, selection or ordering; this suggests that in
  4088. situations where the provider is not backed by a SQLite database, it is
  4089. acceptable to just ignore these parameters.
  4090. Of course, they would be more useful if the parameters were respected,
  4091. so the implementation may be reconsidered in the future.
  4092. \end_layout
  4093. \begin_layout Subsubsection*
  4094. API class
  4095. \end_layout
  4096. \begin_layout Standard
  4097. In order to use receive intents or use content providers, developers need
  4098. to know the URIs and key names data structures involved.
  4099. These are published in the developer documentation (
  4100. \begin_inset CommandInset ref
  4101. LatexCommand prettyref
  4102. reference "sec:Developer-Guide"
  4103. \end_inset
  4104. ), and an optional lightweight
  4105. \begin_inset Quotes eld
  4106. \end_inset
  4107. API
  4108. \begin_inset Quotes erd
  4109. \end_inset
  4110. is also provided to save developers having to hard code common String and
  4111. URI values.
  4112. This API, as discussed in the developer guide, consists of a set of nested
  4113. public classes with public String and URI constants.
  4114. Developers simply drop a single JAR archive or a single JAVA source file
  4115. into their projects, and they can then access constants for the content
  4116. provider URIs, column names for each exposed content provider, and intent
  4117. names and metadata for broadcast intents.
  4118. \end_layout
  4119. \begin_layout Subsubsection*
  4120. Permissions
  4121. \end_layout
  4122. \begin_layout Standard
  4123. In order for the Context Analyser function, it has to ask the user for the
  4124. relevant
  4125. \emph on
  4126. permissions
  4127. \emph default
  4128. to use the accelerometers, access their location, and keep the device awake.
  4129. All of these permissions are classed as
  4130. \begin_inset Quotes eld
  4131. \end_inset
  4132. dangerous
  4133. \begin_inset Quotes erd
  4134. \end_inset
  4135. and are flagged to the user when they install the application.
  4136. The Android OS enforces access control based on permissions, and will cause
  4137. runtime exceptions to be thrown if applications attempt to access a resource
  4138. they do not have access to.
  4139. \end_layout
  4140. \begin_layout Standard
  4141. In order to protect users' privacy, the Context Analyser defines its own
  4142. set of permissions which third-party applications must request in order
  4143. to retrieve context information.
  4144. These permissions are all designated
  4145. \begin_inset Quotes eld
  4146. \end_inset
  4147. dangerous
  4148. \begin_inset Quotes erd
  4149. \end_inset
  4150. so that users will be aware of the information that applications are requesting.
  4151. Without these permissions, the Context Analyser would open up a loophole
  4152. whereby applications could retrieve location information from the Context
  4153. API that they didn't have permission to access directly through the OS.
  4154. The Android OS makes it extremely simple to enforce these permissions -
  4155. in most cases a single tag is added in the application's manifest file,
  4156. or a single method is invoked in code, and the OS handles everything else.
  4157. \end_layout
  4158. \begin_layout Standard
  4159. One extra permission was also created which is requested by the Context
  4160. Analyser itself.
  4161. This permission is called
  4162. \begin_inset Quotes eld
  4163. \end_inset
  4164. BROADCAST
  4165. \begin_inset Quotes erd
  4166. \end_inset
  4167. and is used to ensure data integrity for third party applications.
  4168. Applications are encouraged to check for the
  4169. \begin_inset Quotes eld
  4170. \end_inset
  4171. BROADCAST
  4172. \begin_inset Quotes erd
  4173. \end_inset
  4174. permission when receiving broadcast intents (and again, the Android OS
  4175. makes this as simple as adding a tag to an element in the manifest file)
  4176. in order to ensure that the broadcasts came from a source that the user
  4177. trusts to make them.
  4178. This prevents malicious third-party applications broadcasting erroneous
  4179. data, or broadcasting high volumes of data, to negatively impact context-aware
  4180. applications.
  4181. \end_layout
  4182. \begin_layout Section
  4183. Places application
  4184. \end_layout
  4185. \begin_layout Standard
  4186. The
  4187. \begin_inset Quotes eld
  4188. \end_inset
  4189. places
  4190. \begin_inset Quotes erd
  4191. \end_inset
  4192. application consists of a single activity which shows an Android
  4193. \noun on
  4194. MapView
  4195. \noun default
  4196. , with two custom overlay layers.
  4197. One layer renders a star at the latitude/longitude of each place known
  4198. to the
  4199. \noun on
  4200. Context Analyser
  4201. \noun default
  4202. , while the second layer renders red lines between places that are connected
  4203. by journeys.
  4204. The thickness of the line is proportionate to the number of times the journey
  4205. has been undertaken.
  4206. \end_layout
  4207. \begin_layout Standard
  4208. The application retrieves its data from two of the Context Analyser's content
  4209. providers.
  4210. For each location returned by the places content provider, the application
  4211. creates a new
  4212. \noun on
  4213. OverlayItem
  4214. \noun default
  4215. containing the latitude/longitude, name, and a summary of the statistics
  4216. associated with the place.
  4217. The corresponding overlay shows a new
  4218. \emph on
  4219. toast
  4220. \emph default
  4221. containing the name and statistics when the user clicks on or near the
  4222. overlay item (see
  4223. \begin_inset CommandInset ref
  4224. LatexCommand prettyref
  4225. reference "fig:Place-details"
  4226. \end_inset
  4227. ).
  4228. \end_layout
  4229. \begin_layout Standard
  4230. The journeys overlay constructs a 2-dimensional map of
  4231. \noun on
  4232. OverlayItems
  4233. \noun default
  4234. to
  4235. \noun on
  4236. OverlayItems
  4237. \noun default
  4238. to the number of times that journey has been performed (i.e.,
  4239. \noun on
  4240. Map<OverlayItem, Map<OverlayItem, Integer>>
  4241. \noun default
  4242. ).
  4243. It is passed a list of items created based on the places content provider,
  4244. and then retrieves all known journeys from the journeys content provider
  4245. and uses them to build the map.
  4246. Journeys are normalised so that the ID of the start point is always less
  4247. than the ID of the end point as the overlay is not concerned with direction.
  4248. \end_layout
  4249. \begin_layout Standard
  4250. As each
  4251. \noun on
  4252. OverlayItem
  4253. \noun default
  4254. holds the latitude and longitude of the point, it is therefore trivial
  4255. to iterate over each pair of items, request the
  4256. \noun on
  4257. MapView
  4258. \noun default
  4259. translate the latitude/longitude into screen co-ordinates, and render a
  4260. line between the two points.
  4261. The line width is set such that the most traveled journey is 10 pixels
  4262. wide, and all other journeys are scaled in proportion.
  4263. \end_layout
  4264. \begin_layout Section
  4265. Locale plugin
  4266. \end_layout
  4267. \begin_layout Standard
  4268. The locale plugin is a lightweight application which connects the
  4269. \noun on
  4270. Context Analyser
  4271. \noun default
  4272. to the third-party
  4273. \noun on
  4274. Locale
  4275. \noun default
  4276. software, which is designed to allow users to change settings of their
  4277. device automatically when certain
  4278. \begin_inset Quotes eld
  4279. \end_inset
  4280. situations
  4281. \begin_inset Quotes erd
  4282. \end_inset
  4283. are encountered.
  4284. By default, situations can include location, time, battery power, orientation
  4285. and contact information.
  4286. Many additional plugins are available on the Android Market to augment
  4287. these conditions.
  4288. The plugin for the Context Analyser allows users to add conditions for
  4289. their current activity and (most likely) predicted destination.
  4290. \end_layout
  4291. \begin_layout Standard
  4292. In order to show new conditions in
  4293. \noun on
  4294. Locale
  4295. \noun default
  4296. , the plugin simply has to define an activity which can handle a certain
  4297. predefined intent.
  4298. One such activity is created for each condition, and they simply provide
  4299. a lightweight user interface to allow the user to select the options for
  4300. the condition.
  4301. The activity for selecting a destination, for example, queries the places
  4302. content provider and displays the result in a combobox.
  4303. The user then selects the desired place, and either presses their back
  4304. button, or presses menu and taps
  4305. \begin_inset Quotes eld
  4306. \end_inset
  4307. Save
  4308. \begin_inset Quotes erd
  4309. \end_inset
  4310. (this is a slightly odd user interface, but it is a standard amongst
  4311. \noun on
  4312. Locale
  4313. \noun default
  4314. plugins and highly recommended by the
  4315. \noun on
  4316. Locale
  4317. \noun default
  4318. developers).
  4319. \end_layout
  4320. \begin_layout Standard
  4321. A broadcast receiver is then created which responds to queries from
  4322. \noun on
  4323. Locale.
  4324. \noun default
  4325. It does this by querying the prediction and activity content providers,
  4326. and comparing the values they return with the values previously supplied
  4327. for the condition by the user (these are stored in an Intent's
  4328. \emph on
  4329. extra
  4330. \emph default
  4331. fields, which are provided to the receiver by
  4332. \noun on
  4333. Locale
  4334. \noun default
  4335. ).
  4336. It then sets a result code to indicate whether or not the situation is
  4337. satisfied at present
  4338. \end_layout
  4339. \begin_layout Standard
  4340. The broadcast receiver also listens for intents from the content analyser,
  4341. and sends a special intent to
  4342. \noun on
  4343. Locale
  4344. \noun default
  4345. to suggest that it should requery the plugin.
  4346. This allows
  4347. \noun on
  4348. Locale
  4349. \noun default
  4350. to be aware of when conditions change, and adjust its schedule appropriately.
  4351. This workflow also allows
  4352. \noun on
  4353. Locale
  4354. \noun default
  4355. to govern how often the conditions are queried, which allows it to reduce
  4356. the impact on battery life.
  4357. \end_layout
  4358. \begin_layout Section
  4359. Context-aware Home Screen
  4360. \end_layout
  4361. \begin_layout Standard
  4362. The context-aware home screen took a substantial amount of development time.
  4363. It is a replacement for the stock Android 'home' screen which not only
  4364. gives the user access to their applications and contacts, but displays
  4365. recent e-mails, text messages, upcoming appointments and missed calls.
  4366. In addition to this, it learns and adapts to the user's behaviour in a
  4367. context-sensitive fashion.
  4368. \end_layout
  4369. \begin_layout Standard
  4370. The context-aware home screen consists of a set of
  4371. \begin_inset Quotes eld
  4372. \end_inset
  4373. modules
  4374. \begin_inset Quotes erd
  4375. \end_inset
  4376. which each take up a small portion of the screen real estate.
  4377. Each module displays one or more actionable items, such as a set of application
  4378. shortcuts, an e-mail message, or a missed call.
  4379. The home screen supports a number of
  4380. \begin_inset Quotes eld
  4381. \end_inset
  4382. fixed
  4383. \begin_inset Quotes erd
  4384. \end_inset
  4385. modules which are displayed at the top of the screen, and a set of other
  4386. modules which are displayed below and may be scrolled vertically.
  4387. This allows important or frequently used modules such as application shortcuts
  4388. to be visible regardless of the other information displayed.
  4389. \end_layout
  4390. \begin_layout Standard
  4391. Each module is expected to tailor its behaviour to the user's current context,
  4392. either by ordering its contents appropriately, or selectively displaying
  4393. the most relevant content.
  4394. For example, the application shortcut module will order the shortcuts by
  4395. those it anticipates will be most likely to be used in the present context,
  4396. whereas an e-mail module will chose to display the e-mail messages most
  4397. likely to be read.
  4398. In addition, modules which aren't fixed are ordered by the home screen
  4399. according to the context and previous history.
  4400. \end_layout
  4401. \begin_layout Standard
  4402. The current context is represented as a set of tuples of context type and
  4403. value.
  4404. For example, a complete description of a context may be:
  4405. \end_layout
  4406. \begin_layout LyX-Code
  4407. (location,1),
  4408. \end_layout
  4409. \begin_layout LyX-Code
  4410. (destination,2),
  4411. \end_layout
  4412. \begin_layout LyX-Code
  4413. (activity,CLASSIFIED/WALKING),
  4414. \end_layout
  4415. \begin_layout LyX-Code
  4416. (day,Monday),
  4417. \end_layout
  4418. \begin_layout LyX-Code
  4419. (hour,14),
  4420. \end_layout
  4421. \begin_layout LyX-Code
  4422. (period,Afternoon)
  4423. \end_layout
  4424. \begin_layout Standard
  4425. When the user performs an action, a tuple consisting of the module name
  4426. and a type and identifier for the action is created.
  4427. It is then recorded against each tuple in the current context; so if the
  4428. user tapped an e-mail with the label
  4429. \begin_inset Quotes eld
  4430. \end_inset
  4431. work
  4432. \begin_inset Quotes erd
  4433. \end_inset
  4434. in the above context, some of the generated tuples would be:
  4435. \end_layout
  4436. \begin_layout LyX-Code
  4437. (email,label,work,location,1),
  4438. \end_layout
  4439. \begin_layout LyX-Code
  4440. (email,label,work,destination,2),
  4441. \end_layout
  4442. \begin_layout LyX-Code
  4443. (email,label,work,activity,CLASSIFIED/WALKING),
  4444. \end_layout
  4445. \begin_layout LyX-Code
  4446. ...
  4447. \end_layout
  4448. \begin_layout LyX-Code
  4449. (email,label,work,period,Afternoon)
  4450. \end_layout
  4451. \begin_layout Standard
  4452. Such an event would also cause similar data to be logged for the sender
  4453. of the e-mail and the read state.
  4454. A helper class is provided by the home screen activity to each module to
  4455. facilitate storing and querying of such tuples.
  4456. On the database level, each tuple is associated with a
  4457. \emph on
  4458. count
  4459. \emph default
  4460. - the number of times it has been generated by an event.
  4461. \end_layout
  4462. \begin_layout Standard
  4463. When a module is deciding how to arrange or select its contents, it queries
  4464. for all tuples which match the current context.
  4465. It can then sum the number of times each action occurred in a related context,
  4466. and use this score in its selection or ordering algorithm.
  4467. The same algorithm is applied to the ordering of modules on the home screen
  4468. itself - each interaction is recorded as a tuple of
  4469. \noun on
  4470. (homescreen, activity, <module>).
  4471. \end_layout
  4472. \begin_layout Standard
  4473. Some actions the user performs may be universal, rather than tied to a specific
  4474. context.
  4475. For example, a user is more likely to tap on an
  4476. \emph on
  4477. unread
  4478. \emph default
  4479. e-mail to read it than to tap an e-mail they've already seen.
  4480. To compensate for this fact, a special context provider was introduced
  4481. which constantly provides the tuple
  4482. \noun on
  4483. (global, true).
  4484. \noun default
  4485. This allows modules to seamlessly incorporate the total number of times
  4486. an action was performed into their algorithms.
  4487. \end_layout
  4488. \begin_layout Standard
  4489. \begin_inset Newpage pagebreak
  4490. \end_inset
  4491. \end_layout
  4492. \begin_layout Part
  4493. \begin_inset CommandInset label
  4494. LatexCommand label
  4495. name "par:Evaluation"
  4496. \end_inset
  4497. Evaluation
  4498. \end_layout
  4499. \begin_layout Standard
  4500. This section contains exerts from the project specification and an evaluation
  4501. of how well the goals were met.
  4502. \end_layout
  4503. \begin_layout Section
  4504. Activity classification
  4505. \end_layout
  4506. \begin_layout Quote
  4507. The classifier should be able to classify the following activities: walking,
  4508. running, standing, sitting, traveling in a vehicle.
  4509. ...
  4510. It is expected that the classifier should correctly classify all activities
  4511. with an accuracy of at least 70%, within 30 seconds of the activity being
  4512. started.
  4513. \end_layout
  4514. \begin_layout Standard
  4515. The activity inference component of the context analyser is able to uniquely
  4516. identify all of the activities stated in the specification, with the exception
  4517. of running.
  4518. In addition, it can distinguish between traveling by car and bus, and walking
  4519. up or down stairs.
  4520. Of over 1,000 data samples submitted by users, not a single one was described
  4521. as
  4522. \begin_inset Quotes eld
  4523. \end_inset
  4524. running
  4525. \begin_inset Quotes erd
  4526. \end_inset
  4527. , which suggests that the omission has not negatively impacted the project
  4528. in any way.
  4529. \end_layout
  4530. \begin_layout Standard
  4531. The accuracy of the classifier when presented with supported activities
  4532. is over 75% (see
  4533. \begin_inset CommandInset ref
  4534. LatexCommand prettyref
  4535. reference "sub:Market-and-user"
  4536. \end_inset
  4537. ).
  4538. This was all accomplished by using just two features extracted from two
  4539. axes of the accelerometer; typical research applications that achieve similar
  4540. accuracies often use hundreds of features and combine many different sensors.
  4541. \end_layout
  4542. \begin_layout Standard
  4543. The timescale for activity detection was consciously expanded during this
  4544. project.
  4545. To conserve battery life, polling was reduced to once a minute, and the
  4546. aggregation of results adds a further delay to activities being classified.
  4547. Brief tests with the context analyser suggest that activities take 2-3
  4548. minutes to be correctly identified.
  4549. The change in timescale reflects a shift in aims from enabling applications
  4550. to respond instantaneously to user activity (of which there are few genuine
  4551. use cases) to facilitating a less obvious background enhancement of application
  4552. s, as seen in the context home screen application.
  4553. \end_layout
  4554. \begin_layout Section
  4555. Experimentation
  4556. \end_layout
  4557. \begin_layout Quote
  4558. The results of the experimentation described should be written up as a report.
  4559. The reports must include the data collected in each of the experiments,
  4560. the conclusions drawn from those, and the impact of the results of the
  4561. experiment on the project deliverables.
  4562. \end_layout
  4563. \begin_layout Standard
  4564. Several experiments were performed as part of the project.
  4565. These include investigating Bluetooth ubiquity (
  4566. \begin_inset CommandInset ref
  4567. LatexCommand prettyref
  4568. reference "sec:Bluetooth-1"
  4569. \end_inset
  4570. ) and methods of determining whether or not a device is indoors (
  4571. \begin_inset CommandInset ref
  4572. LatexCommand prettyref
  4573. reference "sec:Use-of-GPS/GSM"
  4574. \end_inset
  4575. ).
  4576. Consideration was also given to the use of data from a camera input (
  4577. \begin_inset CommandInset ref
  4578. LatexCommand prettyref
  4579. reference "sec:Camera"
  4580. \end_inset
  4581. ), and functioning code was developed to use a Microphone input (
  4582. \begin_inset CommandInset ref
  4583. LatexCommand prettyref
  4584. reference "sec:Microphone"
  4585. \end_inset
  4586. ).
  4587. \end_layout
  4588. \begin_layout Standard
  4589. Ultimately, none of these experiments contributed positively to the end
  4590. product.
  4591. The experimentation did, however, save development time which would have
  4592. been spent on features that would probably have not helped the project.
  4593. The lack of positive results, while acceptable according to the specification,
  4594. suggests that other areas should have been considered or alternative approaches
  4595. attempted.
  4596. Some possibilities for these are discussed in
  4597. \begin_inset CommandInset ref
  4598. LatexCommand prettyref
  4599. reference "sec:Future-work"
  4600. \end_inset
  4601. .
  4602. \end_layout
  4603. \begin_layout Section
  4604. Deliverables
  4605. \end_layout
  4606. \begin_layout Quote
  4607. The following items should be delivered: ...
  4608. Context-aware Framework, ...
  4609. Activity condition for Locale, ...
  4610. Context-aware home screen.
  4611. \end_layout
  4612. \begin_layout Standard
  4613. A total of four (final) applications were delivered, along with two applications
  4614. used during the development process.
  4615. All three applications required by the specification were successfully
  4616. implemented, along with the
  4617. \begin_inset Quotes eld
  4618. \end_inset
  4619. Places
  4620. \begin_inset Quotes erd
  4621. \end_inset
  4622. application which exposes some functionality of the context API which would
  4623. otherwise be hidden from the user.
  4624. \end_layout
  4625. \begin_layout Quote
  4626. The application should provide two different interfaces to retrieve the
  4627. user's context.
  4628. The first should be an implementation of the Android ContentProvider interface.
  4629. The second interface should use Android broadcast Intents to notify any
  4630. interested application whenever the user's activity changes.
  4631. \end_layout
  4632. \begin_layout Standard
  4633. The API provided by the Context Analyser exposes a total of four content
  4634. providers, and makes use of three different broadcast intents.
  4635. These are employed by the Places application, Locale plugin, and context
  4636. home screen.
  4637. The two methods compliment each other and facilitate two different methods
  4638. of interfacing very well.
  4639. \end_layout
  4640. \begin_layout Section
  4641. Testing
  4642. \end_layout
  4643. \begin_layout Quote
  4644. Throughout the development of the project, unit tests should be created
  4645. to test key functionality of all applications.
  4646. It is expected that at the completion of the project, all unit tests should
  4647. pass successfully, and they will have a code coverage of 80% or above.
  4648. \end_layout
  4649. \begin_layout Standard
  4650. While unit tests were employed throughout the project, the emphasis was
  4651. on testing small parts of complex or potentially unstable code, and code
  4652. which was not easily covered by systems tests.
  4653. Tests were split between those ran on a standard JVM from the development
  4654. environment, and those that needed to be ran on the device itself with
  4655. an Android-specific test harness.
  4656. While no figure for code coverage is available due to this split, and due
  4657. to lack of coverage tools for the latter type of tests, it is expected
  4658. that the figure would be well below 80% line coverage.
  4659. \end_layout
  4660. \begin_layout Standard
  4661. This represents a failure to adhere to Test-Driven Development (TDD) as
  4662. originally intended (but not documented).
  4663. This involves writing unit tests as a form of
  4664. \begin_inset Quotes eld
  4665. \end_inset
  4666. specification
  4667. \begin_inset Quotes erd
  4668. \end_inset
  4669. before implementing the unit itself.
  4670. With this project, however, a lot of code started out as small
  4671. \begin_inset Quotes eld
  4672. \end_inset
  4673. experiments
  4674. \begin_inset Quotes erd
  4675. \end_inset
  4676. to determine whether or not something would work, or the exact output of
  4677. some built-in functionality; it then evolved into a full implementation,
  4678. and adding unit tests after the fact was not considered a high priority
  4679. for most code.
  4680. \end_layout
  4681. \begin_layout Quote
  4682. The classifier application should also have a suite of system tests.
  4683. These should consist of a set of fake or pre-recorded inputs which are
  4684. fed into the application in place of raw sensor data.
  4685. The output of the classifier can then be compared to expected output for
  4686. the data.
  4687. \end_layout
  4688. \begin_layout Standard
  4689. The input sources for the framework are all located behind factory classes.
  4690. These classes are able to switch out the real information for a stubbed
  4691. version which simulates the data being received; this is automatically
  4692. done if the application is ran on the Android Emulator, which does not
  4693. emulate sensor inputs of any kind.
  4694. The stubbed classes allow for easy testing of the context framework and
  4695. the applications that use it, which makes for verification of the whole
  4696. system extremely easy.
  4697. \end_layout
  4698. \begin_layout Section
  4699. User testing and feedback
  4700. \end_layout
  4701. \begin_layout Quote
  4702. The Locale addon and context-aware home screen should be subject to user
  4703. acceptance testing for evaluation.
  4704. This should take the form of providing the applications to multiple end
  4705. users, allowing them to use them for a period of time (providing instructions
  4706. for certain tasks to complete).
  4707. The users should then be presented with a questionnaire which they can
  4708. use to evaluate the functionality, utility and design of the applications.
  4709. ...
  4710. In addition to providing the applications to a closed set of users, the
  4711. applications should be published to the Android market.
  4712. \end_layout
  4713. \begin_layout Standard
  4714. All four
  4715. \noun on
  4716. Context Analyser
  4717. \noun default
  4718. applications were given to a small group of test users, along with copies
  4719. of the user manuals and developer's guide.
  4720. No questionnaires were used, but the users were asked to give feedback
  4721. and evaluate.
  4722. Both of the preliminary data gathering applications were published to the
  4723. Android Market where they received comments and ratings by users.
  4724. At the time of writing, the
  4725. \noun on
  4726. Context Analyser
  4727. \noun default
  4728. suite had not yet been published to the market.
  4729. \end_layout
  4730. \begin_layout Standard
  4731. The two test applications published to the market, which were never intended
  4732. to be particularly valuable to end users, had between 100 and 500 downloads,
  4733. and both received an average rating between 3 and 4 stars (annotated as
  4734. \begin_inset Quotes eld
  4735. \end_inset
  4736. Average
  4737. \begin_inset Quotes erd
  4738. \end_inset
  4739. and
  4740. \begin_inset Quotes eld
  4741. \end_inset
  4742. Above Average
  4743. \begin_inset Quotes erd
  4744. \end_inset
  4745. within the Market UI, respectively).
  4746. Some positive comments were left, such as the following comment regarding
  4747. the Sensor Logger application:
  4748. \end_layout
  4749. \begin_layout Quote
  4750. It works on myTouch3G but it would be better if it ran in background and
  4751. actually kept a log of what you do throughout the day.
  4752. At least it was right!
  4753. \end_layout
  4754. \begin_layout Standard
  4755. Negative feedback mostly revolved around activities which the applications
  4756. were not trained for being incorrectly classified.
  4757. As evidenced with the annotated data which was submitted, a lot of users
  4758. attempted to get the application to classify them sleeping, and were presented
  4759. with seemingly bizarre results such as
  4760. \begin_inset Quotes eld
  4761. \end_inset
  4762. Traveling by bus
  4763. \begin_inset Quotes erd
  4764. \end_inset
  4765. .
  4766. This is because one sample for traveling by bus was close to a
  4767. \begin_inset Quotes eld
  4768. \end_inset
  4769. stationary
  4770. \begin_inset Quotes erd
  4771. \end_inset
  4772. reading - a vertical acceleration of 9.8m/s, no horizontal acceleration,
  4773. and little variance.
  4774. \end_layout
  4775. \begin_layout Standard
  4776. Methods to correct or detect this type of erroneous result would have given
  4777. a much better user experience, and reduced the small amount of negative
  4778. feedback received, but no such methods were attempted during this project.
  4779. This was because early testing ignored activities which the classifier
  4780. did not know of, and realisation of the scope of the problem came too late
  4781. into the project to make the changes necessary.
  4782. Some ideas for combating this problem are presented in
  4783. \begin_inset CommandInset ref
  4784. LatexCommand prettyref
  4785. reference "sec:Future-work"
  4786. \end_inset
  4787. .
  4788. \end_layout
  4789. \begin_layout Standard
  4790. \begin_inset Note Note
  4791. status open
  4792. \begin_layout Plain Layout
  4793. Resource usage
  4794. \end_layout
  4795. \end_inset
  4796. \end_layout
  4797. \begin_layout Standard
  4798. \begin_inset Newpage pagebreak
  4799. \end_inset
  4800. \end_layout
  4801. \begin_layout Part
  4802. \begin_inset CommandInset label
  4803. LatexCommand label
  4804. name "par:Conclusion"
  4805. \end_inset
  4806. Conclusion
  4807. \end_layout
  4808. \begin_layout Section
  4809. Project outcomes
  4810. \end_layout
  4811. \begin_layout Standard
  4812. A context-aware API has been developed for the Android platform.
  4813. This was the primary purpose and output of this project, and it has been
  4814. evaluated to perform to an acceptable accuracy.
  4815. While not all of the evaluation targets were met, a number of these were
  4816. conscious decisions to deviate from the previous specification in response
  4817. to a change in development method or change in target audience.
  4818. \end_layout
  4819. \begin_layout Standard
  4820. In developing the API, an algorithm to classify accelerometer data using
  4821. an extremely small set of extracted features was devised.
  4822. This is a significant deviation from established works in the field, which
  4823. mostly attempt to use as many features as possible in an attempt to increase
  4824. accuracy.
  4825. \end_layout
  4826. \begin_layout Standard
  4827. In addition to the main API, the project has also delivered a set of application
  4828. s built on top of it, most notably the context aware home screen.
  4829. This clearly demonstrates how context-aware systems can enhance a user's
  4830. experience by tailoring content and behaviour to the current context.
  4831. \end_layout
  4832. \begin_layout Section
  4833. Future work
  4834. \begin_inset CommandInset label
  4835. LatexCommand label
  4836. name "sec:Future-work"
  4837. \end_inset
  4838. \end_layout
  4839. \begin_layout Standard
  4840. There are many areas in this project which could be expanded on or enhanced
  4841. in some way.
  4842. Some of these are discussed below.
  4843. \end_layout
  4844. \begin_layout Subsection
  4845. Using GSM metadata to enhance activity classification
  4846. \end_layout
  4847. \begin_layout Standard
  4848. While experiments with using GSM and GPS signal strength to determine interestin
  4849. g locations were unsuccessful, there is a possibility that some GSM data
  4850. can be used in order to augment the existing activity classification system.
  4851. In order to promptly hand off communications to alternative cell sites
  4852. when the user moves around, all mobile telephones track the cell IDs and
  4853. signal strengths of their
  4854. \emph on
  4855. neighbouring
  4856. \emph default
  4857. cell towers as well as the current one.
  4858. \end_layout
  4859. \begin_layout Standard
  4860. It is possible that measuring the rate of change in either the strength
  4861. of neighbouring cell towers, or indeed the change in cell towers themselves,
  4862. could be used to infer the approximate speed the user is traveling at.
  4863. While this could be a piece of standalone contextual information, it would
  4864. be possible to integrate this with the activity inference system to help
  4865. reduce incorrect results.
  4866. \end_layout
  4867. \begin_layout Standard
  4868. As discussed earlier, a large percentage of incorrectly classified samples
  4869. involved the user sitting down and being misclassified as being in a vehicle.
  4870. A simple decision tree could be implemented that biased the activity inference
  4871. algorithm to favour the
  4872. \begin_inset Quotes eld
  4873. \end_inset
  4874. sitting
  4875. \begin_inset Quotes erd
  4876. \end_inset
  4877. classification over vehicle-based ones if the user was not moving at speed.
  4878. This has the potential to increase accuracy to the region of 90%.
  4879. \end_layout
  4880. \begin_layout Subsection
  4881. Automatic classification of places
  4882. \end_layout
  4883. \begin_layout Standard
  4884. While the context analyser correctly identifies interesting places, it would
  4885. be useful to know what type of place they were.
  4886. \begin_inset Quotes eld
  4887. \end_inset
  4888. Home
  4889. \begin_inset Quotes erd
  4890. \end_inset
  4891. and
  4892. \begin_inset Quotes eld
  4893. \end_inset
  4894. Work
  4895. \begin_inset Quotes erd
  4896. \end_inset
  4897. could potentially be inferred by the times of day spent at each location;
  4898. interchanges could be identified by the duration of visits and the activity
  4899. involved in getting to and from the location, etc.
  4900. \end_layout
  4901. \begin_layout Standard
  4902. This would enhance the behaviour of contextual location-aware services,
  4903. which currently have to rely on analysing the user's activity (either their
  4904. real life activity or their interactions with the phone) in order to correctly
  4905. adapt their behaviour to places.
  4906. Instead of observing that a user frequently reads e-mails at place #17,
  4907. an application could infer that as place #17 is a work place, the user
  4908. is more likely to want to read e-mail than play games.
  4909. \end_layout
  4910. \begin_layout Subsection
  4911. On-device training for new activities
  4912. \end_layout
  4913. \begin_layout Standard
  4914. Because it uses an instance-based learning algorithm, it would be very easy
  4915. to add new samples to the activity classification model on the device itself.
  4916. However, there are various challenges which would make this more difficult.
  4917. At present the model data is stored in a binary file bundled with the Context
  4918. Analyser; this means that it is not modifiable at runtime.
  4919. In order to integrate new data, it would either have to be extracted to
  4920. storage on the device and then modified, or imported into a database.
  4921. \end_layout
  4922. \begin_layout Standard
  4923. In addition, it would be hard to ensure that data entered on the device
  4924. was of a good quality.
  4925. Without a way to explore the model itself, the user has no way of finding
  4926. and correcting or deleting poor quality training samples which lead to
  4927. false classifications.
  4928. Finally, removing the developer from the update process means that new
  4929. activities have to be added by each and every user, instead of added once
  4930. by the developer and shared to all users.
  4931. Further work on this topic would have to explore ways to allow users to
  4932. add high quality data, and then ensure that data is shared appropriately.
  4933. \end_layout
  4934. \begin_layout Subsection
  4935. \begin_inset Quotes eld
  4936. \end_inset
  4937. Omniscient
  4938. \begin_inset Quotes erd
  4939. \end_inset
  4940. context home screen
  4941. \end_layout
  4942. \begin_layout Standard
  4943. The present context home screen only records what happens when the user
  4944. directly interacts with it.
  4945. Further work could expand this to make the home screen aware of all actions
  4946. that were performed on the device, and to incorporate these into the dashboard
  4947. to further improve the user experience.
  4948. \end_layout
  4949. \begin_layout Standard
  4950. An obvious example of this is monitoring outgoing phone calls, which can
  4951. be invoked from a multitude of applications without directly tapping the
  4952. contact on the home screen.
  4953. At present, the home screen sees a tap on the
  4954. \begin_inset Quotes eld
  4955. \end_inset
  4956. Dialer
  4957. \begin_inset Quotes erd
  4958. \end_inset
  4959. application (for example) and nothing else; if it monitored phone calls
  4960. and other activities it could also make the contact involved more prominent
  4961. on the home screen.
  4962. \end_layout
  4963. \begin_layout Standard
  4964. Another use would be monitoring the time spent in applications (rather than
  4965. just the number of launches), and which activities within those are accessed.
  4966. If a user repeatedly opens the market application to browse to the most
  4967. recently added games, the context home screen may be able to detect that
  4968. behaviour and automatically add a
  4969. \emph on
  4970. new
  4971. \emph default
  4972. shortcut which performs this action automatically for them.
  4973. Work would need to be done in order to determine whether or not this was
  4974. possible in a general case for any application.
  4975. \end_layout
  4976. \begin_layout Standard
  4977. \begin_inset Newpage pagebreak
  4978. \end_inset
  4979. \end_layout
  4980. \begin_layout Part
  4981. Appendices
  4982. \end_layout
  4983. \begin_layout Section
  4984. \start_of_appendix
  4985. User Guide - Context Analyser
  4986. \end_layout
  4987. \begin_layout Standard
  4988. Welcome to the
  4989. \noun on
  4990. Context Analyser
  4991. \noun default
  4992. .
  4993. This application analyses your
  4994. \emph on
  4995. context
  4996. \emph default
  4997. as you carry your phone around with you performing day-to-day activities.
  4998. Other applications can query your context information and enhance their
  4999. behaviour so that they're more relevant to what you're doing.
  5000. \end_layout
  5001. \begin_layout Standard
  5002. The context analyser currently provides the following context information:
  5003. \end_layout
  5004. \begin_layout Itemize
  5005. Your activity
  5006. \end_layout
  5007. \begin_layout Itemize
  5008. Your location
  5009. \end_layout
  5010. \begin_layout Itemize
  5011. Your predicted destination, if you're not at a known location
  5012. \end_layout
  5013. \begin_layout Standard
  5014. It does this by gathering data from your phone's accelerometers and location
  5015. provider.
  5016. Data is recorded for a few seconds once a minute, to preserve your battery
  5017. life.
  5018. \end_layout
  5019. \begin_layout Standard
  5020. For your 'activity', the context analyser tries to detect whether you are
  5021. walking, sitting, standing, or in a vehicle.
  5022. It can also expand on these to detect the difference between a car and
  5023. a bus, and walking normally and walking up or down stairs.
  5024. Future updates may add more activities.
  5025. \end_layout
  5026. \begin_layout Standard
  5027. For your location and destination, the context analyser deals in 'places'.
  5028. These are locations up to 500m wide where you have spent several minutes
  5029. not moving.
  5030. A place could correspond to your home, office, favourite coffee shop or
  5031. a bus stop you frequently wait at.
  5032. When you move between places, the context analyser notes which activities
  5033. it thought you were performing, and stores these as a 'journey' which links
  5034. the two places.
  5035. When you next set off from one of these, it can compare your activities
  5036. and see if it can guess where you're heading.
  5037. \end_layout
  5038. \begin_layout Standard
  5039. There is very little you can do with the context analyser on its own.
  5040. It's built as a tool for other applications to hook into.
  5041. \begin_inset Float figure
  5042. wide false
  5043. sideways false
  5044. status collapsed
  5045. \begin_layout Plain Layout
  5046. \begin_inset Graphics
  5047. filename contextanalyser-featured.png
  5048. \end_inset
  5049. \end_layout
  5050. \begin_layout Plain Layout
  5051. \begin_inset Caption
  5052. \begin_layout Plain Layout
  5053. Featured applications
  5054. \begin_inset CommandInset label
  5055. LatexCommand label
  5056. name "fig:Featured-applications"
  5057. \end_inset
  5058. \end_layout
  5059. \end_inset
  5060. \end_layout
  5061. \end_inset
  5062. You can see some of these featured applications listed when you open the
  5063. context analyser (see
  5064. \begin_inset CommandInset ref
  5065. LatexCommand prettyref
  5066. reference "fig:Featured-applications"
  5067. \end_inset
  5068. ) .
  5069. Simply click on one of them and the Android market will open for you to
  5070. view or install your chosen app.
  5071. \end_layout
  5072. \begin_layout Standard
  5073. \begin_inset Float figure
  5074. wide false
  5075. sideways false
  5076. status collapsed
  5077. \begin_layout Plain Layout
  5078. \begin_inset Graphics
  5079. filename contextanalyser-menu.png
  5080. \end_inset
  5081. \begin_inset Caption
  5082. \begin_layout Plain Layout
  5083. Disable service button
  5084. \begin_inset CommandInset label
  5085. LatexCommand label
  5086. name "fig:Disable-service-button"
  5087. \end_inset
  5088. \end_layout
  5089. \end_inset
  5090. \end_layout
  5091. \end_inset
  5092. The context analyser will run a background service as soon as you open the
  5093. application, or whenever another application requests data from it.
  5094. If you wish to disable the background service (which will stop the context
  5095. analyser from detecting places or determining your activity), press the
  5096. \noun on
  5097. menu
  5098. \noun default
  5099. button and select the
  5100. \noun on
  5101. Disable service
  5102. \noun default
  5103. option (see
  5104. \begin_inset CommandInset ref
  5105. LatexCommand prettyref
  5106. reference "fig:Disable-service-button"
  5107. \end_inset
  5108. ).
  5109. The background service will not run until you repeat the procedure and
  5110. select
  5111. \noun on
  5112. Enable service
  5113. \noun default
  5114. .
  5115. \begin_inset Newpage pagebreak
  5116. \end_inset
  5117. \end_layout
  5118. \begin_layout Section
  5119. User Guide - Places
  5120. \end_layout
  5121. \begin_layout Standard
  5122. The
  5123. \noun on
  5124. places
  5125. \noun default
  5126. application shows you all of the places detected by the
  5127. \noun on
  5128. Context Analyser
  5129. \noun default
  5130. , and the journeys you make in between them.
  5131. The
  5132. \noun on
  5133. Context Analyser
  5134. \noun default
  5135. is a tool which tries to determine your current activity and location,
  5136. and your destination if you're on the move.
  5137. If you don't have the
  5138. \noun on
  5139. Context Analyser
  5140. \noun default
  5141. installed, you'll be prompted to install it from the market.
  5142. \end_layout
  5143. \begin_layout Standard
  5144. \begin_inset Float figure
  5145. wide false
  5146. sideways false
  5147. status collapsed
  5148. \begin_layout Plain Layout
  5149. \begin_inset Graphics
  5150. filename places-normal.png
  5151. \end_inset
  5152. \end_layout
  5153. \begin_layout Plain Layout
  5154. \begin_inset Caption
  5155. \begin_layout Plain Layout
  5156. Places application
  5157. \begin_inset CommandInset label
  5158. LatexCommand label
  5159. name "fig:Places-application"
  5160. \end_inset
  5161. \end_layout
  5162. \end_inset
  5163. \end_layout
  5164. \begin_layout Plain Layout
  5165. \end_layout
  5166. \end_inset
  5167. The places application displays a map and marks each detected place with
  5168. an orange star.
  5169. Places you've traveled between are connected with a red line - the thicker
  5170. the line, the more frequently you make that journey.
  5171. In
  5172. \begin_inset CommandInset ref
  5173. LatexCommand prettyref
  5174. reference "fig:Places-application"
  5175. \end_inset
  5176. , you can see two places with a very frequently made journey between them.
  5177. \end_layout
  5178. \begin_layout Standard
  5179. You can pan the map by dragging it around with your finger, or by moving
  5180. your phone's trackball (if it has one).
  5181. To zoom in and out, tap the screen and wait two seconds and the zoom controls
  5182. will appear at the bottom of the map.
  5183. Simply tap either button to zoom in or out.
  5184. \end_layout
  5185. \begin_layout Standard
  5186. \begin_inset Float figure
  5187. wide false
  5188. sideways false
  5189. status collapsed
  5190. \begin_layout Plain Layout
  5191. \begin_inset Graphics
  5192. filename places-toast.png
  5193. \end_inset
  5194. \end_layout
  5195. \begin_layout Plain Layout
  5196. \begin_inset Caption
  5197. \begin_layout Plain Layout
  5198. Place details
  5199. \begin_inset CommandInset label
  5200. LatexCommand label
  5201. name "fig:Place-details"
  5202. \end_inset
  5203. \end_layout
  5204. \end_inset
  5205. \end_layout
  5206. \begin_layout Plain Layout
  5207. \end_layout
  5208. \end_inset
  5209. To see more information about a place, simply tap on its star.
  5210. A small
  5211. \emph on
  5212. toast
  5213. \emph default
  5214. will appear giving you the name of the place, the number of visits, and
  5215. the date and time of your last visit.
  5216. Names are determined automatically by geocoding the latitude and longitude
  5217. to a nearby place name - this could be the name of a street, a nearby landmark
  5218. or a side alley.
  5219. \begin_inset CommandInset ref
  5220. LatexCommand prettyref
  5221. reference "fig:Place-details"
  5222. \end_inset
  5223. shows the result of tapping one of the stars - the name of the place is
  5224. \begin_inset Quotes eld
  5225. \end_inset
  5226. Rose Alley
  5227. \begin_inset Quotes erd
  5228. \end_inset
  5229. , it has been visited 37 times and the last time this happened was in the
  5230. early hours of July the 10th.
  5231. \begin_inset Newpage pagebreak
  5232. \end_inset
  5233. \end_layout
  5234. \begin_layout Section
  5235. User Guide - Locale plugin
  5236. \end_layout
  5237. \begin_layout Standard
  5238. The
  5239. \noun on
  5240. Context Analyser
  5241. \noun default
  5242. plugin for
  5243. \noun on
  5244. Locale
  5245. \noun default
  5246. allows you to create
  5247. \noun on
  5248. Locale
  5249. \noun default
  5250. situations based on information provided by the
  5251. \noun on
  5252. Context Analyser
  5253. \noun default
  5254. .
  5255. \noun on
  5256. Locale
  5257. \noun default
  5258. is an application which allows you to make your phone change settings,
  5259. send tweets, or perform a variety of other actions, whenever a certain
  5260. 'situation' occurs.
  5261. A situation is just a set of conditions - such as your location, your phone's
  5262. battery life, or the current time.
  5263. The
  5264. \noun on
  5265. Context Analyser
  5266. \noun default
  5267. application automatically determines your current activity (such as 'walking'
  5268. or 'sitting down'), and your predicted destination if you're traveling.
  5269. This plugin requires that you have both
  5270. \noun on
  5271. Context Analyser
  5272. \noun default
  5273. and
  5274. \noun on
  5275. Locale
  5276. \noun default
  5277. installed.
  5278. Both are available from the Android market.
  5279. \end_layout
  5280. \begin_layout Standard
  5281. The plugin adds two new conditions which you can use in
  5282. \noun on
  5283. Locale
  5284. \noun default
  5285. situations:
  5286. \end_layout
  5287. \begin_layout Itemize
  5288. Activity - the activity you are
  5289. \emph on
  5290. most likely
  5291. \emph default
  5292. performing
  5293. \end_layout
  5294. \begin_layout Itemize
  5295. Destination - your
  5296. \emph on
  5297. most likely
  5298. \emph default
  5299. destination, if you're not at a known location
  5300. \end_layout
  5301. \begin_layout Standard
  5302. A basic overview of adding these new conditions follows.
  5303. For full documentation on how to use
  5304. \noun on
  5305. Locale
  5306. \noun default
  5307. , consult the
  5308. \noun on
  5309. Locale
  5310. \noun default
  5311. user manual.
  5312. \end_layout
  5313. \begin_layout Standard
  5314. \begin_inset Float figure
  5315. wide false
  5316. sideways false
  5317. status collapsed
  5318. \begin_layout Plain Layout
  5319. \begin_inset Graphics
  5320. filename locale-situations.png
  5321. \end_inset
  5322. \end_layout
  5323. \begin_layout Plain Layout
  5324. \begin_inset Caption
  5325. \begin_layout Plain Layout
  5326. Locale main screen
  5327. \begin_inset CommandInset label
  5328. LatexCommand label
  5329. name "fig:Locale-main-screen"
  5330. \end_inset
  5331. \end_layout
  5332. \end_inset
  5333. \end_layout
  5334. \begin_layout Plain Layout
  5335. \end_layout
  5336. \end_inset
  5337. When you open
  5338. \noun on
  5339. Locale
  5340. \noun default
  5341. , you will see a list of currently defined situations (
  5342. \begin_inset CommandInset ref
  5343. LatexCommand prettyref
  5344. reference "fig:Locale-main-screen"
  5345. \end_inset
  5346. ).
  5347. You can edit existing situations by tapping on them.
  5348. Existing situations may be deleted by clicking on the red minus button
  5349. to the right of the situation name.
  5350. Finally, new situations can be created by tapping the 'Add Situation' button
  5351. at the bottom of the screen.
  5352. \noun on
  5353. Locale
  5354. \noun default
  5355. shows any situations that are
  5356. \emph on
  5357. active
  5358. \emph default
  5359. (all the conditions currently hold true) in bold.
  5360. \end_layout
  5361. \begin_layout Standard
  5362. \begin_inset Float figure
  5363. wide false
  5364. sideways false
  5365. status collapsed
  5366. \begin_layout Plain Layout
  5367. \begin_inset Graphics
  5368. filename locale-situation-pre.png
  5369. \end_inset
  5370. \end_layout
  5371. \begin_layout Plain Layout
  5372. \begin_inset Caption
  5373. \begin_layout Plain Layout
  5374. Locale editing situation
  5375. \begin_inset CommandInset label
  5376. LatexCommand label
  5377. name "fig:Locale-editing-situation"
  5378. \end_inset
  5379. \end_layout
  5380. \end_inset
  5381. \end_layout
  5382. \begin_layout Plain Layout
  5383. \end_layout
  5384. \end_inset
  5385. \begin_inset Float figure
  5386. wide false
  5387. sideways false
  5388. status collapsed
  5389. \begin_layout Plain Layout
  5390. \begin_inset Graphics
  5391. filename locale-add-condition.png
  5392. \end_inset
  5393. \end_layout
  5394. \begin_layout Plain Layout
  5395. \begin_inset Caption
  5396. \begin_layout Plain Layout
  5397. Locale add condition popup
  5398. \begin_inset CommandInset label
  5399. LatexCommand label
  5400. name "fig:Locale-add-condition"
  5401. \end_inset
  5402. \end_layout
  5403. \end_inset
  5404. \end_layout
  5405. \begin_layout Plain Layout
  5406. \end_layout
  5407. \end_inset
  5408. Once you've selected a situation to edit, or created a brand new situation,
  5409. you will see
  5410. \noun on
  5411. Locale
  5412. \noun default
  5413. 's 'edit situation' screen (
  5414. \begin_inset CommandInset ref
  5415. LatexCommand prettyref
  5416. reference "fig:Locale-editing-situation"
  5417. \end_inset
  5418. ).
  5419. This allows you to set the name of the situation, add or edit conditions,
  5420. and add or edit settings.
  5421. The
  5422. \noun on
  5423. Context Analyser
  5424. \noun default
  5425. plugin adds two new conditions, which are shown in the list when you click
  5426. 'Add condition' (
  5427. \begin_inset CommandInset ref
  5428. LatexCommand prettyref
  5429. reference "fig:Locale-add-condition"
  5430. \end_inset
  5431. ).
  5432. Select either 'Activity' or 'Destination' to add a new condition based
  5433. on your current context.
  5434. \end_layout
  5435. \begin_layout Standard
  5436. \begin_inset Float figure
  5437. wide false
  5438. sideways false
  5439. status collapsed
  5440. \begin_layout Plain Layout
  5441. \begin_inset Graphics
  5442. filename locale-select-destination.png
  5443. \end_inset
  5444. \end_layout
  5445. \begin_layout Plain Layout
  5446. \begin_inset Caption
  5447. \begin_layout Plain Layout
  5448. Locale plugin selecting destination
  5449. \begin_inset CommandInset label
  5450. LatexCommand label
  5451. name "fig:Locale-plugin-selecting"
  5452. \end_inset
  5453. \end_layout
  5454. \end_inset
  5455. \end_layout
  5456. \begin_layout Plain Layout
  5457. \end_layout
  5458. \end_inset
  5459. \begin_inset Float figure
  5460. wide false
  5461. sideways false
  5462. status collapsed
  5463. \begin_layout Plain Layout
  5464. \begin_inset Graphics
  5465. filename locale-select-activity.png
  5466. \end_inset
  5467. \end_layout
  5468. \begin_layout Plain Layout
  5469. \begin_inset Caption
  5470. \begin_layout Plain Layout
  5471. Locale plugin selecting activity
  5472. \begin_inset CommandInset label
  5473. LatexCommand label
  5474. name "fig:Locale-plugin-selecting-activity"
  5475. \end_inset
  5476. \end_layout
  5477. \end_inset
  5478. \end_layout
  5479. \begin_layout Plain Layout
  5480. \end_layout
  5481. \end_inset
  5482. When you select one of the plugin's conditions, you will be presented with
  5483. a screen which allows you to specify which activity (see
  5484. \begin_inset CommandInset ref
  5485. LatexCommand prettyref
  5486. reference "fig:Locale-plugin-selecting-activity"
  5487. \end_inset
  5488. ) or destination (see
  5489. \begin_inset CommandInset ref
  5490. LatexCommand prettyref
  5491. reference "fig:Locale-plugin-selecting"
  5492. \end_inset
  5493. ) you wish to match.
  5494. For activities, you can select one of sitting, standing, walking, walking
  5495. up stairs, walking down stairs, dancing, traveling bar car, or traveling
  5496. by bus.
  5497. For destination, you may select any place which the
  5498. \noun on
  5499. Context Analyser
  5500. \noun default
  5501. has previously detected.
  5502. \end_layout
  5503. \begin_layout Standard
  5504. \begin_inset Float figure
  5505. wide false
  5506. sideways false
  5507. status collapsed
  5508. \begin_layout Plain Layout
  5509. \begin_inset Graphics
  5510. filename locale-menu.png
  5511. \end_inset
  5512. \end_layout
  5513. \begin_layout Plain Layout
  5514. \begin_inset Caption
  5515. \begin_layout Plain Layout
  5516. Locale condition editor menu
  5517. \begin_inset CommandInset label
  5518. LatexCommand label
  5519. name "fig:Locale-condition-editor"
  5520. \end_inset
  5521. \end_layout
  5522. \end_inset
  5523. \end_layout
  5524. \end_inset
  5525. Once you've selected your chosen activity or destination, press the
  5526. \noun on
  5527. menu
  5528. \noun default
  5529. button and select the 'Save Changes' option (see
  5530. \begin_inset CommandInset ref
  5531. LatexCommand prettyref
  5532. reference "fig:Locale-condition-editor"
  5533. \end_inset
  5534. ).
  5535. You will then return to the situation editor where the new condition will
  5536. be displayed.
  5537. You may then add settings as with any other
  5538. \noun on
  5539. Locale
  5540. \noun default
  5541. situation, and
  5542. \noun on
  5543. Locale
  5544. \noun default
  5545. will automatically apply these when all of the conditions match.
  5546. \end_layout
  5547. \begin_layout Standard
  5548. \begin_inset Newpage pagebreak
  5549. \end_inset
  5550. \end_layout
  5551. \begin_layout Section
  5552. User Guide - Context Home Screen
  5553. \end_layout
  5554. \begin_layout Standard
  5555. The
  5556. \begin_inset Quotes eld
  5557. \end_inset
  5558. context-aware home screen
  5559. \begin_inset Quotes erd
  5560. \end_inset
  5561. replaces your phone's normal home screen with an information rich dashboard
  5562. which can adapt to offer different information based on your current context.
  5563. As you use the home screen (by, for example, launching applications, opening
  5564. e-mails, etc), the home screen remembers what you were doing, when you
  5565. did it, and where you were at the time.
  5566. It then applies this information to automatically make the shortcuts or
  5567. messages it thinks you will be most interested in more prominent.
  5568. \end_layout
  5569. \begin_layout Standard
  5570. \begin_inset Float figure
  5571. wide false
  5572. sideways false
  5573. status collapsed
  5574. \begin_layout Plain Layout
  5575. \begin_inset Graphics
  5576. filename home-select.png
  5577. \end_inset
  5578. \end_layout
  5579. \begin_layout Plain Layout
  5580. \begin_inset Caption
  5581. \begin_layout Plain Layout
  5582. Home screen selection
  5583. \begin_inset CommandInset label
  5584. LatexCommand label
  5585. name "fig:Home-screen-selection"
  5586. \end_inset
  5587. \end_layout
  5588. \end_inset
  5589. \end_layout
  5590. \begin_layout Plain Layout
  5591. \end_layout
  5592. \end_inset
  5593. Once the context-aware home screen is installed, pressing the
  5594. \begin_inset Quotes eld
  5595. \end_inset
  5596. Home
  5597. \begin_inset Quotes erd
  5598. \end_inset
  5599. key or turning on your device will prompt you as to which application you
  5600. wish to provide the
  5601. \begin_inset Quotes eld
  5602. \end_inset
  5603. Home
  5604. \begin_inset Quotes erd
  5605. \end_inset
  5606. functionality, as seen in
  5607. \begin_inset CommandInset ref
  5608. LatexCommand prettyref
  5609. reference "fig:Home-screen-selection"
  5610. \end_inset
  5611. .
  5612. Select
  5613. \begin_inset Quotes eld
  5614. \end_inset
  5615. Context Home
  5616. \begin_inset Quotes erd
  5617. \end_inset
  5618. to open the context home screen.
  5619. If you want this to
  5620. \emph on
  5621. always
  5622. \emph default
  5623. open when you press home, tick the
  5624. \begin_inset Quotes eld
  5625. \end_inset
  5626. Use by default for this action
  5627. \begin_inset Quotes erd
  5628. \end_inset
  5629. checkbox at the bottom of the prompt before making your choice.
  5630. \end_layout
  5631. \begin_layout Standard
  5632. \begin_inset Float figure
  5633. wide false
  5634. sideways false
  5635. status collapsed
  5636. \begin_layout Plain Layout
  5637. \begin_inset Graphics
  5638. filename home-main.png
  5639. \end_inset
  5640. \end_layout
  5641. \begin_layout Plain Layout
  5642. \begin_inset Caption
  5643. \begin_layout Plain Layout
  5644. Context home screen
  5645. \begin_inset CommandInset label
  5646. LatexCommand label
  5647. name "fig:Context-home-screen"
  5648. \end_inset
  5649. \end_layout
  5650. \end_inset
  5651. \end_layout
  5652. \begin_layout Plain Layout
  5653. \end_layout
  5654. \end_inset
  5655. The context home screen is shown in
  5656. \begin_inset CommandInset ref
  5657. LatexCommand prettyref
  5658. reference "fig:Context-home-screen"
  5659. \end_inset
  5660. .
  5661. The top two lines of the home screen show shortcuts for your installed
  5662. applications and contacts who have pictures associated with them.
  5663. You can open the application or contact information screen by tapping on
  5664. the appropriate image.
  5665. To scroll left or right, simply drag your finger across the shortcuts.
  5666. You may also use your device's trackball to navigate around the screen,
  5667. if it has one.
  5668. \end_layout
  5669. \begin_layout Standard
  5670. The rest of the home screen shows you your recent e-mails, text messages,
  5671. appointments, missed calls, and other information.
  5672. You can scroll up and down in this area by dragging your finger up or down.
  5673. Tapping on an item will open it in the relevant application.
  5674. The context home screen will attempt to show contact pictures for each
  5675. event where they are available; if the sender is not associated with a
  5676. contact, or the contact has no photograph, then a white
  5677. \begin_inset Quotes eld
  5678. \end_inset
  5679. running man
  5680. \begin_inset Quotes erd
  5681. \end_inset
  5682. will be displayed.
  5683. \end_layout
  5684. \begin_layout Standard
  5685. As you use the context home screen, you should notice that the applications
  5686. you use most frequently start appearing nearer to the start of the list
  5687. and the types of event that you click on trickle up towards the top of
  5688. the screen.
  5689. If you regularly call someone every Saturday evening, you should find that
  5690. person at the top of your contacts list when you look on Saturday evening.
  5691. The more you use the context home screen, the better it adapts to your
  5692. needs!
  5693. \end_layout
  5694. \begin_layout Standard
  5695. \begin_inset Newpage pagebreak
  5696. \end_inset
  5697. \end_layout
  5698. \begin_layout Section
  5699. Developer Guide
  5700. \begin_inset CommandInset label
  5701. LatexCommand label
  5702. name "sec:Developer-Guide"
  5703. \end_inset
  5704. \end_layout
  5705. \begin_layout Standard
  5706. This guide details how you can integrate the data made available by the
  5707. \noun on
  5708. Context Analyser
  5709. \noun default
  5710. into your own applications.
  5711. It is expected that you are familiar with Android application development
  5712. and general concepts.
  5713. For an overview of how the
  5714. \noun on
  5715. Context Analyser
  5716. \noun default
  5717. works, please consult the user guide.
  5718. \end_layout
  5719. \begin_layout Standard
  5720. The
  5721. \noun on
  5722. Context Analyser
  5723. \noun default
  5724. exposes its data via a set of Content Providers.
  5725. These are augmented by several broadcast intents which can be used by third
  5726. party applications to receive immediate notification when the user's context
  5727. changes.
  5728. \end_layout
  5729. \begin_layout Subsection
  5730. Permissions
  5731. \begin_inset CommandInset label
  5732. LatexCommand label
  5733. name "sub:Permissions"
  5734. \end_inset
  5735. \end_layout
  5736. \begin_layout Standard
  5737. In order to protect the user's privacy, a series of permissions are defined
  5738. by the
  5739. \noun on
  5740. Context Analyser
  5741. \noun default
  5742. , and access to data and broadcast intents is limited to applications which
  5743. hold the appropriate permissions.
  5744. The
  5745. \noun on
  5746. Context Analyser
  5747. \noun default
  5748. defines the following permissions:
  5749. \end_layout
  5750. \begin_layout Itemize
  5751. uk.co.md87.android.contextanalyser.RECEIVE_UPDATES - allows the application to
  5752. receive real-time updates about context or place information through broadcast
  5753. intents
  5754. \end_layout
  5755. \begin_layout Itemize
  5756. uk.co.md87.android.contextanalyser.READ_PLACES - allows the application to read
  5757. places from the relevant content provider
  5758. \end_layout
  5759. \begin_layout Itemize
  5760. uk.co.md87.android.contextanalyser.WRITE_PLACES - allows the application to modify
  5761. places via the relevant content provider
  5762. \end_layout
  5763. \begin_layout Itemize
  5764. uk.co.md87.android.contextanalyser.READ_JOURNEYS - allows the application to
  5765. read journey information from the relevant content providers
  5766. \end_layout
  5767. \begin_layout Itemize
  5768. uk.co.md87.android.contextanalyser.WRITE_JOURNEYS - allows the application to
  5769. modify journey information via the relevant content providers
  5770. \end_layout
  5771. \begin_layout Itemize
  5772. uk.co.md87.android.contextanalyser.BROADCAST - permission used when broadcasting
  5773. context-related intents.
  5774. Applications may wish to check that broadcasters hold this permission to
  5775. prevent third parties broadcasting erroneous data.
  5776. \end_layout
  5777. \begin_layout Standard
  5778. If you do not declare the required permissions, a run time error will occur
  5779. when your application attempts to access protected data.
  5780. All permissions listed here are defined as
  5781. \noun on
  5782. dangerous
  5783. \noun default
  5784. , which means that end users will be prompted about them when installing
  5785. any application using them; this is in line with the underlying accelerometer
  5786. and location permissions.
  5787. \end_layout
  5788. \begin_layout Subsection
  5789. Model
  5790. \end_layout
  5791. \begin_layout Standard
  5792. The
  5793. \noun on
  5794. Context Analyser
  5795. \noun default
  5796. is backed by a database containing tables for
  5797. \emph on
  5798. places
  5799. \emph default
  5800. ,
  5801. \emph on
  5802. journeys
  5803. \emph default
  5804. and
  5805. \emph on
  5806. journey steps
  5807. \emph default
  5808. .
  5809. Activities and predictions are stored in memory.
  5810. \end_layout
  5811. \begin_layout Standard
  5812. A
  5813. \series bold
  5814. place
  5815. \series default
  5816. is a location represented by a latitude/longitude tuple.
  5817. Places have a radius of 500 metres; whenever a user moves to within 500
  5818. metres of a known place, they are assumed to be located at that place.
  5819. New places are identified when the user is observed to be in the same location
  5820. (within 500 metres) for three consecutive readings, which occur at 1 minute
  5821. intervals.
  5822. Places also have an associated name, which is initially set to a string
  5823. representation of the latitude and longitude; the
  5824. \noun on
  5825. Context Analyser
  5826. \noun default
  5827. will attempt to rename any place with such a name by geocoding the latitude/lon
  5828. gitude into a nearby street or landmark name.
  5829. \end_layout
  5830. \begin_layout Standard
  5831. An
  5832. \series bold
  5833. activity
  5834. \series default
  5835. is represented by a string delimited by forward slashes (
  5836. \noun on
  5837. /
  5838. \noun default
  5839. ).
  5840. This forms a hierarchy of classifications, with the following possible
  5841. values:
  5842. \end_layout
  5843. \begin_layout Itemize
  5844. CLASSIFIED/DANCING
  5845. \end_layout
  5846. \begin_layout Itemize
  5847. CLASSIFIED/IDLE/SITTING
  5848. \end_layout
  5849. \begin_layout Itemize
  5850. CLASSIFIED/IDLE/STANDING
  5851. \end_layout
  5852. \begin_layout Itemize
  5853. CLASSIFIED/VEHICLE/BUS
  5854. \end_layout
  5855. \begin_layout Itemize
  5856. CLASSIFIED/VEHICLE/CAR
  5857. \end_layout
  5858. \begin_layout Itemize
  5859. CLASSIFIED/WALKING
  5860. \end_layout
  5861. \begin_layout Itemize
  5862. CLASSIFIED/WALKING/STAIRS/DOWN
  5863. \end_layout
  5864. \begin_layout Itemize
  5865. CLASSIFIED/WALKING/STAIRS/UP
  5866. \end_layout
  5867. \begin_layout Standard
  5868. It is possible for activities to contain only a part of the hierarchy -
  5869. for example if the readings alternate between classifications for traveling
  5870. by bus and by car, they will be aggregated and the resulting activity will
  5871. be simply CLASSIFIED/VEHICLE
  5872. \noun on
  5873. .
  5874. \noun default
  5875. Similarly, if the user's activity is in constant flux, the resulting activity
  5876. will be aggregated to simply 'CLASSIFIED'.
  5877. \end_layout
  5878. \begin_layout Standard
  5879. A
  5880. \series bold
  5881. journey
  5882. \series default
  5883. is a recorded sequence of activities which occurred when the user moved
  5884. from one place to another.
  5885. Whenever the user leaves a known place, the
  5886. \noun on
  5887. Context Analyser
  5888. \noun default
  5889. begins a log of activities; when they then reach another known place, the
  5890. log is converted into a journey.
  5891. Each journey consists of a sequence of
  5892. \series bold
  5893. journey steps
  5894. \series default
  5895. , which describe a single activity and a number of repetitions.
  5896. \end_layout
  5897. \begin_layout Standard
  5898. For example, if the user leaves place A, spends five minutes walking, then
  5899. ten minutes on a bus, and arrives at place B:
  5900. \end_layout
  5901. \begin_layout Itemize
  5902. A journey will be created with a start point of A and an end point of B
  5903. \end_layout
  5904. \begin_layout Itemize
  5905. The journey will consist of two journey steps:
  5906. \end_layout
  5907. \begin_deeper
  5908. \begin_layout Itemize
  5909. Step one will have an activity of CLASSIFIED/WALKING with five repetitions
  5910. \end_layout
  5911. \begin_layout Itemize
  5912. Step two will have an activity of CLASSIFIED/VEHICLE/BUS with ten repetitions
  5913. \end_layout
  5914. \end_deeper
  5915. \begin_layout Standard
  5916. When the user is on a journey, the Context Analyser compares their current
  5917. history to that of previously recorded journeys leaving the same place.
  5918. If any of the journeys match, their destinations are considered as
  5919. \series bold
  5920. predictions
  5921. \series default
  5922. .
  5923. The number of times each matching journey occurred is summed and the result
  5924. is used as a 'score' for the destination involved.
  5925. The destination with the highest score is considered the most likely destinatio
  5926. n for the user.
  5927. \end_layout
  5928. \begin_layout Standard
  5929. For the purposes of prediction, a partial journey is considered to match
  5930. a historical journey if:
  5931. \end_layout
  5932. \begin_layout Itemize
  5933. it contains the same number of, or fewer, steps
  5934. \end_layout
  5935. \begin_layout Itemize
  5936. each step has the same activity
  5937. \end_layout
  5938. \begin_layout Itemize
  5939. the number of repetitions in each completed step (not the last step) is:
  5940. \end_layout
  5941. \begin_deeper
  5942. \begin_layout Itemize
  5943. no less than 50% of the historical value
  5944. \end_layout
  5945. \begin_layout Itemize
  5946. no greater than 150% of the historical value
  5947. \end_layout
  5948. \end_deeper
  5949. \begin_layout Itemize
  5950. the number of repetitions of the last step is:
  5951. \end_layout
  5952. \begin_deeper
  5953. \begin_layout Itemize
  5954. no greater than 150% of the historical value
  5955. \end_layout
  5956. \end_deeper
  5957. \begin_layout Subsection
  5958. Broadcast intents
  5959. \end_layout
  5960. \begin_layout Standard
  5961. The
  5962. \noun on
  5963. Context Analyser
  5964. \noun default
  5965. broadcasts three different intents to make other applications aware of
  5966. certain events.
  5967. Applications require the RECEIVE_UPDATES permission to receive these broadcasts
  5968. , as discussed previously.
  5969. These intents are:
  5970. \end_layout
  5971. \begin_layout Itemize
  5972. uk.co.md87.android.contextanalyser.ACTIVITY_CHANGED
  5973. \end_layout
  5974. \begin_layout Itemize
  5975. uk.co.md87.android.contextanalyser.CONTEXT_CHANGED
  5976. \end_layout
  5977. \begin_layout Itemize
  5978. uk.co.md87.android.contextanalyser.PREDICTION_AVAILABLE
  5979. \end_layout
  5980. \begin_layout Standard
  5981. The
  5982. \series bold
  5983. ACTIVITY_CHANGED
  5984. \series default
  5985. intent is broadcast whenever the user's activity is discovered to have
  5986. changed.
  5987. It contains two string extras - the old activity and the new activity -
  5988. under the keys
  5989. \begin_inset Quotes eld
  5990. \end_inset
  5991. old
  5992. \begin_inset Quotes erd
  5993. \end_inset
  5994. and
  5995. \begin_inset Quotes eld
  5996. \end_inset
  5997. new
  5998. \begin_inset Quotes erd
  5999. \end_inset
  6000. respectively.
  6001. \end_layout
  6002. \begin_layout Standard
  6003. The
  6004. \series bold
  6005. CONTEXT_CHANGED
  6006. \series default
  6007. intent occurs whenever some other aspect of the user's context changes.
  6008. Presently this only includes the user's current place.
  6009. It contains an integer extra under the key
  6010. \begin_inset Quotes eld
  6011. \end_inset
  6012. type
  6013. \begin_inset Quotes erd
  6014. \end_inset
  6015. which describes which type of context has changed; this will have the value
  6016. 1 for place updates.
  6017. Place updates will also have two further integer extras - the place the
  6018. user was previously in (or -1 if they were not in a known place) and the
  6019. place the user is now in - under the keys
  6020. \begin_inset Quotes eld
  6021. \end_inset
  6022. old
  6023. \begin_inset Quotes erd
  6024. \end_inset
  6025. and
  6026. \begin_inset Quotes eld
  6027. \end_inset
  6028. new
  6029. \begin_inset Quotes erd
  6030. \end_inset
  6031. , respectively.
  6032. These place IDs can be resolved to names and latitude/longitude by querying
  6033. the relevant content provider, described below.
  6034. \end_layout
  6035. \begin_layout Standard
  6036. The
  6037. \series bold
  6038. PREDICTION_AVAILABLE
  6039. \series default
  6040. intent is broadcast whenever a prediction has been made by the
  6041. \noun on
  6042. Context Analyser
  6043. \noun default
  6044. .
  6045. The best available prediction is included as a place ID in the
  6046. \begin_inset Quotes eld
  6047. \end_inset
  6048. best_target
  6049. \begin_inset Quotes erd
  6050. \end_inset
  6051. key, the total score for the prediction to that place is available as an
  6052. integer in the
  6053. \begin_inset Quotes eld
  6054. \end_inset
  6055. count
  6056. \begin_inset Quotes erd
  6057. \end_inset
  6058. key, and the 'probability' (the score for that place divided by the total
  6059. scores for all predicted places) is a float in the
  6060. \begin_inset Quotes eld
  6061. \end_inset
  6062. best_probability
  6063. \begin_inset Quotes erd
  6064. \end_inset
  6065. key.
  6066. A full set of predictions can be retrieved from the relevant content provider,
  6067. described below.
  6068. \end_layout
  6069. \begin_layout Standard
  6070. As discussed in the permissions section (
  6071. \begin_inset CommandInset ref
  6072. LatexCommand prettyref
  6073. reference "sub:Permissions"
  6074. \end_inset
  6075. ), you may wish to make sure that all broadcasts you receive are sent by
  6076. an application which holds the BROADCAST permission.
  6077. This ensures that the user trusts the application to send these broadcasts,
  6078. and reduces the chance that they are from a malicious application attempting
  6079. to introduce erroneous data or otherwise compromise your receiver.
  6080. \end_layout
  6081. \begin_layout Subsection
  6082. Content providers
  6083. \end_layout
  6084. \begin_layout Standard
  6085. The
  6086. \noun on
  6087. Context Analyser
  6088. \noun default
  6089. provides four content providers from which you can receive data:
  6090. \end_layout
  6091. \begin_layout Subsubsection
  6092. Activities
  6093. \end_layout
  6094. \begin_layout Standard
  6095. Allows querying of the user's current activity.
  6096. This may be expanded in future versions to allow querying of all known
  6097. activities.
  6098. Read only, does not accept selection, projection or order parameters.
  6099. \end_layout
  6100. \begin_layout Standard
  6101. URI:
  6102. \noun on
  6103. content://uk.co.md87.android.contextanalyser.activitiescontentprovider/current
  6104. \end_layout
  6105. \begin_layout Standard
  6106. Content type:
  6107. \noun on
  6108. vnd.contextanalyser.activity
  6109. \end_layout
  6110. \begin_layout Standard
  6111. Columns:
  6112. \end_layout
  6113. \begin_layout Standard
  6114. \begin_inset Tabular
  6115. <lyxtabular version="3" rows="2" columns="3">
  6116. <features>
  6117. <column alignment="center" valignment="top" width="0">
  6118. <column alignment="center" valignment="top" width="0">
  6119. <column alignment="center" valignment="top" width="0">
  6120. <row>
  6121. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  6122. \begin_inset Text
  6123. \begin_layout Plain Layout
  6124. \series bold
  6125. Name
  6126. \end_layout
  6127. \end_inset
  6128. </cell>
  6129. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  6130. \begin_inset Text
  6131. \begin_layout Plain Layout
  6132. \series bold
  6133. Type
  6134. \end_layout
  6135. \end_inset
  6136. </cell>
  6137. <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  6138. \begin_inset Text
  6139. \begin_layout Plain Layout
  6140. \series bold
  6141. Remarks
  6142. \end_layout
  6143. \end_inset
  6144. </cell>
  6145. </row>
  6146. <row>
  6147. <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
  6148. \begin_inset Text
  6149. \begin_layout Plain Layout
  6150. activity
  6151. \end_layout
  6152. \end_inset
  6153. </cell>
  6154. <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
  6155. \begin_inset Text
  6156. \begin_layout Plain Layout
  6157. string
  6158. \end_layout
  6159. \end_inset
  6160. </cell>
  6161. <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
  6162. \begin_inset Text
  6163. \begin_layout Plain Layout
  6164. The user's current activity
  6165. \end_layout
  6166. \end_inset
  6167. </cell>
  6168. </row>
  6169. </lyxtabular>
  6170. \end_inset
  6171. \end_layout
  6172. \begin_layout Subsubsection
  6173. Journeys
  6174. \end_layout
  6175. \begin_layout Standard
  6176. Allows querying of the user's historical journeys and steps within them.
  6177. Read/write access, supports selection and ordering.
  6178. \end_layout
  6179. \begin_layout Paragraph
  6180. Journeys
  6181. \end_layout
  6182. \begin_layout Standard
  6183. URI:
  6184. \noun on
  6185. content://uk.co.md87.android.contextanalyser.journeyscontentprovider/journeys
  6186. \end_layout
  6187. \begin_layout Standard
  6188. Content type:
  6189. \noun on
  6190. vnd.contextanalyser.journey
  6191. \end_layout
  6192. \begin_layout Standard
  6193. Columns:
  6194. \end_layout
  6195. \begin_layout Standard
  6196. \begin_inset Tabular
  6197. <lyxtabular version="3" rows="6" columns="3">
  6198. <features>
  6199. <column alignment="center" valignment="top" width="0">
  6200. <column alignment="center" valignment="top" width="0">
  6201. <column alignment="center" valignment="top" width="0">
  6202. <row>
  6203. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  6204. \begin_inset Text
  6205. \begin_layout Plain Layout
  6206. \series bold
  6207. Name
  6208. \end_layout
  6209. \end_inset
  6210. </cell>
  6211. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  6212. \begin_inset Text
  6213. \begin_layout Plain Layout
  6214. \series bold
  6215. Type
  6216. \end_layout
  6217. \end_inset
  6218. </cell>
  6219. <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  6220. \begin_inset Text
  6221. \begin_layout Plain Layout
  6222. \series bold
  6223. Remarks
  6224. \end_layout
  6225. \end_inset
  6226. </cell>
  6227. </row>
  6228. <row>
  6229. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  6230. \begin_inset Text
  6231. \begin_layout Plain Layout
  6232. _id
  6233. \end_layout
  6234. \end_inset
  6235. </cell>
  6236. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  6237. \begin_inset Text
  6238. \begin_layout Plain Layout
  6239. long
  6240. \end_layout
  6241. \end_inset
  6242. </cell>
  6243. <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  6244. \begin_inset Text
  6245. \begin_layout Plain Layout
  6246. A unique, persistent ID for the journey
  6247. \end_layout
  6248. \end_inset
  6249. </cell>
  6250. </row>
  6251. <row>
  6252. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  6253. \begin_inset Text
  6254. \begin_layout Plain Layout
  6255. start
  6256. \end_layout
  6257. \end_inset
  6258. </cell>
  6259. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  6260. \begin_inset Text
  6261. \begin_layout Plain Layout
  6262. long
  6263. \end_layout
  6264. \end_inset
  6265. </cell>
  6266. <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  6267. \begin_inset Text
  6268. \begin_layout Plain Layout
  6269. The ID of the place at which this journey starts
  6270. \end_layout
  6271. \end_inset
  6272. </cell>
  6273. </row>
  6274. <row>
  6275. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  6276. \begin_inset Text
  6277. \begin_layout Plain Layout
  6278. end
  6279. \end_layout
  6280. \end_inset
  6281. </cell>
  6282. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  6283. \begin_inset Text
  6284. \begin_layout Plain Layout
  6285. long
  6286. \end_layout
  6287. \end_inset
  6288. </cell>
  6289. <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  6290. \begin_inset Text
  6291. \begin_layout Plain Layout
  6292. The ID of the place at which this journey ends
  6293. \end_layout
  6294. \end_inset
  6295. </cell>
  6296. </row>
  6297. <row>
  6298. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  6299. \begin_inset Text
  6300. \begin_layout Plain Layout
  6301. steps
  6302. \end_layout
  6303. \end_inset
  6304. </cell>
  6305. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  6306. \begin_inset Text
  6307. \begin_layout Plain Layout
  6308. int
  6309. \end_layout
  6310. \end_inset
  6311. </cell>
  6312. <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  6313. \begin_inset Text
  6314. \begin_layout Plain Layout
  6315. The number of steps in this journey
  6316. \end_layout
  6317. \end_inset
  6318. </cell>
  6319. </row>
  6320. <row>
  6321. <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
  6322. \begin_inset Text
  6323. \begin_layout Plain Layout
  6324. number
  6325. \end_layout
  6326. \end_inset
  6327. </cell>
  6328. <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
  6329. \begin_inset Text
  6330. \begin_layout Plain Layout
  6331. int
  6332. \end_layout
  6333. \end_inset
  6334. </cell>
  6335. <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
  6336. \begin_inset Text
  6337. \begin_layout Plain Layout
  6338. The number of times this journey has been made
  6339. \end_layout
  6340. \end_inset
  6341. </cell>
  6342. </row>
  6343. </lyxtabular>
  6344. \end_inset
  6345. \end_layout
  6346. \begin_layout Paragraph
  6347. Journey steps
  6348. \end_layout
  6349. \begin_layout Standard
  6350. URI:
  6351. \noun on
  6352. content://uk.co.md87.android.contextanalyser.journeyscontentprovider/steps
  6353. \end_layout
  6354. \begin_layout Standard
  6355. Content type:
  6356. \noun on
  6357. vnd.contextanalyser.journeystep
  6358. \end_layout
  6359. \begin_layout Standard
  6360. Columns:
  6361. \end_layout
  6362. \begin_layout Standard
  6363. \begin_inset Tabular
  6364. <lyxtabular version="3" rows="6" columns="3">
  6365. <features>
  6366. <column alignment="center" valignment="top" width="0">
  6367. <column alignment="center" valignment="top" width="0">
  6368. <column alignment="center" valignment="top" width="0">
  6369. <row>
  6370. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  6371. \begin_inset Text
  6372. \begin_layout Plain Layout
  6373. \series bold
  6374. Name
  6375. \end_layout
  6376. \end_inset
  6377. </cell>
  6378. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  6379. \begin_inset Text
  6380. \begin_layout Plain Layout
  6381. \series bold
  6382. Type
  6383. \end_layout
  6384. \end_inset
  6385. </cell>
  6386. <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  6387. \begin_inset Text
  6388. \begin_layout Plain Layout
  6389. \series bold
  6390. Remarks
  6391. \end_layout
  6392. \end_inset
  6393. </cell>
  6394. </row>
  6395. <row>
  6396. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  6397. \begin_inset Text
  6398. \begin_layout Plain Layout
  6399. _id
  6400. \end_layout
  6401. \end_inset
  6402. </cell>
  6403. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  6404. \begin_inset Text
  6405. \begin_layout Plain Layout
  6406. long
  6407. \end_layout
  6408. \end_inset
  6409. </cell>
  6410. <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  6411. \begin_inset Text
  6412. \begin_layout Plain Layout
  6413. A unique, persistent ID for the step
  6414. \end_layout
  6415. \end_inset
  6416. </cell>
  6417. </row>
  6418. <row>
  6419. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  6420. \begin_inset Text
  6421. \begin_layout Plain Layout
  6422. activity
  6423. \end_layout
  6424. \end_inset
  6425. </cell>
  6426. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  6427. \begin_inset Text
  6428. \begin_layout Plain Layout
  6429. string
  6430. \end_layout
  6431. \end_inset
  6432. </cell>
  6433. <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  6434. \begin_inset Text
  6435. \begin_layout Plain Layout
  6436. The activity that was observed
  6437. \end_layout
  6438. \end_inset
  6439. </cell>
  6440. </row>
  6441. <row>
  6442. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  6443. \begin_inset Text
  6444. \begin_layout Plain Layout
  6445. repetitions
  6446. \end_layout
  6447. \end_inset
  6448. </cell>
  6449. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  6450. \begin_inset Text
  6451. \begin_layout Plain Layout
  6452. int
  6453. \end_layout
  6454. \end_inset
  6455. </cell>
  6456. <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  6457. \begin_inset Text
  6458. \begin_layout Plain Layout
  6459. The number of times the activity occurred
  6460. \end_layout
  6461. \end_inset
  6462. </cell>
  6463. </row>
  6464. <row>
  6465. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  6466. \begin_inset Text
  6467. \begin_layout Plain Layout
  6468. journey
  6469. \end_layout
  6470. \end_inset
  6471. </cell>
  6472. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  6473. \begin_inset Text
  6474. \begin_layout Plain Layout
  6475. long
  6476. \end_layout
  6477. \end_inset
  6478. </cell>
  6479. <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  6480. \begin_inset Text
  6481. \begin_layout Plain Layout
  6482. The ID of the journey that this step belongs to
  6483. \end_layout
  6484. \end_inset
  6485. </cell>
  6486. </row>
  6487. <row>
  6488. <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
  6489. \begin_inset Text
  6490. \begin_layout Plain Layout
  6491. next
  6492. \end_layout
  6493. \end_inset
  6494. </cell>
  6495. <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
  6496. \begin_inset Text
  6497. \begin_layout Plain Layout
  6498. long
  6499. \end_layout
  6500. \end_inset
  6501. </cell>
  6502. <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
  6503. \begin_inset Text
  6504. \begin_layout Plain Layout
  6505. The ID of the next step in the journey, or 0 if the last step in sequence
  6506. \end_layout
  6507. \end_inset
  6508. </cell>
  6509. </row>
  6510. </lyxtabular>
  6511. \end_inset
  6512. \end_layout
  6513. \begin_layout Subsubsection
  6514. Places
  6515. \end_layout
  6516. \begin_layout Standard
  6517. Allows querying of the user's know places.
  6518. Read/write access, supports selection and ordering.
  6519. \end_layout
  6520. \begin_layout Standard
  6521. URI:
  6522. \noun on
  6523. content://uk.co.md87.android.contextanalyser.placescontentprovider/places
  6524. \end_layout
  6525. \begin_layout Standard
  6526. Content type:
  6527. \noun on
  6528. vnd.contextanalyser.location
  6529. \end_layout
  6530. \begin_layout Standard
  6531. Columns:
  6532. \end_layout
  6533. \begin_layout Standard
  6534. \begin_inset Tabular
  6535. <lyxtabular version="3" rows="8" columns="3">
  6536. <features>
  6537. <column alignment="center" valignment="top" width="0">
  6538. <column alignment="center" valignment="top" width="0">
  6539. <column alignment="center" valignment="top" width="0">
  6540. <row>
  6541. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  6542. \begin_inset Text
  6543. \begin_layout Plain Layout
  6544. \series bold
  6545. Name
  6546. \end_layout
  6547. \end_inset
  6548. </cell>
  6549. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  6550. \begin_inset Text
  6551. \begin_layout Plain Layout
  6552. \series bold
  6553. Type
  6554. \end_layout
  6555. \end_inset
  6556. </cell>
  6557. <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  6558. \begin_inset Text
  6559. \begin_layout Plain Layout
  6560. \series bold
  6561. Remarks
  6562. \end_layout
  6563. \end_inset
  6564. </cell>
  6565. </row>
  6566. <row>
  6567. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  6568. \begin_inset Text
  6569. \begin_layout Plain Layout
  6570. _id
  6571. \end_layout
  6572. \end_inset
  6573. </cell>
  6574. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  6575. \begin_inset Text
  6576. \begin_layout Plain Layout
  6577. long
  6578. \end_layout
  6579. \end_inset
  6580. </cell>
  6581. <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  6582. \begin_inset Text
  6583. \begin_layout Plain Layout
  6584. A unique, persistent ID for the place
  6585. \end_layout
  6586. \end_inset
  6587. </cell>
  6588. </row>
  6589. <row>
  6590. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  6591. \begin_inset Text
  6592. \begin_layout Plain Layout
  6593. name
  6594. \end_layout
  6595. \end_inset
  6596. </cell>
  6597. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  6598. \begin_inset Text
  6599. \begin_layout Plain Layout
  6600. string
  6601. \end_layout
  6602. \end_inset
  6603. </cell>
  6604. <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  6605. \begin_inset Text
  6606. \begin_layout Plain Layout
  6607. The name of the place
  6608. \end_layout
  6609. \end_inset
  6610. </cell>
  6611. </row>
  6612. <row>
  6613. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  6614. \begin_inset Text
  6615. \begin_layout Plain Layout
  6616. latitude
  6617. \end_layout
  6618. \end_inset
  6619. </cell>
  6620. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  6621. \begin_inset Text
  6622. \begin_layout Plain Layout
  6623. double
  6624. \end_layout
  6625. \end_inset
  6626. </cell>
  6627. <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  6628. \begin_inset Text
  6629. \begin_layout Plain Layout
  6630. The latitude of the centre of the place
  6631. \end_layout
  6632. \end_inset
  6633. </cell>
  6634. </row>
  6635. <row>
  6636. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  6637. \begin_inset Text
  6638. \begin_layout Plain Layout
  6639. longitude
  6640. \end_layout
  6641. \end_inset
  6642. </cell>
  6643. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  6644. \begin_inset Text
  6645. \begin_layout Plain Layout
  6646. double
  6647. \end_layout
  6648. \end_inset
  6649. </cell>
  6650. <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  6651. \begin_inset Text
  6652. \begin_layout Plain Layout
  6653. The longitude at the centre of the place
  6654. \end_layout
  6655. \end_inset
  6656. </cell>
  6657. </row>
  6658. <row>
  6659. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  6660. \begin_inset Text
  6661. \begin_layout Plain Layout
  6662. duration
  6663. \end_layout
  6664. \end_inset
  6665. </cell>
  6666. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  6667. \begin_inset Text
  6668. \begin_layout Plain Layout
  6669. long
  6670. \end_layout
  6671. \end_inset
  6672. </cell>
  6673. <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  6674. \begin_inset Text
  6675. \begin_layout Plain Layout
  6676. Amount of time in seconds spent at the place
  6677. \end_layout
  6678. \end_inset
  6679. </cell>
  6680. </row>
  6681. <row>
  6682. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  6683. \begin_inset Text
  6684. \begin_layout Plain Layout
  6685. times
  6686. \end_layout
  6687. \end_inset
  6688. </cell>
  6689. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  6690. \begin_inset Text
  6691. \begin_layout Plain Layout
  6692. long
  6693. \end_layout
  6694. \end_inset
  6695. </cell>
  6696. <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  6697. \begin_inset Text
  6698. \begin_layout Plain Layout
  6699. The number of times the place has been visited
  6700. \end_layout
  6701. \end_inset
  6702. </cell>
  6703. </row>
  6704. <row>
  6705. <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
  6706. \begin_inset Text
  6707. \begin_layout Plain Layout
  6708. lastvisit
  6709. \end_layout
  6710. \end_inset
  6711. </cell>
  6712. <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
  6713. \begin_inset Text
  6714. \begin_layout Plain Layout
  6715. long
  6716. \end_layout
  6717. \end_inset
  6718. </cell>
  6719. <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
  6720. \begin_inset Text
  6721. \begin_layout Plain Layout
  6722. The unix timestamp of the last visit (seconds)
  6723. \end_layout
  6724. \end_inset
  6725. </cell>
  6726. </row>
  6727. </lyxtabular>
  6728. \end_inset
  6729. \end_layout
  6730. \begin_layout Subsubsection
  6731. Predictions
  6732. \end_layout
  6733. \begin_layout Standard
  6734. Allows querying of the current predictions, if any.
  6735. Read only, does not accept selection, projection or order parameters.
  6736. \end_layout
  6737. \begin_layout Standard
  6738. URI:
  6739. \noun on
  6740. content://uk.co.md87.android.contextanalyser.predictionscontentprovider/predictions
  6741. \end_layout
  6742. \begin_layout Standard
  6743. Content type:
  6744. \noun on
  6745. vnd.contextanalyser.prediction
  6746. \end_layout
  6747. \begin_layout Standard
  6748. Columns:
  6749. \end_layout
  6750. \begin_layout Standard
  6751. \begin_inset Tabular
  6752. <lyxtabular version="3" rows="4" columns="3">
  6753. <features>
  6754. <column alignment="center" valignment="top" width="0">
  6755. <column alignment="center" valignment="top" width="0">
  6756. <column alignment="center" valignment="top" width="0">
  6757. <row>
  6758. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  6759. \begin_inset Text
  6760. \begin_layout Plain Layout
  6761. \series bold
  6762. Name
  6763. \end_layout
  6764. \end_inset
  6765. </cell>
  6766. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  6767. \begin_inset Text
  6768. \begin_layout Plain Layout
  6769. \series bold
  6770. Type
  6771. \end_layout
  6772. \end_inset
  6773. </cell>
  6774. <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  6775. \begin_inset Text
  6776. \begin_layout Plain Layout
  6777. \series bold
  6778. Remarks
  6779. \end_layout
  6780. \end_inset
  6781. </cell>
  6782. </row>
  6783. <row>
  6784. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  6785. \begin_inset Text
  6786. \begin_layout Plain Layout
  6787. _ID
  6788. \end_layout
  6789. \end_inset
  6790. </cell>
  6791. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  6792. \begin_inset Text
  6793. \begin_layout Plain Layout
  6794. long
  6795. \end_layout
  6796. \end_inset
  6797. </cell>
  6798. <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  6799. \begin_inset Text
  6800. \begin_layout Plain Layout
  6801. A unique ID for the prediction
  6802. \end_layout
  6803. \end_inset
  6804. </cell>
  6805. </row>
  6806. <row>
  6807. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  6808. \begin_inset Text
  6809. \begin_layout Plain Layout
  6810. place
  6811. \end_layout
  6812. \end_inset
  6813. </cell>
  6814. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  6815. \begin_inset Text
  6816. \begin_layout Plain Layout
  6817. long
  6818. \end_layout
  6819. \end_inset
  6820. </cell>
  6821. <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  6822. \begin_inset Text
  6823. \begin_layout Plain Layout
  6824. The ID of the predicted destination
  6825. \end_layout
  6826. \end_inset
  6827. </cell>
  6828. </row>
  6829. <row>
  6830. <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
  6831. \begin_inset Text
  6832. \begin_layout Plain Layout
  6833. count
  6834. \end_layout
  6835. \end_inset
  6836. </cell>
  6837. <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
  6838. \begin_inset Text
  6839. \begin_layout Plain Layout
  6840. int
  6841. \end_layout
  6842. \end_inset
  6843. </cell>
  6844. <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
  6845. \begin_inset Text
  6846. \begin_layout Plain Layout
  6847. The 'score' of the prediction
  6848. \end_layout
  6849. \end_inset
  6850. </cell>
  6851. </row>
  6852. </lyxtabular>
  6853. \end_inset
  6854. \end_layout
  6855. \begin_layout Subsection
  6856. Context API
  6857. \end_layout
  6858. \begin_layout Standard
  6859. A small
  6860. \begin_inset Quotes eld
  6861. \end_inset
  6862. API
  6863. \begin_inset Quotes erd
  6864. \end_inset
  6865. is available to facilitate easier access to the services exposed by the
  6866. \noun on
  6867. Context Analyser.
  6868. \noun default
  6869. This consists of the
  6870. \noun on
  6871. ContextApi
  6872. \noun default
  6873. class and its assorted subclasses.
  6874. These subclasses contain constant values for all column names, URIs and
  6875. content types, as well as intent names and enumeration values.
  6876. \end_layout
  6877. \begin_layout Standard
  6878. The
  6879. \noun on
  6880. ContextApi.Intents
  6881. \noun default
  6882. class defines string constants for the three broadcast intents which are
  6883. used by the
  6884. \noun on
  6885. Context Analyser
  6886. \noun default
  6887. .
  6888. The
  6889. \noun on
  6890. ContextTypes
  6891. \noun default
  6892. inner class contains integer constants for the possible 'type' values for
  6893. the CONTEXT_CHANGED intent.
  6894. \end_layout
  6895. \begin_layout Standard
  6896. The
  6897. \noun on
  6898. Places
  6899. \noun default
  6900. ,
  6901. \noun on
  6902. Journeys
  6903. \noun default
  6904. ,
  6905. \noun on
  6906. JourneySteps
  6907. \noun default
  6908. ,
  6909. \noun on
  6910. Predictions
  6911. \noun default
  6912. and
  6913. \noun on
  6914. Activities
  6915. \noun default
  6916. classes all contain a CONTENT_URI field containing the Uri of the the content
  6917. provider, a CONTENT_TYPE field containing the string mime type for that
  6918. provider, and a static
  6919. \noun on
  6920. ColumnNames
  6921. \noun default
  6922. class which contains string constants for each column returned by the content
  6923. provider.
  6924. \end_layout
  6925. \begin_layout Standard
  6926. The following code from the
  6927. \noun on
  6928. Places
  6929. \noun default
  6930. application shows the use of these constant values:
  6931. \end_layout
  6932. \begin_layout LyX-Code
  6933. final Cursor cursor = managedQuery(ContextApi.Places.CONTENT_URI,
  6934. \end_layout
  6935. \begin_layout LyX-Code
  6936. new String[] { ColumnNames.LATITUDE, ColumnNames.LONGITUDE,
  6937. \end_layout
  6938. \begin_layout LyX-Code
  6939. ColumnNames._ID, ColumnNames.NAME, ColumnNames.LAST_VISIT,
  6940. \end_layout
  6941. \begin_layout LyX-Code
  6942. ColumnNames.VISIT_COUNT }, null, null, null);
  6943. \end_layout
  6944. \begin_layout LyX-Code
  6945. \end_layout
  6946. \begin_layout LyX-Code
  6947. if (cursor.moveToFirst()) {
  6948. \end_layout
  6949. \begin_layout LyX-Code
  6950. final int nameColumn = cursor.getColumnIndex(ColumnNames.NAME);
  6951. \end_layout
  6952. \begin_layout LyX-Code
  6953. final int idColumn = cursor.getColumnIndex(ColumnNames._ID);
  6954. \end_layout
  6955. \begin_layout LyX-Code
  6956. \end_layout
  6957. \begin_layout LyX-Code
  6958. do {
  6959. \end_layout
  6960. \begin_layout LyX-Code
  6961. final String name = cursor.getString(nameColumn);
  6962. \end_layout
  6963. \begin_layout LyX-Code
  6964. final int id = cursor.getInt(idColumn);
  6965. \end_layout
  6966. \begin_layout LyX-Code
  6967. // etc
  6968. \end_layout
  6969. \begin_layout LyX-Code
  6970. } while (cursor.moveToNext());
  6971. \end_layout
  6972. \begin_layout LyX-Code
  6973. }
  6974. \end_layout
  6975. \begin_layout Standard
  6976. Note that the code imports both the
  6977. \noun on
  6978. ContextApi
  6979. \noun default
  6980. class, and the
  6981. \noun on
  6982. ContextApi.Places.ColumnNames
  6983. \noun default
  6984. class.
  6985. \end_layout
  6986. \begin_layout Standard
  6987. \begin_inset Newpage pagebreak
  6988. \end_inset
  6989. \end_layout
  6990. \begin_layout Section
  6991. Extract from export of window data
  6992. \begin_inset CommandInset label
  6993. LatexCommand label
  6994. name "sec:Extract-from-export"
  6995. \end_inset
  6996. \end_layout
  6997. \begin_layout Quote
  6998. \noindent
  6999. \align left
  7000. \size footnotesize
  7001. Activity: CLASSIFIED/WALKING
  7002. \end_layout
  7003. \begin_layout Quote
  7004. \noindent
  7005. \align left
  7006. \size footnotesize
  7007. 1264518159452:-7.804459,-1.3620348,-0.55843425,99.4375,73.3125,-32.6875, 1264518159502
  7008. :-8.853226,-0.53119355,-0.0,100.4375,72.0625,-33.6875, 1264518159557:-11.699879,0.830841
  7009. 2,-1.2803127,101.1875,70.8125,-32.9375, 1264518159601:-13.797412,-0.24516626,-1.1168685
  7010. ,101.4375,70.5625,-31.9375, 1264518159652:-10.59663,-4.8760843,1.96133,102.375,71.5625,-
  7011. 31.1875, 1264518159702:-10.528529,-5.3119354,0.6946377,102.125,71.5625,-29.6875,
  7012. 1264518159751:-14.219643,-2.506144,2.4108016,102.375,69.5625,-28.0, 1264518159801:-9.2
  7013. 75456,-1.2666923,1.253072,102.875,69.8125,-29.0, 1264518159852:-5.1621118,-0.7491191,0.2
  7014. 7240697,103.125,69.8125,-30.6875, 1264518159901:-3.568531,-0.8036005,0.88532263,103.625
  7015. ,68.5625,-31.9375, 1264518159951:-4.4810944,-0.51757324,1.253072,103.625,69.0625,-31.687
  7016. 5, 1264518160001:-6.9191365,1.4028958,1.0487667,103.875,70.5625,-30.4375, 126451816006
  7017. 1:-13.007432,1.3484144,0.32688835,105.0625,70.5625,-29.0, 1264518160102:-16.42614,1.2394
  7018. 516,-0.10896278,104.375,71.3125,-27.25, 1264518160152:-15.908566,-2.3018389,-0.06810174
  7019. ,104.625,71.0625,-27.25, 1264518160202:-9.915613,-4.780742,1.6344417,105.3125,71.0625,-2
  7020. 9.0, 1264518160251:-10.242501,-2.465283,2.73769,105.0625,70.3125,-30.4375, 126451816030
  7021. 1:-10.351464,-4.8897047,0.58567494,104.375,71.3125,-32.6875, 1264518160351:-7.600154,-2.
  7022. 0294318,0.81722087,102.375,73.0625,-33.6875, 1264518160401:-6.1291566,-1.0760075,0.7218
  7023. 784,101.1875,72.3125,-34.375, 1264518160451:-5.3936577,-1.5527196,0.3677494,101.1875,71.
  7024. 8125,-35.625, 1264518160502:-6.101916,-1.3892754,-0.23154591,100.6875,72.0625,-35.625,
  7025. 1264518160551:-7.2187843,-1.525479,-0.8308412,100.9375,68.0625,-36.625, 1264518160694
  7026. :-15.227549,-2.2609777,0.6401563,101.4375,68.0625,-36.625, 1264518160697:-15.227549,-2.2
  7027. 609777,0.6401563,101.4375,68.0625,-36.625, 1264518160701:-15.227549,-2.2609777,0.640156
  7028. 3,101.4375,68.0625,-36.625, 1264518160752:-9.956474,-3.840938,3.405087,103.125,68.8125,-
  7029. 36.375, 1264518160802:-12.598822,-5.298315,0.32688835,103.875,69.3125,-34.875,
  7030. 1264518160858:-13.756551,-2.9283748,2.5333846,105.0625,69.3125,-32.6875, 126451816090
  7031. 1:-8.962189,-1.6344417,0.9942854,105.5625,68.0625,-34.125, 1264518160951:-4.399372,-1.47
  7032. 09976,0.54481393,104.625,68.8125,-35.875, 1264518161001:-3.050958,-1.4573772,0.58567494
  7033. ,105.0625,68.5625,-35.875, 1264518161051:-4.5491962,0.19068487,0.6537767,105.0625,67.812
  7034. 5,-35.375, 1264518161101:-6.7965536,1.3484144,0.87170225,105.5625,69.3125,-33.4375,
  7035. 1264518161151:-12.993812,1.920469,1.253072,107.3125,70.3125,-30.4375, 1264518161201:-
  7036. 16.303556,0.53119355,0.14982383,106.8125,71.0625,-29.5, 1264518161251:-14.09706,-4.75350
  7037. 14,0.20430522,105.5625,71.0625,-29.0, 1264518161301:-10.746454,-4.971427,1.4709976,105.5
  7038. 625,70.3125,-30.1875, 1264518161351:-11.34575,-4.0588636,1.525479,104.125,70.5625,-32.93
  7039. 75, 1264518161401:-8.989429,-4.930566,0.88532263,103.375,70.8125,-35.125, 126451816145
  7040. 1:-6.4560447,-2.1111538,0.47671217,101.625,71.3125,-35.125,
  7041. \end_layout
  7042. \begin_layout Standard
  7043. \begin_inset Newpage pagebreak
  7044. \end_inset
  7045. \end_layout
  7046. \begin_layout Section
  7047. Extract from ARFF representation
  7048. \begin_inset CommandInset label
  7049. LatexCommand label
  7050. name "sec:Extract-from-ARFF"
  7051. \end_inset
  7052. \end_layout
  7053. \begin_layout Quotation
  7054. \size footnotesize
  7055. @RELATION activity
  7056. \end_layout
  7057. \begin_layout Quotation
  7058. \size footnotesize
  7059. @ATTRIBUTE "Absolute Mean (series 0)" numeric
  7060. \end_layout
  7061. \begin_layout Quotation
  7062. \size footnotesize
  7063. @ATTRIBUTE "Absolute Mean (series 1)" numeric
  7064. \end_layout
  7065. \begin_layout Quotation
  7066. \size footnotesize
  7067. @ATTRIBUTE "Absolute Mean (series 2)" numeric
  7068. \end_layout
  7069. \begin_layout Quotation
  7070. \size footnotesize
  7071. @ATTRIBUTE "Absolute Mean (series 3)" numeric
  7072. \end_layout
  7073. \begin_layout Quotation
  7074. \size footnotesize
  7075. @ATTRIBUTE "Absolute Mean (series 4)" numeric
  7076. \end_layout
  7077. \begin_layout Quotation
  7078. \size footnotesize
  7079. @ATTRIBUTE "Absolute Mean (series 5)" numeric
  7080. \end_layout
  7081. \begin_layout Quotation
  7082. \size footnotesize
  7083. @ATTRIBUTE "Maximum (series 0)" numeric
  7084. \end_layout
  7085. \begin_layout Quotation
  7086. \size footnotesize
  7087. @ATTRIBUTE "Maximum (series 1)" numeric
  7088. \end_layout
  7089. \begin_layout Quotation
  7090. \size footnotesize
  7091. @ATTRIBUTE "Maximum (series 2)" numeric
  7092. \end_layout
  7093. \begin_layout Quotation
  7094. \size footnotesize
  7095. @ATTRIBUTE "Maximum (series 3)" numeric
  7096. \end_layout
  7097. \begin_layout Quotation
  7098. \size footnotesize
  7099. @ATTRIBUTE "Maximum (series 4)" numeric
  7100. \end_layout
  7101. \begin_layout Quotation
  7102. \size footnotesize
  7103. @ATTRIBUTE "Maximum (series 5)" numeric
  7104. \end_layout
  7105. \begin_layout Quotation
  7106. \size footnotesize
  7107. @ATTRIBUTE "Mean (series 0)" numeric
  7108. \end_layout
  7109. \begin_layout Quotation
  7110. \size footnotesize
  7111. @ATTRIBUTE "Mean (series 1)" numeric
  7112. \end_layout
  7113. \begin_layout Quotation
  7114. \size footnotesize
  7115. @ATTRIBUTE "Mean (series 2)" numeric
  7116. \end_layout
  7117. \begin_layout Quotation
  7118. \size footnotesize
  7119. @ATTRIBUTE "Mean (series 3)" numeric
  7120. \end_layout
  7121. \begin_layout Quotation
  7122. \size footnotesize
  7123. @ATTRIBUTE "Mean (series 4)" numeric
  7124. \end_layout
  7125. \begin_layout Quotation
  7126. \size footnotesize
  7127. @ATTRIBUTE "Mean (series 5)" numeric
  7128. \end_layout
  7129. \begin_layout Quotation
  7130. \size footnotesize
  7131. @ATTRIBUTE "Median (series 0)" numeric
  7132. \end_layout
  7133. \begin_layout Quotation
  7134. \size footnotesize
  7135. @ATTRIBUTE "Median (series 1)" numeric
  7136. \end_layout
  7137. \begin_layout Quotation
  7138. \size footnotesize
  7139. @ATTRIBUTE "Median (series 2)" numeric
  7140. \end_layout
  7141. \begin_layout Quotation
  7142. \size footnotesize
  7143. @ATTRIBUTE "Median (series 3)" numeric
  7144. \end_layout
  7145. \begin_layout Quotation
  7146. \size footnotesize
  7147. @ATTRIBUTE "Median (series 4)" numeric
  7148. \end_layout
  7149. \begin_layout Quotation
  7150. \size footnotesize
  7151. @ATTRIBUTE "Median (series 5)" numeric
  7152. \end_layout
  7153. \begin_layout Quotation
  7154. \size footnotesize
  7155. @ATTRIBUTE "Minimum (series 0)" numeric
  7156. \end_layout
  7157. \begin_layout Quotation
  7158. \size footnotesize
  7159. @ATTRIBUTE "Minimum (series 1)" numeric
  7160. \end_layout
  7161. \begin_layout Quotation
  7162. \size footnotesize
  7163. @ATTRIBUTE "Minimum (series 2)" numeric
  7164. \end_layout
  7165. \begin_layout Quotation
  7166. \size footnotesize
  7167. @ATTRIBUTE "Minimum (series 3)" numeric
  7168. \end_layout
  7169. \begin_layout Quotation
  7170. \size footnotesize
  7171. @ATTRIBUTE "Minimum (series 4)" numeric
  7172. \end_layout
  7173. \begin_layout Quotation
  7174. \size footnotesize
  7175. @ATTRIBUTE "Minimum (series 5)" numeric
  7176. \end_layout
  7177. \begin_layout Quotation
  7178. \size footnotesize
  7179. @ATTRIBUTE "Range (series 0)" numeric
  7180. \end_layout
  7181. \begin_layout Quotation
  7182. \size footnotesize
  7183. @ATTRIBUTE "Range (series 1)" numeric
  7184. \end_layout
  7185. \begin_layout Quotation
  7186. \size footnotesize
  7187. @ATTRIBUTE "Range (series 2)" numeric
  7188. \end_layout
  7189. \begin_layout Quotation
  7190. \size footnotesize
  7191. @ATTRIBUTE "Range (series 3)" numeric
  7192. \end_layout
  7193. \begin_layout Quotation
  7194. \size footnotesize
  7195. @ATTRIBUTE "Range (series 4)" numeric
  7196. \end_layout
  7197. \begin_layout Quotation
  7198. \size footnotesize
  7199. @ATTRIBUTE "Range (series 5)" numeric
  7200. \end_layout
  7201. \begin_layout Quotation
  7202. \size footnotesize
  7203. @ATTRIBUTE classification {CLASSIFIED/VEHICLE/CAR, CLASSIFIED/IDLE/STANDING,
  7204. CLASSIFIED/VEHICLE/BUS, CLASSIFIED/WALKING, CLASSIFIED/IDLE/SITTING, CLASSIFIED
  7205. /WALKING/STAIRS/DOWN, CLASSIFIED/DANCING, CLASSIFIED/WALKING/STAIRS/UP}
  7206. \end_layout
  7207. \begin_layout Quotation
  7208. \size footnotesize
  7209. @DATA
  7210. \end_layout
  7211. \begin_layout Quotation
  7212. \size footnotesize
  7213. 0.44361898, 4.7165775, 8.409821, 10.608887, 10.081055, 16.005371, 5.5162406, 9.479762,
  7214. 11.35937, 15.125, 1.4E-45, 1.4E-45, -0.44361898, 4.7165775, 8.409821, 10.608887,
  7215. -10.081055, -16.005371, -0.19068487, 4.9169455, 8.7034025, 10.9375, -9.875, -15.6875,
  7216. -3.8273177, 1.4437568, 3.4187074, -0.0625, -18.6875, -23.0625, 9.343558, 8.036005,
  7217. 7.940663, 15.1875, 18.6875, 23.0625, CLASSIFIED/VEHICLE/CAR
  7218. \end_layout
  7219. \begin_layout Quotation
  7220. \size footnotesize
  7221. 3.9024422, 2.722155, 8.665946, 12.640137, 3.3691406, 15.688477, 1.4E-45, 4.6036777,
  7222. 15.649779, 15.125, 1.4E-45, 1.4E-45, -3.9024422, 2.722155, 8.665946, 12.640137,
  7223. -3.3691406, -15.688477, -3.840938, 2.7240696, 8.499097, 12.6875, -3.375, -15.6875,
  7224. -7.518432, 1.0351465, 4.69902, 8.75,-5.875, -17.625, 7.518432, 3.5685313, 10.95076,
  7225. 6.375, 5.875, 17.625, CLASSIFIED/VEHICLE/CAR
  7226. \end_layout
  7227. \begin_layout Quotation
  7228. \size footnotesize
  7229. 2.9535933, 1.9287692, 9.193417, 8.516602, 3.9960938, 16.75, 1.4E-45, 3.173541, 14.669114,
  7230. 11.1875, 1.4E-45, 1.4E-45, -2.9535933, 1.9287692, 9.193417, 8.516602, -3.9960938,
  7231. -16.75, -2.901134, 2.083913, 9.275456, 8.5, -3.875, -16.875, -5.0803895, 0.50395286,
  7232. 4.6445384, 5.5625, -6.625, -18.875, 5.0803895, 2.669588, 10.024576, 5.625, 6.625,
  7233. 18.875, CLASSIFIED/VEHICLE/CAR
  7234. \end_layout
  7235. \begin_layout Quotation
  7236. \size footnotesize
  7237. 3.7644293, 0.39350045, 9.493064, 4.345215, 4.4628906, 17.933105, 1.4E-45, 2.002191,
  7238. 15.704261, 10.75, 1.4E-45, 1.4E-45, -3.7644293, 0.39350045, 9.493064, 4.345215,
  7239. -4.4628906, -17.933105, -3.5957718, 0.50395286, 9.493382, 4.8125, -4.375, -17.875,
  7240. -8.567199, -1.3756552, 6.006573, -2.0, -7.125, -20.5625, 8.567199, 3.3778462, 9.697687,
  7241. 12.75, 7.125, 20.5625, CLASSIFIED/VEHICLE/CAR
  7242. \end_layout
  7243. \begin_layout Quotation
  7244. \size footnotesize
  7245. 1.8751402, 2.4263377, 9.45008, 0.78222656, 5.080078, 16.560059, 1.4E-45, 3.8954194,
  7246. 9.874752, 2.625, 1.4E-45, 1.4E-45, -1.8751402, 2.4263377, 9.45008, 0.78222656,
  7247. -5.080078, -16.560059, -1.8387469, 2.587866, 9.425281, 0.9375, -5.125, -16.625,
  7248. -2.4789033, 1.334794, 9.220976, -1.3125, -6.625, -17.875, 2.4789033, 2.5606253,
  7249. 0.65377617, 3.9375, 6.625, 17.875, CLASSIFIED/VEHICLE/CAR
  7250. \end_layout
  7251. \begin_layout Quotation
  7252. \size footnotesize
  7253. 1.7938437, 2.6545851, 9.423793, 0.110839844, 4.611328, 16.045898, 1.4E-45, 4.099725,
  7254. 9.697687, 1.625, 1.4E-45, 1.4E-45, -1.7938437, 2.6545851, 9.423793, 0.110839844,
  7255. -4.611328, -16.045898, -1.8115063, 2.7240696, 9.41166, 0.1875, -4.625, -16.125,
  7256. -2.5333846, 1.4437568, 9.248216, -1.0625, -5.625, -17.375, 2.5333846, 2.655968,
  7257. 0.44947147, 2.6875, 5.625, 17.375, CLASSIFIED/VEHICLE/CAR
  7258. \end_layout
  7259. \begin_layout Standard
  7260. \begin_inset Newpage pagebreak
  7261. \end_inset
  7262. \end_layout
  7263. \begin_layout Section
  7264. User-annotated
  7265. \noun on
  7266. Sensor Logger
  7267. \noun default
  7268. Results
  7269. \begin_inset CommandInset label
  7270. LatexCommand label
  7271. name "sec:User-annotated-Sensor-Logger"
  7272. \end_inset
  7273. \end_layout
  7274. \begin_layout Standard
  7275. \begin_inset Tabular
  7276. <lyxtabular version="3" rows="83" columns="3">
  7277. <features islongtable="true">
  7278. <column alignment="right" valignment="top" width="0">
  7279. <column alignment="left" valignment="top" width="0">
  7280. <column alignment="left" valignment="top" width="0">
  7281. <row endhead="true" endfirsthead="true">
  7282. <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
  7283. \begin_inset Text
  7284. \begin_layout Plain Layout
  7285. \series bold
  7286. Count
  7287. \end_layout
  7288. \end_inset
  7289. </cell>
  7290. <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
  7291. \begin_inset Text
  7292. \begin_layout Plain Layout
  7293. \series bold
  7294. User annotation
  7295. \end_layout
  7296. \end_inset
  7297. </cell>
  7298. <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
  7299. \begin_inset Text
  7300. \begin_layout Plain Layout
  7301. \series bold
  7302. On-device classification
  7303. \end_layout
  7304. \end_inset
  7305. </cell>
  7306. </row>
  7307. <row>
  7308. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  7309. \begin_inset Text
  7310. \begin_layout Plain Layout
  7311. 3
  7312. \end_layout
  7313. \end_inset
  7314. </cell>
  7315. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  7316. \begin_inset Text
  7317. \begin_layout Plain Layout
  7318. \end_layout
  7319. \end_inset
  7320. </cell>
  7321. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  7322. \begin_inset Text
  7323. \begin_layout Plain Layout
  7324. CLASSIFIED/DANCING
  7325. \end_layout
  7326. \end_inset
  7327. </cell>
  7328. </row>
  7329. <row>
  7330. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  7331. \begin_inset Text
  7332. \begin_layout Plain Layout
  7333. 6
  7334. \end_layout
  7335. \end_inset
  7336. </cell>
  7337. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  7338. \begin_inset Text
  7339. \begin_layout Plain Layout
  7340. \end_layout
  7341. \end_inset
  7342. </cell>
  7343. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  7344. \begin_inset Text
  7345. \begin_layout Plain Layout
  7346. CLASSIFIED/IDLE/SITTING
  7347. \end_layout
  7348. \end_inset
  7349. </cell>
  7350. </row>
  7351. <row>
  7352. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  7353. \begin_inset Text
  7354. \begin_layout Plain Layout
  7355. 2
  7356. \end_layout
  7357. \end_inset
  7358. </cell>
  7359. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  7360. \begin_inset Text
  7361. \begin_layout Plain Layout
  7362. \end_layout
  7363. \end_inset
  7364. </cell>
  7365. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  7366. \begin_inset Text
  7367. \begin_layout Plain Layout
  7368. CLASSIFIED/IDLE/STANDING
  7369. \end_layout
  7370. \end_inset
  7371. </cell>
  7372. </row>
  7373. <row>
  7374. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  7375. \begin_inset Text
  7376. \begin_layout Plain Layout
  7377. 9
  7378. \end_layout
  7379. \end_inset
  7380. </cell>
  7381. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  7382. \begin_inset Text
  7383. \begin_layout Plain Layout
  7384. \end_layout
  7385. \end_inset
  7386. </cell>
  7387. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  7388. \begin_inset Text
  7389. \begin_layout Plain Layout
  7390. CLASSIFIED/UNKNOWN
  7391. \end_layout
  7392. \end_inset
  7393. </cell>
  7394. </row>
  7395. <row>
  7396. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  7397. \begin_inset Text
  7398. \begin_layout Plain Layout
  7399. 31
  7400. \end_layout
  7401. \end_inset
  7402. </cell>
  7403. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  7404. \begin_inset Text
  7405. \begin_layout Plain Layout
  7406. \end_layout
  7407. \end_inset
  7408. </cell>
  7409. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  7410. \begin_inset Text
  7411. \begin_layout Plain Layout
  7412. CLASSIFIED/VEHICLE/BUS
  7413. \end_layout
  7414. \end_inset
  7415. </cell>
  7416. </row>
  7417. <row>
  7418. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  7419. \begin_inset Text
  7420. \begin_layout Plain Layout
  7421. 11
  7422. \end_layout
  7423. \end_inset
  7424. </cell>
  7425. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  7426. \begin_inset Text
  7427. \begin_layout Plain Layout
  7428. \end_layout
  7429. \end_inset
  7430. </cell>
  7431. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  7432. \begin_inset Text
  7433. \begin_layout Plain Layout
  7434. CLASSIFIED/VEHICLE/CAR
  7435. \end_layout
  7436. \end_inset
  7437. </cell>
  7438. </row>
  7439. <row>
  7440. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  7441. \begin_inset Text
  7442. \begin_layout Plain Layout
  7443. 1
  7444. \end_layout
  7445. \end_inset
  7446. </cell>
  7447. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  7448. \begin_inset Text
  7449. \begin_layout Plain Layout
  7450. 10
  7451. \end_layout
  7452. \end_inset
  7453. </cell>
  7454. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  7455. \begin_inset Text
  7456. \begin_layout Plain Layout
  7457. CLASSIFIED/IDLE/SITTING
  7458. \end_layout
  7459. \end_inset
  7460. </cell>
  7461. </row>
  7462. <row>
  7463. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  7464. \begin_inset Text
  7465. \begin_layout Plain Layout
  7466. 1
  7467. \end_layout
  7468. \end_inset
  7469. </cell>
  7470. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  7471. \begin_inset Text
  7472. \begin_layout Plain Layout
  7473. beed
  7474. \end_layout
  7475. \end_inset
  7476. </cell>
  7477. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  7478. \begin_inset Text
  7479. \begin_layout Plain Layout
  7480. CLASSIFIED/VEHICLE/BUS
  7481. \end_layout
  7482. \end_inset
  7483. </cell>
  7484. </row>
  7485. <row>
  7486. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  7487. \begin_inset Text
  7488. \begin_layout Plain Layout
  7489. 1
  7490. \end_layout
  7491. \end_inset
  7492. </cell>
  7493. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  7494. \begin_inset Text
  7495. \begin_layout Plain Layout
  7496. breathing
  7497. \end_layout
  7498. \end_inset
  7499. </cell>
  7500. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  7501. \begin_inset Text
  7502. \begin_layout Plain Layout
  7503. CLASSIFIED/VEHICLE/BUS
  7504. \end_layout
  7505. \end_inset
  7506. </cell>
  7507. </row>
  7508. <row>
  7509. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  7510. \begin_inset Text
  7511. \begin_layout Plain Layout
  7512. 1
  7513. \end_layout
  7514. \end_inset
  7515. </cell>
  7516. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  7517. \begin_inset Text
  7518. \begin_layout Plain Layout
  7519. cycle
  7520. \end_layout
  7521. \end_inset
  7522. </cell>
  7523. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  7524. \begin_inset Text
  7525. \begin_layout Plain Layout
  7526. CLASSIFIED/VEHICLE/BUS
  7527. \end_layout
  7528. \end_inset
  7529. </cell>
  7530. </row>
  7531. <row>
  7532. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  7533. \begin_inset Text
  7534. \begin_layout Plain Layout
  7535. 1
  7536. \end_layout
  7537. \end_inset
  7538. </cell>
  7539. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  7540. \begin_inset Text
  7541. \begin_layout Plain Layout
  7542. Dancing
  7543. \end_layout
  7544. \end_inset
  7545. </cell>
  7546. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  7547. \begin_inset Text
  7548. \begin_layout Plain Layout
  7549. CLASSIFIED/WALKING
  7550. \end_layout
  7551. \end_inset
  7552. </cell>
  7553. </row>
  7554. <row>
  7555. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  7556. \begin_inset Text
  7557. \begin_layout Plain Layout
  7558. 1
  7559. \end_layout
  7560. \end_inset
  7561. </cell>
  7562. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  7563. \begin_inset Text
  7564. \begin_layout Plain Layout
  7565. driving
  7566. \end_layout
  7567. \end_inset
  7568. </cell>
  7569. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  7570. \begin_inset Text
  7571. \begin_layout Plain Layout
  7572. CLASSIFIED/WALKING/STAIRS/DOWN
  7573. \end_layout
  7574. \end_inset
  7575. </cell>
  7576. </row>
  7577. <row>
  7578. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  7579. \begin_inset Text
  7580. \begin_layout Plain Layout
  7581. 1
  7582. \end_layout
  7583. \end_inset
  7584. </cell>
  7585. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  7586. \begin_inset Text
  7587. \begin_layout Plain Layout
  7588. drunkenly going to the bathroom to pee.
  7589. \end_layout
  7590. \end_inset
  7591. </cell>
  7592. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  7593. \begin_inset Text
  7594. \begin_layout Plain Layout
  7595. CLASSIFIED/VEHICLE/CAR
  7596. \end_layout
  7597. \end_inset
  7598. </cell>
  7599. </row>
  7600. <row>
  7601. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  7602. \begin_inset Text
  7603. \begin_layout Plain Layout
  7604. 1
  7605. \end_layout
  7606. \end_inset
  7607. </cell>
  7608. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  7609. \begin_inset Text
  7610. \begin_layout Plain Layout
  7611. fixing my clothes
  7612. \end_layout
  7613. \end_inset
  7614. </cell>
  7615. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  7616. \begin_inset Text
  7617. \begin_layout Plain Layout
  7618. CLASSIFIED/VEHICLE/BUS
  7619. \end_layout
  7620. \end_inset
  7621. </cell>
  7622. </row>
  7623. <row>
  7624. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  7625. \begin_inset Text
  7626. \begin_layout Plain Layout
  7627. 1
  7628. \end_layout
  7629. \end_inset
  7630. </cell>
  7631. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  7632. \begin_inset Text
  7633. \begin_layout Plain Layout
  7634. hhhg
  7635. \end_layout
  7636. \end_inset
  7637. </cell>
  7638. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  7639. \begin_inset Text
  7640. \begin_layout Plain Layout
  7641. CLASSIFIED/VEHICLE/BUS
  7642. \end_layout
  7643. \end_inset
  7644. </cell>
  7645. </row>
  7646. <row>
  7647. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  7648. \begin_inset Text
  7649. \begin_layout Plain Layout
  7650. 2
  7651. \end_layout
  7652. \end_inset
  7653. </cell>
  7654. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  7655. \begin_inset Text
  7656. \begin_layout Plain Layout
  7657. In a car
  7658. \end_layout
  7659. \end_inset
  7660. </cell>
  7661. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  7662. \begin_inset Text
  7663. \begin_layout Plain Layout
  7664. CLASSIFIED/VEHICLE/BUS
  7665. \end_layout
  7666. \end_inset
  7667. </cell>
  7668. </row>
  7669. <row>
  7670. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  7671. \begin_inset Text
  7672. \begin_layout Plain Layout
  7673. 1
  7674. \end_layout
  7675. \end_inset
  7676. </cell>
  7677. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  7678. \begin_inset Text
  7679. \begin_layout Plain Layout
  7680. in a house
  7681. \end_layout
  7682. \end_inset
  7683. </cell>
  7684. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  7685. \begin_inset Text
  7686. \begin_layout Plain Layout
  7687. CLASSIFIED/VEHICLE/CAR
  7688. \end_layout
  7689. \end_inset
  7690. </cell>
  7691. </row>
  7692. <row>
  7693. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  7694. \begin_inset Text
  7695. \begin_layout Plain Layout
  7696. 4
  7697. \end_layout
  7698. \end_inset
  7699. </cell>
  7700. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  7701. \begin_inset Text
  7702. \begin_layout Plain Layout
  7703. in bed
  7704. \end_layout
  7705. \end_inset
  7706. </cell>
  7707. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  7708. \begin_inset Text
  7709. \begin_layout Plain Layout
  7710. CLASSIFIED/VEHICLE/BUS
  7711. \end_layout
  7712. \end_inset
  7713. </cell>
  7714. </row>
  7715. <row>
  7716. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  7717. \begin_inset Text
  7718. \begin_layout Plain Layout
  7719. 2
  7720. \end_layout
  7721. \end_inset
  7722. </cell>
  7723. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  7724. \begin_inset Text
  7725. \begin_layout Plain Layout
  7726. it is a cat
  7727. \end_layout
  7728. \end_inset
  7729. </cell>
  7730. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  7731. \begin_inset Text
  7732. \begin_layout Plain Layout
  7733. CLASSIFIED/VEHICLE/BUS
  7734. \end_layout
  7735. \end_inset
  7736. </cell>
  7737. </row>
  7738. <row>
  7739. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  7740. \begin_inset Text
  7741. \begin_layout Plain Layout
  7742. 1
  7743. \end_layout
  7744. \end_inset
  7745. </cell>
  7746. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  7747. \begin_inset Text
  7748. \begin_layout Plain Layout
  7749. kitchen work
  7750. \end_layout
  7751. \end_inset
  7752. </cell>
  7753. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  7754. \begin_inset Text
  7755. \begin_layout Plain Layout
  7756. CLASSIFIED/IDLE/STANDING
  7757. \end_layout
  7758. \end_inset
  7759. </cell>
  7760. </row>
  7761. <row>
  7762. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  7763. \begin_inset Text
  7764. \begin_layout Plain Layout
  7765. 1
  7766. \end_layout
  7767. \end_inset
  7768. </cell>
  7769. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  7770. \begin_inset Text
  7771. \begin_layout Plain Layout
  7772. laundry
  7773. \end_layout
  7774. \end_inset
  7775. </cell>
  7776. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  7777. \begin_inset Text
  7778. \begin_layout Plain Layout
  7779. CLASSIFIED/VEHICLE/CAR
  7780. \end_layout
  7781. \end_inset
  7782. </cell>
  7783. </row>
  7784. <row>
  7785. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  7786. \begin_inset Text
  7787. \begin_layout Plain Layout
  7788. 1
  7789. \end_layout
  7790. \end_inset
  7791. </cell>
  7792. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  7793. \begin_inset Text
  7794. \begin_layout Plain Layout
  7795. lay in bed
  7796. \end_layout
  7797. \end_inset
  7798. </cell>
  7799. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  7800. \begin_inset Text
  7801. \begin_layout Plain Layout
  7802. CLASSIFIED/VEHICLE/BUS
  7803. \end_layout
  7804. \end_inset
  7805. </cell>
  7806. </row>
  7807. <row>
  7808. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  7809. \begin_inset Text
  7810. \begin_layout Plain Layout
  7811. 1
  7812. \end_layout
  7813. \end_inset
  7814. </cell>
  7815. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  7816. \begin_inset Text
  7817. \begin_layout Plain Layout
  7818. layin down
  7819. \end_layout
  7820. \end_inset
  7821. </cell>
  7822. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  7823. \begin_inset Text
  7824. \begin_layout Plain Layout
  7825. CLASSIFIED/IDLE/STANDING
  7826. \end_layout
  7827. \end_inset
  7828. </cell>
  7829. </row>
  7830. <row>
  7831. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  7832. \begin_inset Text
  7833. \begin_layout Plain Layout
  7834. 1
  7835. \end_layout
  7836. \end_inset
  7837. </cell>
  7838. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  7839. \begin_inset Text
  7840. \begin_layout Plain Layout
  7841. layin in bed
  7842. \end_layout
  7843. \end_inset
  7844. </cell>
  7845. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  7846. \begin_inset Text
  7847. \begin_layout Plain Layout
  7848. CLASSIFIED/VEHICLE/BUS
  7849. \end_layout
  7850. \end_inset
  7851. </cell>
  7852. </row>
  7853. <row>
  7854. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  7855. \begin_inset Text
  7856. \begin_layout Plain Layout
  7857. 3
  7858. \end_layout
  7859. \end_inset
  7860. </cell>
  7861. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  7862. \begin_inset Text
  7863. \begin_layout Plain Layout
  7864. laying down
  7865. \end_layout
  7866. \end_inset
  7867. </cell>
  7868. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  7869. \begin_inset Text
  7870. \begin_layout Plain Layout
  7871. CLASSIFIED/VEHICLE/BUS
  7872. \end_layout
  7873. \end_inset
  7874. </cell>
  7875. </row>
  7876. <row>
  7877. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  7878. \begin_inset Text
  7879. \begin_layout Plain Layout
  7880. 1
  7881. \end_layout
  7882. \end_inset
  7883. </cell>
  7884. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  7885. \begin_inset Text
  7886. \begin_layout Plain Layout
  7887. laying down
  7888. \end_layout
  7889. \end_inset
  7890. </cell>
  7891. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  7892. \begin_inset Text
  7893. \begin_layout Plain Layout
  7894. CLASSIFIED/VEHICLE/CAR
  7895. \end_layout
  7896. \end_inset
  7897. </cell>
  7898. </row>
  7899. <row>
  7900. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  7901. \begin_inset Text
  7902. \begin_layout Plain Layout
  7903. 1
  7904. \end_layout
  7905. \end_inset
  7906. </cell>
  7907. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  7908. \begin_inset Text
  7909. \begin_layout Plain Layout
  7910. laying down in bed
  7911. \end_layout
  7912. \end_inset
  7913. </cell>
  7914. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  7915. \begin_inset Text
  7916. \begin_layout Plain Layout
  7917. CLASSIFIED/VEHICLE/BUS
  7918. \end_layout
  7919. \end_inset
  7920. </cell>
  7921. </row>
  7922. <row>
  7923. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  7924. \begin_inset Text
  7925. \begin_layout Plain Layout
  7926. 3
  7927. \end_layout
  7928. \end_inset
  7929. </cell>
  7930. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  7931. \begin_inset Text
  7932. \begin_layout Plain Layout
  7933. laying in bed
  7934. \end_layout
  7935. \end_inset
  7936. </cell>
  7937. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  7938. \begin_inset Text
  7939. \begin_layout Plain Layout
  7940. CLASSIFIED/VEHICLE/BUS
  7941. \end_layout
  7942. \end_inset
  7943. </cell>
  7944. </row>
  7945. <row>
  7946. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  7947. \begin_inset Text
  7948. \begin_layout Plain Layout
  7949. 1
  7950. \end_layout
  7951. \end_inset
  7952. </cell>
  7953. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  7954. \begin_inset Text
  7955. \begin_layout Plain Layout
  7956. laying in bed with the phone on my stomach
  7957. \end_layout
  7958. \end_inset
  7959. </cell>
  7960. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  7961. \begin_inset Text
  7962. \begin_layout Plain Layout
  7963. CLASSIFIED/VEHICLE/CAR
  7964. \end_layout
  7965. \end_inset
  7966. </cell>
  7967. </row>
  7968. <row>
  7969. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  7970. \begin_inset Text
  7971. \begin_layout Plain Layout
  7972. 1
  7973. \end_layout
  7974. \end_inset
  7975. </cell>
  7976. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  7977. \begin_inset Text
  7978. \begin_layout Plain Layout
  7979. lie in bed
  7980. \end_layout
  7981. \end_inset
  7982. </cell>
  7983. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  7984. \begin_inset Text
  7985. \begin_layout Plain Layout
  7986. CLASSIFIED/VEHICLE/BUS
  7987. \end_layout
  7988. \end_inset
  7989. </cell>
  7990. </row>
  7991. <row>
  7992. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  7993. \begin_inset Text
  7994. \begin_layout Plain Layout
  7995. 1
  7996. \end_layout
  7997. \end_inset
  7998. </cell>
  7999. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  8000. \begin_inset Text
  8001. \begin_layout Plain Layout
  8002. ligger pa golvet
  8003. \end_layout
  8004. \end_inset
  8005. </cell>
  8006. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  8007. \begin_inset Text
  8008. \begin_layout Plain Layout
  8009. CLASSIFIED/VEHICLE/BUS
  8010. \end_layout
  8011. \end_inset
  8012. </cell>
  8013. </row>
  8014. <row>
  8015. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  8016. \begin_inset Text
  8017. \begin_layout Plain Layout
  8018. 1
  8019. \end_layout
  8020. \end_inset
  8021. </cell>
  8022. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  8023. \begin_inset Text
  8024. \begin_layout Plain Layout
  8025. love
  8026. \end_layout
  8027. \end_inset
  8028. </cell>
  8029. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  8030. \begin_inset Text
  8031. \begin_layout Plain Layout
  8032. CLASSIFIED/VEHICLE/CAR
  8033. \end_layout
  8034. \end_inset
  8035. </cell>
  8036. </row>
  8037. <row>
  8038. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  8039. \begin_inset Text
  8040. \begin_layout Plain Layout
  8041. 1
  8042. \end_layout
  8043. \end_inset
  8044. </cell>
  8045. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  8046. \begin_inset Text
  8047. \begin_layout Plain Layout
  8048. lying in bed
  8049. \end_layout
  8050. \end_inset
  8051. </cell>
  8052. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  8053. \begin_inset Text
  8054. \begin_layout Plain Layout
  8055. CLASSIFIED/VEHICLE/BUS
  8056. \end_layout
  8057. \end_inset
  8058. </cell>
  8059. </row>
  8060. <row>
  8061. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  8062. \begin_inset Text
  8063. \begin_layout Plain Layout
  8064. 1
  8065. \end_layout
  8066. \end_inset
  8067. </cell>
  8068. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  8069. \begin_inset Text
  8070. \begin_layout Plain Layout
  8071. moving phone
  8072. \end_layout
  8073. \end_inset
  8074. </cell>
  8075. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  8076. \begin_inset Text
  8077. \begin_layout Plain Layout
  8078. CLASSIFIED/WALKING
  8079. \end_layout
  8080. \end_inset
  8081. </cell>
  8082. </row>
  8083. <row>
  8084. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  8085. \begin_inset Text
  8086. \begin_layout Plain Layout
  8087. 1
  8088. \end_layout
  8089. \end_inset
  8090. </cell>
  8091. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  8092. \begin_inset Text
  8093. \begin_layout Plain Layout
  8094. Nothing at all!
  8095. \end_layout
  8096. \end_inset
  8097. </cell>
  8098. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  8099. \begin_inset Text
  8100. \begin_layout Plain Layout
  8101. CLASSIFIED/UNKNOWN
  8102. \end_layout
  8103. \end_inset
  8104. </cell>
  8105. </row>
  8106. <row>
  8107. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  8108. \begin_inset Text
  8109. \begin_layout Plain Layout
  8110. 1
  8111. \end_layout
  8112. \end_inset
  8113. </cell>
  8114. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  8115. \begin_inset Text
  8116. \begin_layout Plain Layout
  8117. passenger in car straight road 50mph
  8118. \end_layout
  8119. \end_inset
  8120. </cell>
  8121. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  8122. \begin_inset Text
  8123. \begin_layout Plain Layout
  8124. CLASSIFIED/VEHICLE/BUS
  8125. \end_layout
  8126. \end_inset
  8127. </cell>
  8128. </row>
  8129. <row>
  8130. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  8131. \begin_inset Text
  8132. \begin_layout Plain Layout
  8133. 1
  8134. \end_layout
  8135. \end_inset
  8136. </cell>
  8137. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  8138. \begin_inset Text
  8139. \begin_layout Plain Layout
  8140. playin gamw
  8141. \end_layout
  8142. \end_inset
  8143. </cell>
  8144. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  8145. \begin_inset Text
  8146. \begin_layout Plain Layout
  8147. CLASSIFIED/VEHICLE/BUS
  8148. \end_layout
  8149. \end_inset
  8150. </cell>
  8151. </row>
  8152. <row>
  8153. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  8154. \begin_inset Text
  8155. \begin_layout Plain Layout
  8156. 1
  8157. \end_layout
  8158. \end_inset
  8159. </cell>
  8160. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  8161. \begin_inset Text
  8162. \begin_layout Plain Layout
  8163. pooping
  8164. \end_layout
  8165. \end_inset
  8166. </cell>
  8167. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  8168. \begin_inset Text
  8169. \begin_layout Plain Layout
  8170. CLASSIFIED/UNKNOWN
  8171. \end_layout
  8172. \end_inset
  8173. </cell>
  8174. </row>
  8175. <row>
  8176. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  8177. \begin_inset Text
  8178. \begin_layout Plain Layout
  8179. 1
  8180. \end_layout
  8181. \end_inset
  8182. </cell>
  8183. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  8184. \begin_inset Text
  8185. \begin_layout Plain Layout
  8186. Rolling around
  8187. \end_layout
  8188. \end_inset
  8189. </cell>
  8190. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  8191. \begin_inset Text
  8192. \begin_layout Plain Layout
  8193. CLASSIFIED/WALKING
  8194. \end_layout
  8195. \end_inset
  8196. </cell>
  8197. </row>
  8198. <row>
  8199. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  8200. \begin_inset Text
  8201. \begin_layout Plain Layout
  8202. 1
  8203. \end_layout
  8204. \end_inset
  8205. </cell>
  8206. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  8207. \begin_inset Text
  8208. \begin_layout Plain Layout
  8209. Rotating the phone
  8210. \end_layout
  8211. \end_inset
  8212. </cell>
  8213. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  8214. \begin_inset Text
  8215. \begin_layout Plain Layout
  8216. CLASSIFIED/WALKING/STAIRS/UP
  8217. \end_layout
  8218. \end_inset
  8219. </cell>
  8220. </row>
  8221. <row>
  8222. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  8223. \begin_inset Text
  8224. \begin_layout Plain Layout
  8225. 1
  8226. \end_layout
  8227. \end_inset
  8228. </cell>
  8229. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  8230. \begin_inset Text
  8231. \begin_layout Plain Layout
  8232. seating down
  8233. \end_layout
  8234. \end_inset
  8235. </cell>
  8236. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  8237. \begin_inset Text
  8238. \begin_layout Plain Layout
  8239. CLASSIFIED/VEHICLE/BUS
  8240. \end_layout
  8241. \end_inset
  8242. </cell>
  8243. </row>
  8244. <row>
  8245. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  8246. \begin_inset Text
  8247. \begin_layout Plain Layout
  8248. 1
  8249. \end_layout
  8250. \end_inset
  8251. </cell>
  8252. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  8253. \begin_inset Text
  8254. \begin_layout Plain Layout
  8255. seting
  8256. \end_layout
  8257. \end_inset
  8258. </cell>
  8259. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  8260. \begin_inset Text
  8261. \begin_layout Plain Layout
  8262. CLASSIFIED/VEHICLE/BUS
  8263. \end_layout
  8264. \end_inset
  8265. </cell>
  8266. </row>
  8267. <row>
  8268. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  8269. \begin_inset Text
  8270. \begin_layout Plain Layout
  8271. 1
  8272. \end_layout
  8273. \end_inset
  8274. </cell>
  8275. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  8276. \begin_inset Text
  8277. \begin_layout Plain Layout
  8278. shake the device
  8279. \end_layout
  8280. \end_inset
  8281. </cell>
  8282. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  8283. \begin_inset Text
  8284. \begin_layout Plain Layout
  8285. CLASSIFIED/VEHICLE/CAR
  8286. \end_layout
  8287. \end_inset
  8288. </cell>
  8289. </row>
  8290. <row>
  8291. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  8292. \begin_inset Text
  8293. \begin_layout Plain Layout
  8294. 1
  8295. \end_layout
  8296. \end_inset
  8297. </cell>
  8298. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  8299. \begin_inset Text
  8300. \begin_layout Plain Layout
  8301. shaking my leg sitting on my bed
  8302. \end_layout
  8303. \end_inset
  8304. </cell>
  8305. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  8306. \begin_inset Text
  8307. \begin_layout Plain Layout
  8308. CLASSIFIED/VEHICLE/BUS
  8309. \end_layout
  8310. \end_inset
  8311. </cell>
  8312. </row>
  8313. <row>
  8314. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  8315. \begin_inset Text
  8316. \begin_layout Plain Layout
  8317. 1
  8318. \end_layout
  8319. \end_inset
  8320. </cell>
  8321. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  8322. \begin_inset Text
  8323. \begin_layout Plain Layout
  8324. shaking phone violently!!!
  8325. \end_layout
  8326. \end_inset
  8327. </cell>
  8328. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  8329. \begin_inset Text
  8330. \begin_layout Plain Layout
  8331. CLASSIFIED/WALKING/STAIRS/UP
  8332. \end_layout
  8333. \end_inset
  8334. </cell>
  8335. </row>
  8336. <row>
  8337. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  8338. \begin_inset Text
  8339. \begin_layout Plain Layout
  8340. 1
  8341. \end_layout
  8342. \end_inset
  8343. </cell>
  8344. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  8345. \begin_inset Text
  8346. \begin_layout Plain Layout
  8347. siq
  8348. \end_layout
  8349. \end_inset
  8350. </cell>
  8351. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  8352. \begin_inset Text
  8353. \begin_layout Plain Layout
  8354. CLASSIFIED/VEHICLE/BUS
  8355. \end_layout
  8356. \end_inset
  8357. </cell>
  8358. </row>
  8359. <row>
  8360. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  8361. \begin_inset Text
  8362. \begin_layout Plain Layout
  8363. 1
  8364. \end_layout
  8365. \end_inset
  8366. </cell>
  8367. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  8368. \begin_inset Text
  8369. \begin_layout Plain Layout
  8370. sitti
  8371. \end_layout
  8372. \end_inset
  8373. </cell>
  8374. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  8375. \begin_inset Text
  8376. \begin_layout Plain Layout
  8377. CLASSIFIED/VEHICLE/BUS
  8378. \end_layout
  8379. \end_inset
  8380. </cell>
  8381. </row>
  8382. <row>
  8383. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  8384. \begin_inset Text
  8385. \begin_layout Plain Layout
  8386. 1
  8387. \end_layout
  8388. \end_inset
  8389. </cell>
  8390. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  8391. \begin_inset Text
  8392. \begin_layout Plain Layout
  8393. Sitting
  8394. \end_layout
  8395. \end_inset
  8396. </cell>
  8397. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  8398. \begin_inset Text
  8399. \begin_layout Plain Layout
  8400. CLASSIFIED/IDLE/SITTING
  8401. \end_layout
  8402. \end_inset
  8403. </cell>
  8404. </row>
  8405. <row>
  8406. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  8407. \begin_inset Text
  8408. \begin_layout Plain Layout
  8409. 1
  8410. \end_layout
  8411. \end_inset
  8412. </cell>
  8413. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  8414. \begin_inset Text
  8415. \begin_layout Plain Layout
  8416. Sitting
  8417. \end_layout
  8418. \end_inset
  8419. </cell>
  8420. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  8421. \begin_inset Text
  8422. \begin_layout Plain Layout
  8423. CLASSIFIED/IDLE/STANDING
  8424. \end_layout
  8425. \end_inset
  8426. </cell>
  8427. </row>
  8428. <row>
  8429. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  8430. \begin_inset Text
  8431. \begin_layout Plain Layout
  8432. 19
  8433. \end_layout
  8434. \end_inset
  8435. </cell>
  8436. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  8437. \begin_inset Text
  8438. \begin_layout Plain Layout
  8439. Sitting
  8440. \end_layout
  8441. \end_inset
  8442. </cell>
  8443. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  8444. \begin_inset Text
  8445. \begin_layout Plain Layout
  8446. CLASSIFIED/VEHICLE/BUS
  8447. \end_layout
  8448. \end_inset
  8449. </cell>
  8450. </row>
  8451. <row>
  8452. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  8453. \begin_inset Text
  8454. \begin_layout Plain Layout
  8455. 6
  8456. \end_layout
  8457. \end_inset
  8458. </cell>
  8459. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  8460. \begin_inset Text
  8461. \begin_layout Plain Layout
  8462. Sitting
  8463. \end_layout
  8464. \end_inset
  8465. </cell>
  8466. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  8467. \begin_inset Text
  8468. \begin_layout Plain Layout
  8469. CLASSIFIED/VEHICLE/CAR
  8470. \end_layout
  8471. \end_inset
  8472. </cell>
  8473. </row>
  8474. <row>
  8475. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  8476. \begin_inset Text
  8477. \begin_layout Plain Layout
  8478. 1
  8479. \end_layout
  8480. \end_inset
  8481. </cell>
  8482. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  8483. \begin_inset Text
  8484. \begin_layout Plain Layout
  8485. sitting at my desk
  8486. \end_layout
  8487. \end_inset
  8488. </cell>
  8489. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  8490. \begin_inset Text
  8491. \begin_layout Plain Layout
  8492. CLASSIFIED/VEHICLE/BUS
  8493. \end_layout
  8494. \end_inset
  8495. </cell>
  8496. </row>
  8497. <row>
  8498. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  8499. \begin_inset Text
  8500. \begin_layout Plain Layout
  8501. 1
  8502. \end_layout
  8503. \end_inset
  8504. </cell>
  8505. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  8506. \begin_inset Text
  8507. \begin_layout Plain Layout
  8508. Sitting down
  8509. \end_layout
  8510. \end_inset
  8511. </cell>
  8512. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  8513. \begin_inset Text
  8514. \begin_layout Plain Layout
  8515. CLASSIFIED/VEHICLE/BUS
  8516. \end_layout
  8517. \end_inset
  8518. </cell>
  8519. </row>
  8520. <row>
  8521. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  8522. \begin_inset Text
  8523. \begin_layout Plain Layout
  8524. 1
  8525. \end_layout
  8526. \end_inset
  8527. </cell>
  8528. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  8529. \begin_inset Text
  8530. \begin_layout Plain Layout
  8531. sitting on my ass
  8532. \end_layout
  8533. \end_inset
  8534. </cell>
  8535. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  8536. \begin_inset Text
  8537. \begin_layout Plain Layout
  8538. CLASSIFIED/VEHICLE/CAR
  8539. \end_layout
  8540. \end_inset
  8541. </cell>
  8542. </row>
  8543. <row>
  8544. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  8545. \begin_inset Text
  8546. \begin_layout Plain Layout
  8547. 1
  8548. \end_layout
  8549. \end_inset
  8550. </cell>
  8551. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  8552. \begin_inset Text
  8553. \begin_layout Plain Layout
  8554. sitting on the couch
  8555. \end_layout
  8556. \end_inset
  8557. </cell>
  8558. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  8559. \begin_inset Text
  8560. \begin_layout Plain Layout
  8561. CLASSIFIED/VEHICLE/BUS
  8562. \end_layout
  8563. \end_inset
  8564. </cell>
  8565. </row>
  8566. <row>
  8567. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  8568. \begin_inset Text
  8569. \begin_layout Plain Layout
  8570. 1
  8571. \end_layout
  8572. \end_inset
  8573. </cell>
  8574. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  8575. \begin_inset Text
  8576. \begin_layout Plain Layout
  8577. sjxjxgzog
  8578. \end_layout
  8579. \end_inset
  8580. </cell>
  8581. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  8582. \begin_inset Text
  8583. \begin_layout Plain Layout
  8584. CLASSIFIED/VEHICLE/BUS
  8585. \end_layout
  8586. \end_inset
  8587. </cell>
  8588. </row>
  8589. <row>
  8590. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  8591. \begin_inset Text
  8592. \begin_layout Plain Layout
  8593. 1
  8594. \end_layout
  8595. \end_inset
  8596. </cell>
  8597. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  8598. \begin_inset Text
  8599. \begin_layout Plain Layout
  8600. sleep
  8601. \end_layout
  8602. \end_inset
  8603. </cell>
  8604. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  8605. \begin_inset Text
  8606. \begin_layout Plain Layout
  8607. CLASSIFIED/IDLE/SITTING
  8608. \end_layout
  8609. \end_inset
  8610. </cell>
  8611. </row>
  8612. <row>
  8613. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  8614. \begin_inset Text
  8615. \begin_layout Plain Layout
  8616. 2
  8617. \end_layout
  8618. \end_inset
  8619. </cell>
  8620. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  8621. \begin_inset Text
  8622. \begin_layout Plain Layout
  8623. sleeping
  8624. \end_layout
  8625. \end_inset
  8626. </cell>
  8627. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  8628. \begin_inset Text
  8629. \begin_layout Plain Layout
  8630. CLASSIFIED/VEHICLE/BUS
  8631. \end_layout
  8632. \end_inset
  8633. </cell>
  8634. </row>
  8635. <row>
  8636. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  8637. \begin_inset Text
  8638. \begin_layout Plain Layout
  8639. 1
  8640. \end_layout
  8641. \end_inset
  8642. </cell>
  8643. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  8644. \begin_inset Text
  8645. \begin_layout Plain Layout
  8646. Standing
  8647. \end_layout
  8648. \end_inset
  8649. </cell>
  8650. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  8651. \begin_inset Text
  8652. \begin_layout Plain Layout
  8653. CLASSIFIED/VEHICLE/BUS
  8654. \end_layout
  8655. \end_inset
  8656. </cell>
  8657. </row>
  8658. <row>
  8659. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  8660. \begin_inset Text
  8661. \begin_layout Plain Layout
  8662. 1
  8663. \end_layout
  8664. \end_inset
  8665. </cell>
  8666. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  8667. \begin_inset Text
  8668. \begin_layout Plain Layout
  8669. Standing
  8670. \end_layout
  8671. \end_inset
  8672. </cell>
  8673. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  8674. \begin_inset Text
  8675. \begin_layout Plain Layout
  8676. CLASSIFIED/VEHICLE/CAR
  8677. \end_layout
  8678. \end_inset
  8679. </cell>
  8680. </row>
  8681. <row>
  8682. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  8683. \begin_inset Text
  8684. \begin_layout Plain Layout
  8685. 1
  8686. \end_layout
  8687. \end_inset
  8688. </cell>
  8689. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  8690. \begin_inset Text
  8691. \begin_layout Plain Layout
  8692. swinging
  8693. \end_layout
  8694. \end_inset
  8695. </cell>
  8696. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  8697. \begin_inset Text
  8698. \begin_layout Plain Layout
  8699. CLASSIFIED/IDLE/SITTING
  8700. \end_layout
  8701. \end_inset
  8702. </cell>
  8703. </row>
  8704. <row>
  8705. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  8706. \begin_inset Text
  8707. \begin_layout Plain Layout
  8708. 1
  8709. \end_layout
  8710. \end_inset
  8711. </cell>
  8712. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  8713. \begin_inset Text
  8714. \begin_layout Plain Layout
  8715. test
  8716. \end_layout
  8717. \end_inset
  8718. </cell>
  8719. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  8720. \begin_inset Text
  8721. \begin_layout Plain Layout
  8722. CLASSIFIED/VEHICLE/CAR
  8723. \end_layout
  8724. \end_inset
  8725. </cell>
  8726. </row>
  8727. <row>
  8728. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  8729. \begin_inset Text
  8730. \begin_layout Plain Layout
  8731. 2
  8732. \end_layout
  8733. \end_inset
  8734. </cell>
  8735. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  8736. \begin_inset Text
  8737. \begin_layout Plain Layout
  8738. train
  8739. \end_layout
  8740. \end_inset
  8741. </cell>
  8742. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  8743. \begin_inset Text
  8744. \begin_layout Plain Layout
  8745. CLASSIFIED/VEHICLE/BUS
  8746. \end_layout
  8747. \end_inset
  8748. </cell>
  8749. </row>
  8750. <row>
  8751. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  8752. \begin_inset Text
  8753. \begin_layout Plain Layout
  8754. 1
  8755. \end_layout
  8756. \end_inset
  8757. </cell>
  8758. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  8759. \begin_inset Text
  8760. \begin_layout Plain Layout
  8761. traveling by bus
  8762. \end_layout
  8763. \end_inset
  8764. </cell>
  8765. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  8766. \begin_inset Text
  8767. \begin_layout Plain Layout
  8768. CLASSIFIED/VEHICLE/CAR
  8769. \end_layout
  8770. \end_inset
  8771. </cell>
  8772. </row>
  8773. <row>
  8774. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  8775. \begin_inset Text
  8776. \begin_layout Plain Layout
  8777. 1
  8778. \end_layout
  8779. \end_inset
  8780. </cell>
  8781. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  8782. \begin_inset Text
  8783. \begin_layout Plain Layout
  8784. traveling by car
  8785. \end_layout
  8786. \end_inset
  8787. </cell>
  8788. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  8789. \begin_inset Text
  8790. \begin_layout Plain Layout
  8791. CLASSIFIED/VEHICLE/BUS
  8792. \end_layout
  8793. \end_inset
  8794. </cell>
  8795. </row>
  8796. <row>
  8797. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  8798. \begin_inset Text
  8799. \begin_layout Plain Layout
  8800. 1
  8801. \end_layout
  8802. \end_inset
  8803. </cell>
  8804. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  8805. \begin_inset Text
  8806. \begin_layout Plain Layout
  8807. travelling by bus
  8808. \end_layout
  8809. \end_inset
  8810. </cell>
  8811. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  8812. \begin_inset Text
  8813. \begin_layout Plain Layout
  8814. CLASSIFIED/VEHICLE/CAR
  8815. \end_layout
  8816. \end_inset
  8817. </cell>
  8818. </row>
  8819. <row>
  8820. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  8821. \begin_inset Text
  8822. \begin_layout Plain Layout
  8823. 2
  8824. \end_layout
  8825. \end_inset
  8826. </cell>
  8827. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  8828. \begin_inset Text
  8829. \begin_layout Plain Layout
  8830. travelling by s line
  8831. \end_layout
  8832. \end_inset
  8833. </cell>
  8834. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  8835. \begin_inset Text
  8836. \begin_layout Plain Layout
  8837. CLASSIFIED/VEHICLE/BUS
  8838. \end_layout
  8839. \end_inset
  8840. </cell>
  8841. </row>
  8842. <row>
  8843. <cell alignment="right" valignment="top" topline="true" leftline="true" usebox="none">
  8844. \begin_inset Text
  8845. \begin_layout Plain Layout
  8846. 3
  8847. \end_layout
  8848. \end_inset
  8849. </cell>
  8850. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  8851. \begin_inset Text
  8852. \begin_layout Plain Layout
  8853. UNCLASSIFIED/NOTCORRECTED
  8854. \end_layout
  8855. \end_inset
  8856. </cell>
  8857. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  8858. \begin_inset Text
  8859. \begin_layout Plain Layout
  8860. CLASSIFIED/DANCING
  8861. \end_layout
  8862. \end_inset
  8863. </cell>
  8864. </row>
  8865. <row>
  8866. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  8867. \begin_inset Text
  8868. \begin_layout Plain Layout
  8869. 69
  8870. \end_layout
  8871. \end_inset
  8872. </cell>
  8873. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  8874. \begin_inset Text
  8875. \begin_layout Plain Layout
  8876. UNCLASSIFIED/NOTCORRECTED
  8877. \end_layout
  8878. \end_inset
  8879. </cell>
  8880. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  8881. \begin_inset Text
  8882. \begin_layout Plain Layout
  8883. CLASSIFIED/IDLE/SITTING
  8884. \end_layout
  8885. \end_inset
  8886. </cell>
  8887. </row>
  8888. <row>
  8889. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  8890. \begin_inset Text
  8891. \begin_layout Plain Layout
  8892. 29
  8893. \end_layout
  8894. \end_inset
  8895. </cell>
  8896. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  8897. \begin_inset Text
  8898. \begin_layout Plain Layout
  8899. UNCLASSIFIED/NOTCORRECTED
  8900. \end_layout
  8901. \end_inset
  8902. </cell>
  8903. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  8904. \begin_inset Text
  8905. \begin_layout Plain Layout
  8906. CLASSIFIED/IDLE/STANDING
  8907. \end_layout
  8908. \end_inset
  8909. </cell>
  8910. </row>
  8911. <row>
  8912. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  8913. \begin_inset Text
  8914. \begin_layout Plain Layout
  8915. 32
  8916. \end_layout
  8917. \end_inset
  8918. </cell>
  8919. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  8920. \begin_inset Text
  8921. \begin_layout Plain Layout
  8922. UNCLASSIFIED/NOTCORRECTED
  8923. \end_layout
  8924. \end_inset
  8925. </cell>
  8926. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  8927. \begin_inset Text
  8928. \begin_layout Plain Layout
  8929. CLASSIFIED/VEHICLE/BUS
  8930. \end_layout
  8931. \end_inset
  8932. </cell>
  8933. </row>
  8934. <row>
  8935. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  8936. \begin_inset Text
  8937. \begin_layout Plain Layout
  8938. 14
  8939. \end_layout
  8940. \end_inset
  8941. </cell>
  8942. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  8943. \begin_inset Text
  8944. \begin_layout Plain Layout
  8945. UNCLASSIFIED/NOTCORRECTED
  8946. \end_layout
  8947. \end_inset
  8948. </cell>
  8949. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  8950. \begin_inset Text
  8951. \begin_layout Plain Layout
  8952. CLASSIFIED/VEHICLE/CAR
  8953. \end_layout
  8954. \end_inset
  8955. </cell>
  8956. </row>
  8957. <row>
  8958. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  8959. \begin_inset Text
  8960. \begin_layout Plain Layout
  8961. 16
  8962. \end_layout
  8963. \end_inset
  8964. </cell>
  8965. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  8966. \begin_inset Text
  8967. \begin_layout Plain Layout
  8968. UNCLASSIFIED/NOTCORRECTED
  8969. \end_layout
  8970. \end_inset
  8971. </cell>
  8972. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  8973. \begin_inset Text
  8974. \begin_layout Plain Layout
  8975. CLASSIFIED/WALKING
  8976. \end_layout
  8977. \end_inset
  8978. </cell>
  8979. </row>
  8980. <row>
  8981. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  8982. \begin_inset Text
  8983. \begin_layout Plain Layout
  8984. 5
  8985. \end_layout
  8986. \end_inset
  8987. </cell>
  8988. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  8989. \begin_inset Text
  8990. \begin_layout Plain Layout
  8991. Walking
  8992. \end_layout
  8993. \end_inset
  8994. </cell>
  8995. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  8996. \begin_inset Text
  8997. \begin_layout Plain Layout
  8998. CLASSIFIED/VEHICLE/BUS
  8999. \end_layout
  9000. \end_inset
  9001. </cell>
  9002. </row>
  9003. <row>
  9004. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  9005. \begin_inset Text
  9006. \begin_layout Plain Layout
  9007. 1
  9008. \end_layout
  9009. \end_inset
  9010. </cell>
  9011. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  9012. \begin_inset Text
  9013. \begin_layout Plain Layout
  9014. Walking
  9015. \end_layout
  9016. \end_inset
  9017. </cell>
  9018. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  9019. \begin_inset Text
  9020. \begin_layout Plain Layout
  9021. CLASSIFIED/VEHICLE/CAR
  9022. \end_layout
  9023. \end_inset
  9024. </cell>
  9025. </row>
  9026. <row>
  9027. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  9028. \begin_inset Text
  9029. \begin_layout Plain Layout
  9030. 1
  9031. \end_layout
  9032. \end_inset
  9033. </cell>
  9034. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  9035. \begin_inset Text
  9036. \begin_layout Plain Layout
  9037. Walking (downs tairs)
  9038. \end_layout
  9039. \end_inset
  9040. </cell>
  9041. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  9042. \begin_inset Text
  9043. \begin_layout Plain Layout
  9044. CLASSIFIED/WALKING/STAIRS/UP
  9045. \end_layout
  9046. \end_inset
  9047. </cell>
  9048. </row>
  9049. <row>
  9050. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  9051. \begin_inset Text
  9052. \begin_layout Plain Layout
  9053. 1
  9054. \end_layout
  9055. \end_inset
  9056. </cell>
  9057. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  9058. \begin_inset Text
  9059. \begin_layout Plain Layout
  9060. walking in a store
  9061. \end_layout
  9062. \end_inset
  9063. </cell>
  9064. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  9065. \begin_inset Text
  9066. \begin_layout Plain Layout
  9067. CLASSIFIED/VEHICLE/CAR
  9068. \end_layout
  9069. \end_inset
  9070. </cell>
  9071. </row>
  9072. <row>
  9073. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  9074. \begin_inset Text
  9075. \begin_layout Plain Layout
  9076. 1
  9077. \end_layout
  9078. \end_inset
  9079. </cell>
  9080. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  9081. \begin_inset Text
  9082. \begin_layout Plain Layout
  9083. walking in circles
  9084. \end_layout
  9085. \end_inset
  9086. </cell>
  9087. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  9088. \begin_inset Text
  9089. \begin_layout Plain Layout
  9090. CLASSIFIED/VEHICLE/CAR
  9091. \end_layout
  9092. \end_inset
  9093. </cell>
  9094. </row>
  9095. <row>
  9096. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  9097. \begin_inset Text
  9098. \begin_layout Plain Layout
  9099. 1
  9100. \end_layout
  9101. \end_inset
  9102. </cell>
  9103. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  9104. \begin_inset Text
  9105. \begin_layout Plain Layout
  9106. watching amovie!
  9107. \end_layout
  9108. \end_inset
  9109. </cell>
  9110. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  9111. \begin_inset Text
  9112. \begin_layout Plain Layout
  9113. CLASSIFIED/VEHICLE/BUS
  9114. \end_layout
  9115. \end_inset
  9116. </cell>
  9117. </row>
  9118. <row>
  9119. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  9120. \begin_inset Text
  9121. \begin_layout Plain Layout
  9122. 1
  9123. \end_layout
  9124. \end_inset
  9125. </cell>
  9126. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  9127. \begin_inset Text
  9128. \begin_layout Plain Layout
  9129. watching TV
  9130. \end_layout
  9131. \end_inset
  9132. </cell>
  9133. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  9134. \begin_inset Text
  9135. \begin_layout Plain Layout
  9136. CLASSIFIED/VEHICLE/BUS
  9137. \end_layout
  9138. \end_inset
  9139. </cell>
  9140. </row>
  9141. <row>
  9142. <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
  9143. \begin_inset Text
  9144. \begin_layout Plain Layout
  9145. 1
  9146. \end_layout
  9147. \end_inset
  9148. </cell>
  9149. <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
  9150. \begin_inset Text
  9151. \begin_layout Plain Layout
  9152. work in the airport
  9153. \end_layout
  9154. \end_inset
  9155. </cell>
  9156. <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
  9157. \begin_inset Text
  9158. \begin_layout Plain Layout
  9159. CLASSIFIED/VEHICLE/CAR
  9160. \end_layout
  9161. \end_inset
  9162. </cell>
  9163. </row>
  9164. <row>
  9165. <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
  9166. \begin_inset Text
  9167. \begin_layout Plain Layout
  9168. 1
  9169. \end_layout
  9170. \end_inset
  9171. </cell>
  9172. <cell alignment="left" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
  9173. \begin_inset Text
  9174. \begin_layout Plain Layout
  9175. z
  9176. \end_layout
  9177. \end_inset
  9178. </cell>
  9179. <cell alignment="left" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
  9180. \begin_inset Text
  9181. \begin_layout Plain Layout
  9182. CLASSIFIED/VEHICLE/BUS
  9183. \end_layout
  9184. \end_inset
  9185. </cell>
  9186. </row>
  9187. </lyxtabular>
  9188. \end_inset
  9189. \end_layout
  9190. \begin_layout Standard
  9191. \begin_inset Float table
  9192. placement H
  9193. wide false
  9194. sideways false
  9195. status open
  9196. \begin_layout Plain Layout
  9197. \begin_inset Caption
  9198. \begin_layout Plain Layout
  9199. User-annotated
  9200. \noun on
  9201. Sensor Logger
  9202. \noun default
  9203. results
  9204. \begin_inset CommandInset label
  9205. LatexCommand label
  9206. name "tab:User-annotated-Sensor-Logger"
  9207. \end_inset
  9208. \end_layout
  9209. \end_inset
  9210. \end_layout
  9211. \end_inset
  9212. \end_layout
  9213. \begin_layout Standard
  9214. \begin_inset Newpage pagebreak
  9215. \end_inset
  9216. \begin_inset CommandInset bibtex
  9217. LatexCommand bibtex
  9218. bibfiles "/home/chris/Projects/Java/ContextApi/papers/project"
  9219. options "bibtotoc,savetrees"
  9220. \end_inset
  9221. \end_layout
  9222. \end_body
  9223. \end_document