Transcript
Page 1: Querying Mobile Objects in Spatio-Temporal Databases

Querying Mobile Objects in Spatio-Temporal Databases

Kriengkrai Porkaew1

Iosif Lazaridis2

Sharad Mehrotra2

1 King Monkut’s University of Technology at Thonburi, Thailand

2 University of California, Irvine

SSTD 2001, Redondo Beach, CA

Page 2: Querying Mobile Objects in Spatio-Temporal Databases

Talk Outline

Related WorkQuery Types over Mobile ObjectsIndexing & Query Evaluation Strategies

Native Space Indexing (NSI) Parametric Space Indexing (PSI)

ExperimentsConclusions

Page 3: Querying Mobile Objects in Spatio-Temporal Databases

Motivation - VGIS

VGIS a 3D terrain visualization system

Data terrain, weather data, static & dynamic 3D

objects Functionality

spatio-temporal queries over mobile objects

Page 4: Querying Mobile Objects in Spatio-Temporal Databases

Update Model

Linear Motion with constant velocityUpdate consists of <ts, te, xi, vi>

Next update arrives at time of previous update’s expiration te. Both historical and future queries are supported

time

location

Page 5: Querying Mobile Objects in Spatio-Temporal Databases

Related Work

Spatio-Temporal Index Structures Theodoridis et. al. SSDBM 1998 “Specifications for Efficient

Indexing in Spatio-Temporal Databases”

Indexing Mobile Objects Tayeb et. al. Computer Journal 41(3) “A quadtree based dynamic

attribute indexing method” Kollios et. al. PODS 1999 “On Indexing Mobile Objects” Saltenis et. al. SIGMOD 2000 “Indexing the Positions of

Continuously Moving Objects”

General Wolfson et. al. SSDBM 1998 “Moving Objects Databases: Issues

and Solutions”

Focus of Current Techniques: Future Spatio-Temporal Range Queries

Page 6: Querying Mobile Objects in Spatio-Temporal Databases

Query TypesSpatial/Temporal Range

Which objects were in spatial range [Q.xL,Q.xiL] during time interval [Q.tL,Q.tL]?

time

location

Q.tL Q.tH

Q.xL

Q.xH

Page 7: Querying Mobile Objects in Spatio-Temporal Databases

Query TypesTemporal kNN

k top objects closest temporally to query time Q.t that lie in spatial range [Q.xL, Q.xH], ordered by time

time

location

Q.t

1

2 3

Q.xL

Q.xH

Page 8: Querying Mobile Objects in Spatio-Temporal Databases

Query TypesSpatial kNN

time

location

Q.tL

1

3

Q.tH

4

Q.x2

k top objects closest spatial to query location Q.x during time interval [Q.tL, Q.tH], ordered by proximity

Page 9: Querying Mobile Objects in Spatio-Temporal Databases

Indexing ApproachesNative Space Indexing (NSI)

represents objects with bounding boxes in native space (time/location) bounding box: <L,H> L =R.tL,R.x1L,…,R.xnL ;

H=R.tH,R.x1H,…,R.xnH

L

s

e

HX

Time

Object’s trajectory

Y

To eliminate false admission: line-segment: <s,e> s=O.ts,O.x1s,…,O.xns ;

e=O.te,O.x1e,…,O.xne

Page 10: Querying Mobile Objects in Spatio-Temporal Databases

Range Query QFor a Bounding Box R:

if overlaps (Q, R), i.e., Q overlaps with R along the temporal and all spatial dimensions explore node

For a line segment L: if L does not overlap with Q in time ignore else …

Native Space IndexingRange Query

Page 11: Querying Mobile Objects in Spatio-Temporal Databases

Native Space IndexingRange Query – Line Segment

time

Q.xiH

Ti

time

O.T

Q.T

Li.T=time interval that the line of the object cuts the upper/lower boundary of the query along dimension i

Li.T

Q.xiL

locationTi=Q.T O.T Li.T

T = i Ti

— If T is empty, ignore

— Else retrieve

Page 12: Querying Mobile Objects in Spatio-Temporal Databases

k Nearest Neighbor Algorithm

A

B

AB

Priority Queue

A

CDE

C

D

EBCDE

B

fghf

g

h

fCDEgh

f answer

Page 13: Querying Mobile Objects in Spatio-Temporal Databases

Native Space IndexingTemporal kNN

Temporal kNN query: <Q.t; Q.xiL, Q.xiH>

retrieve objects in <Q.xiL, Q.xiH> with minimum t=|Q.t-O.t|

explore nodes in ascending order of t using a priority queue

Bounding Box testing for each i, if [R.xiL, R.xiH] not overlap [Q.xiL, Q.xiH]

ignore else, compute t and insert <t, R> in the priority

queue

otherwise0

t.Rt.Qift.Qt.R

t.Rt.Qift.Rt.Q

t LL

HH

Page 14: Querying Mobile Objects in Spatio-Temporal Databases

Native Space IndexingTemporal kNN – Line Segment

time

location

O.T

Li.T

Ti

Q.t

otherwise0

TQ.tifTQ.t

Q.tTifQ.tT

t Hov,Hov,

Lov,Lov,

Ti= O.T Li.T

Tov = i Ti

Page 15: Querying Mobile Objects in Spatio-Temporal Databases

Spatial kNN query: <Q.tL, Q.tH; Q.xi>

retrieve the k nearest objects to Q.xi during the time interval [Q.tL, Q.tH]

explore node in ascending order of d = distance from Q.xi

Bounding Box testing if [R.tL, R.tH] not overlap [Q.tL, Q.tH] ignore R

else, compute d = mindist (P, Q) = [I di2]1/2

Native Space IndexingSpatial kNN

xi

Q.xi

di=R.xL-Q.xH

di= Q.xL-R.xH

di=0

time

Q

Q

Q

Bounding Box Line Segment

Page 16: Querying Mobile Objects in Spatio-Temporal Databases

Indexing ApproachesParametric Space Indexing (PSI) represent objects with their

motion parameters time <ts, te>

starting location O.xi

velocity O.vi

Location FunctionO.xi(t)=O.xi+O.vi(t - O.ts)

where ts t te

Bounding box R=

<tL,xiL,viL; tH,xiH,viH>Velocity (v)

Time (t)

Location (x)Object’s motion

Spatio-temporal Query(projected on a bounding box)

Historical Queries feasible since past segments are kept in index Maximum locality since ts the time reference of the most recent

update is used

Page 17: Querying Mobile Objects in Spatio-Temporal Databases

Bounding Box testing if [Q.tL,Q.tH] not overlap [R.tL,R.tH]

ignore R; else compute time interval tov,i that

R overlaps Q in the native space along dimension i:

Tov,i=Ti Q.T R.T

if Tov,I is not empty on all dimensions, then explore R, else ignore it

time

viH

location

Ti

Parametric Space IndexingRange Query

Q.T

viL

R.T

R

Tov,

i

Page 18: Querying Mobile Objects in Spatio-Temporal Databases

Bounding Box testing compute time interval Tov,i that R

overlaps Q in the native space along dimension i

Tov,i= Ti R.T

Tov = i Ti

viH

viL

time

Bounding Box R

tpriority

Parametric Space IndexingTemporal kNN

Q.t

Ti

R.T

location

Tov,i

otherwise0

TQ.tifQ.tT

TQ.tifTQ.t

t Lov,Lov,

Hov,Hov,

priority

Page 19: Querying Mobile Objects in Spatio-Temporal Databases

First, compute the temporal overlap:K.T= Q.T R.T

Then, compute Si the extent of R in dimension i within the time range K.T

Compute spriority by taking the mindist of the query point Q.xi and the range Si and summing up over all dimensions

Parametric Space IndexingSpatial kNN

viH

time

xi

Bounding Box R

Query

Si

di

Q.xi

viLviL

R.T

Q.T

K.T

Spriority = [i di2]1/2

Page 20: Querying Mobile Objects in Spatio-Temporal Databases

Experiments

Data 5,000 mobile objects moving in a 100x100 grid Objects send ~1 update/time unit Simulations with 1, 2, 4 velocity units were run Duration of simulation 100 time units (~500,000

line segments in index)

Queries Ranges of sizes 0.25 to 10 along each spatial

dim. Average results over 1,000-query loads

Page 21: Querying Mobile Objects in Spatio-Temporal Databases

Range QueriesI/O Cost

Page 22: Querying Mobile Objects in Spatio-Temporal Databases

Range QueriesCPU Cost

Page 23: Querying Mobile Objects in Spatio-Temporal Databases

Range QueriesVarying Object Speed

Page 24: Querying Mobile Objects in Spatio-Temporal Databases

Temporal kNNI/O Cost

Page 25: Querying Mobile Objects in Spatio-Temporal Databases

Spatial kNNI/O Cost

Page 26: Querying Mobile Objects in Spatio-Temporal Databases

Interpretation

Parametric Space Indexing+ compact representation+ no false alarms- need transformation - not so good locality - specific to the type of motion used

Native Space Indexing+ good locality+ general for all kinds of motions: linear, circular, constant

speed, constant acceleration+ easy to deal with- highly overlapped boxes

Page 27: Querying Mobile Objects in Spatio-Temporal Databases

Conclusions

Classification of selection queries over mobile objects with range or nearest neighbor predicate on space/time

Query processing techniques using two indexing approaches: Native– and Parametric-Space Indexing

Native Space Indexing outperforms Parametric Space Indexing besides being conceptually simpler