Upload
others
View
1
Download
0
Embed Size (px)
Citation preview
1
More Model-Driven Processing inSensor Networks
Jun Yang
CPS 296.1, Spring 2007
Sensor Data ProcessingWith contents from A. Deshpande
2
Announcements (Feb. 8)
Course project milestone 1: March 1
Reading for next Tuesday (review): directed diffusion
3
More model-driven processing
Amol Deshpande, Carlos Guestrin, Samuel Madden, Joseph M. Hellerstein, and Wei Hong. “Model-Driven Data Acquisition in Sensor Networks.” International Conference on Data Engineering, 2006
Yannis Kotidis. “Snapshot Queries: Towards Data-Centric Sensor Networks.” International Conference on Data Engineering, 2005
2
4
Ken
Forget about fancy queries—many sensor network users still want to collect all data
As in BBQ: exploit correlations in data
What’s different from BBQ?Use model to optimize transmission, but not to avoid acquisition
• Don’t transmit if reading predicted by model
5
Models for prediction
space
model ([input] ...) → predicted value
I know samples from other nodes:
…, Xit-2, Xit-1,
Xkt, Xmt, Xnt,…
My guess for the new sensor samples is…
Xit+1Xit
I know past samples from this node:time
6
A simple example
node i
base station
model23±0.5oC
23oC
23±0.5oC23oC
23oC
23.2oC
23oC
23.4oC
23oC
24oC
24oC
24oC
24±0.5oC
24±0.5oC
sampled value
(Transition) model: value predicted at t+1 ← value predicted at tSource reporting rule:
report if |actual – predicted| ≥ εModel update rule:
use actual if report receivedGuarantee:
|actual – predicted| < ε
Another possibility: A linear model
Xt+1 = a Xt + b
3
7
From temporal to spatiotemporal
1 node
no spatial correlations
entire network
full spatial correlations
Ken explores the spectrum between these two
What’s the trade-off?
8
Some detailsIn each time step…
Apply transition model to get p(Xt+1), conditioned on all observations transmitted to sink
Caution: not all observations!
Source: Compute Xt+1 using p(Xt+1)If ∀i: |xit+1 – xit+1|< ε, stopOtherwise, send to sink the smallest subset of values such that conditioning on it makes predictions accurate
Sink:Condition p on values received from source (if any)Compute Xt+1 using p(Xt+1)
9
Example: disjoint cliques
Nodes form cliques with roots
In each time stepNodes in a clique transmit to clique root
Clique root runs model (mirrored at base station) and decides which readings (if any) to transmit to base station
4
10
Optimizing disjoint cliques
What to consider
How to compute data reduction factorUse the model (poor model gives suboptimal cliques)
Done compile-time, at base stationNP-hard; use exhaustive or heuristic search
11
Example: average model
When would this model work well?
12
Experiment results
Ignores model maintenance(why?)
5
13
DiscussionMain concern of BBQ addressed
Suppression driven by in-network modelsNo longer trust model completelyCan handle outliersThough detecting node failures again depends on good models
14
Snapshot queries
Target one-time queries instead of continuous ones
IdeasUse a subset of nodes (representatives) to represent their neighbors to within ±T
• Queries contact fewer nodes
Rep Ni has a model for each Nj it represents
• Requires communication between Ni and Nj to maintain
15
Model maintenance
Rep Ni “caches” recent readings from NjModel obtained by fitting a line through all available (xis, xjs) pairs: xjt = ai, j xit + bi, jCache replacement policy considers benefit of caching a pair and cost of evicting a pair, in terms of prediction error
6
16
Selecting and maintaining reps
Rep discovery is fully distributedNodes broadcast values & signal they’re looking for reps
Nodes with values within ±T of xj add Nj as a candidate
Nodes broadcast their lists of candidates
Node Nj picks the node with the longest list containing Nj to be its rep, and let that node know
+ Some refinement logic
A node Nj represented by Ni periodically sends a heartbeat message to Ni asking for its estimate
If estimate out of bound or no reply, select a new rep
17
Comparison with BBQ/KenHow are the models used?
Where are the models?
Are models replicated?
How complex are the models?
How are the models built?
Who answers queries?
18
Discussion