420 likes | 535 Views
Close Pair Queries in Moving Object Databases. Panfeng Zhou, Donghui Zhang, Betty Salzberg, Gene Cooperman Northeastern University. George Kollios Boston University. Talk Outline. Problem description Motivation Algorithm Overview structure Retrieval component Identification component
E N D
Close Pair Queries in Moving Object Databases Panfeng Zhou, Donghui Zhang, Betty Salzberg, Gene Cooperman Northeastern University George Kollios Boston University
Talk Outline • Problem description • Motivation • Algorithm • Overview structure • Retrieval component • Identification component • Experimental results • Conclusions
Problem definition • Example: Which airplanes were closer to each other than 10 miles during the past month in Massachusetts? • Formal definition: Given a trajectory dataset D, a spatial range R, a time interval I and a threshold ε, the Close-Pair Query finds all pairs of object IDs (o1, o2) such that at some time t Є I, o1 and o2 are both located inside R and d(o1, o2) < ε.
Talk Outline • Problem description • Motivation • Algorithm • Overview structure • Retrieval component • Identification component • Experimental results • Conclusions
Motivations • Close pair query can be used to find associations and correlations between objects (e.g., S. Shekhar and Y. Huang, “Discovering Spatial Co-location Patterns: A Summary of Results”, SSTD 2001). • Close pair query itself can be used in many real applications.
ACCIDENTS Motivations (cont) INCIDENTS UNREPORTED OCCURRENCES Heinrich Pyramid
Talk Outline • Problem description • Motivation • Algorithm • Overview structure • Retrieval component • Identification component • Experimental results • Conclusions
Algorithm • Overview Structure • Retrieval component • Identification component
Identification Component (Time-X Plane Sweep) Retrieval Component (MTSB-tree) Overview structure of algorithm Close pairs Trajectories in increasing time order
Talk Outline • Problem description • Motivation • Algorithm • Overview structure • Retrieval component • Identification component • Experimental results • Conclusions
Retrieval component • Overview of the MTSB-tree • Challenges in the MTSB-tree • How to avoid sorting • How to avoid duplication
TSB-tree 2 TSB-tree 1 TSB-tree 3 TSB-tree 5 TSB-tree 4 TSB-tree 6 TSB-tree 8 TSB-tree 7 TSB-tree 9 Overview of the MTSB-tree • Note: • Trajectory covers multi- cells will be saved in all those cells. • The retrieval algorithm will first find all the cells intersect spatial range R. Within each cell, load all the pages intersect time range I.
Challenges in the MTSB-tree • Output the retrieval results in time increasing order. • Avoid loading the same trajectory multiple times.
How to avoid sorting - 1 Page 1 Page 2 Priority Queue T1, L12 T7, L14 T1, L11 T5, L13 Cell 1 Cell 1 Cell 2 Page 1 Page 2 T4, L22 T8, L24 T2, L21 T6, L23 Cell 2
How to avoid sorting - 2 Page 1 Page 2 Priority Queue T1, L12 T7, L14 T1, L11 T5, L13 Cell 1 T1, L11 Cell 1 Cell 2 Page 1 Page 2 T4, L22 T8, L24 T2, L21 T6, L23 Cell 2
How to avoid sorting - 3 Page 1 Page 2 Priority Queue T1, L12 T7, L14 T1, L11 T5, L13 Cell 1 T1, L11 Cell 1 T2, L21 Cell 2 Page 1 Page 2 T4, L22 T8, L24 T2, L21 T6, L23 Cell 2
How to avoid sorting - 4 Page 1 Page 2 Priority Queue T1, L12 T7, L14 T1, L11 T5, L13 Cell 1 T1, L12 Cell 1 T2, L21 Cell 2 Page 1 Page 2 T4, L22 T8, L24 T2, L21 T6, L23 Cell 2
How to avoid sorting - 5 Page 1 Page 2 Priority Queue T1, L12 T7, L14 T1, L11 T5, L13 Cell 1 T2, L21 Cell 1 T5, L13 Cell 2 Page 1 Page 2 T4, L22 T8, L24 T2, L21 T6, L23 Cell 2
How to avoid sorting - 6 Page 1 Page 2 Priority Queue T1, L12 T7, L14 T1, L11 T5, L13 Cell 1 T4, L22 Cell 1 T5, L13 Cell 2 Page 1 Page 2 T4, L22 T8, L24 T2, L21 T6, L23 Cell 2
X Query time interval Cell 2 Spatial query range Cell 1 QET Time How to avoid duplication loading from different cells
X Query time interval Spatial query range QET Page 2 Page 1 Time How to avoid duplication loading from the same cell
Talk Outline • Problem description • Motivation • Algorithm • Overview structure • Retrieval component • Identification component • Experimental results • Conclusions
Identification component • Motivation for TIME-X sweep algorithm • Observations • Algorithm
X X ε ε ε Time Time Motivation
Observations • Only need to detect close pairs at start times, end times and intersections • If two trajectory segments do not intersect, • they are closest at the start/end time of one of them • Store trajectories relative positions in X-dimension at their start times and update the order at intersections, we can always keep the correct relative order • If two trajectory segments do not intersect, • their relative positions will never change • If two trajectory segments’ distance at X-dimension • is bigger than ε, their distance at X-Y plane is also • bigger than ε • Plane sweep at TIME-X plane can filter out the unqualified close pair candidates in TIME-X-Y plane.
t1: X L1 SL: EL: t8, L1 ends L1 t1 t8 Time Algorithm - 1
t3: L2 SL: L1 L2 EL: t8, L1 ends t12, L2 ends t3 t12 Algorithm - 2 X L1 t1 t8 Time
t5: L2 SL: L3 L1 L3 EL: t8, L1 ends t11, L3 ends t12, L2 ends t5 t11 Algorithm - 3 X L2 L1 t1 t3 t8 t12 Time
t7: SL: L2 L3 L1 L4 EL: t8, L1 ends t10, L4 ends L4 t11, L3 ends t12, L2 ends t7 t10 Algorithm - 4 X L2 L3 L1 t1 t3 t5 t8 t11 t12 Time
t8: Close pair candidates: (L1,L3), (L1,L4) SL: L2 L3 L4 ε ε EL: L1 t10, L4 ends t11, L3 ends t1 t8 t12, L2 ends Algorithm - 5 X L2 L3 L4 t3 t5 t7 t10 t11 t12 Time
t10: Close pair candidates: (L1,L3), (L1,L4) SL: L2 L3 L4 EL: t11, L3 ends t12, L2 ends t7 t10 Algorithm - 6 X L2 L3 t3 t5 t11 t12 Time
t11: Close pair candidates: (L1,L3), (L1,L4) SL: L2 L3 EL: t12, L2 ends t5 t11 Algorithm - 7 X L2 t3 t12 Time
t12: Close pair candidates: (L1,L3), (L1,L4) SL: L2 EL: t3 t12 Algorithm - 8 X Time
Talk Outline • Problem description • Motivation • Algorithm • Overview structure • Retrieval component • Identification component • Experimental results • Conclusions
Experimental results • Setup • Retrieval component • Identification component
Setup • Simulated Air Traffic Control data set includes 200,000 3-D line segments and the whole space is a 10000x10000x10 space. • 4D R*-tree (i.e., 3D for spatial, 1D for temporal) uses the XXL library • Page size: 16KB
Talk Outline • Problem description • Motivation • Algorithm • Overview structure • Retrieval component • Identification component • Experimental results • Conclusions
Conclusions • The MTSB-tree can efficiently return the retrieval results without sorting. • The Time-X plane sweep algorithm can avoid the unnecessary comparisons. • The efficiency of the methods are verified by extensive experimental results.