Presentation is loading. Please wait.

Presentation is loading. Please wait.

Algorithms for Map Construction and Comparison:

Similar presentations


Presentation on theme: "Algorithms for Map Construction and Comparison:"— Presentation transcript:

1 Algorithms for Map Construction and Comparison:
Map-Matching Carola Wenk Department of Computer Science Tulane University Collaborators: Mahmuda Ahmed, Brittany Fasy, Kyle Hickmann, Dieter Pfoser, Sophia Karagiorgou, Majid Mirzanezhad, Helmut Alt, Maike Buchin, Kevin Buchin, …

2 New Orleans

3 New Orleans

4 Mardi Gras!

5 Outline For the Week Algorithms for polygonal curves (trajectories) and for embedded graphs (road maps). Map-matching: Mapping a curve to a graph Curve comparison Map construction: Constructing a road map from a set of trajectories Map comparison: Comparing two roadmaps

6 Outline For the Week Map-Matching Fréchet distance
Fréchet map-matching HMM map-matching Map Construction I Density-based methods Intersection linking Fréchet-based Map Construction II Fréchet clustering Bundle map-construction Map Comparison Hausdorff distance Path-based distances Local persistent homology-based distance Graph sampling-based distance Local signatures Extensions Handling directed edges, multiple lanes, turn restrictions Map updates and detecting change Fréchet range queries

7 Curves f(0.6) f(1) f(0) f(0.2) f(0.4) f(0.45) f(a(0.9)) f(a(1))
A curve is a continuous map f:[0,1]  ℝd Many different curves can have the same image. We can reparameterize curves: f∘a: [0,1]  ℝd, where a: [0,1]  [0,1] is a reparameterization. f(0.6) f(1) f(0) f(0.2) f(0.4) f(0.45) f(a(0)) f(a(1)) f(a(0.5)) f(a(0.8)) f(a(0.81)) f(a(0.9))

8 Polygonal Curves p3 p5 p1 p6 p4 p2 p0
Polygonal curves are piecewise linear curves that consist of a finite number of line segments and vertices. They can be specified by a sequence of points <p0,..., pn> We typically endow a polygonal curve with its arc-length parameterization f:[0,1]  ℝd. On each edge pipi+1 this is a linear function, hence a piecewise linear function overall. f is a piecewise linear interpolation of <p0,..., pn>. What are good distance measures for curves? Hausdorff distance? Fréchet distance? p3 p5 p1 p6 p4 p2 p0

9 Trajectories A (geospatial) trajectory is a sequence of position samples: p1,…,pn Each pi minimally consists of: position measurement (e.g., latitude/longitude; (x,y)-coordinate) time stamp  e.g., pi = (xi, yi, ti) … and optionally of : speed acceleration noise estimate Example: GPS trajectories p3 t3=3 p6 t6=15 p2 t2=2 p4 t4=8 p5 t5=14 p1 t1=1

10 Trajectories and Sampling
A trajectory is a sequence of position samples: p1,…,pn Each pi minimally consists of: position measurement (e.g., latitude/longitude; (x,y)-coordinate) time stamp  e.g., pi = (xi, yi, ti) Such a trajectory is a finite sample of a continuous curve f:[t1, tn]  ℝ2 For simplicity, f is often assumed to be a piecewise linear interpolation. But clearly there are many possible choices for f. There are also many possible choices for parameterizations in between sample points f(1)= f(2)= f(3)= =f(4) =f(5) =f(6) p3 t3=3 p6 t6=15 p2 t2=2 p4 t4=8 p5 t5=14 p1 t1=1

11 Uncertainty and Error/Noise
Measurement error: Usually modeled as Gaussian noise, or as an error-disk around each measurement point. Sampling error: Amounts to modeling the transition between two measurements Simple transition model: Linear interpolation. Common transition models in ecology: Brownian bridges, Levy walks Simple region-based model: Buffers of fixed radius around each trajectory Need input model: E.g., chain of beads model for trajectories What is a good output model? [T11] G. Trajcevski, Uncertainty in spatial trajectories, in Y. Zheng, X. Zhou (eds), Computing with Spatial Trajectories: , 2011.

12 Comparing Curves and Trajectories

13 Comparing Curves and Trajectories
Being able to compare trajectories and curves is an important prerequisite for most applications dealing with trajectories: Map-matching: Given a road network and a trajectory, find a path in the network that is most similar to the trajectory Clustering: Given a set of trajectories, find a cluster of similar (sub-) trajectories Simplification: Given a piecewise linear curve, find a curve with fewer vertices that is most similar to the original curve How does one compare two curves or trajectories?

14 Polygonal Curves Let f,g:[0,1]  Rd be two polygonal curves (i.e., piecewise linear curves) What are good distance measures for curves? Hausdorff distance? Fréchet distance? f g

15 When Are Two Curves „Similar“?
Directed Hausdorff distance 𝛿 𝐻 (A,B) = max min || a-b || Undirected Hausdorff-distance dH (A,B) = max ( 𝛿 𝐻 (A,B) , 𝛿 𝐻 (B,A) ) But: B A a A bB 𝛿 𝐻 (B,A) 𝛿 𝐻 (A,B) Small Hausdorff distance When considered as curves the distance should be large The Fréchet distance takes the continuity of the curves into account

16 Fréchet Distance for Curves
dF(f,g) = inf max ||f(a(t))-g(b(t))|| a,b:[0,1] [0,1] t [0,1] where a and b range over continuous monotone increasing reparameterizations only. Man and dog walk on one curve each They hold each other at a leash They are only allowed to go forward dF is the minimal possible leash length f g [F06] M. Fréchet, Sur quelques points de calcul fonctionel, Rendiconti del Circolo Mathematico di Palermo 22: 1-74, 1906.

17 Free Space Diagram g >e f g 1 e ε 1 2 3 4 5 6 f Let e > 0 fixed (eventually solve decision problem) Fe(f,g) = { (s,t)[0,1]2 | || f(s) - g(t)||  e } white points free space of f and g The free space in one cell is an ellipse.

18 Free Space Diagram g g f f Let e > 0 fixed (eventually solve decision problem) Fe(f,g) = { (s,t)[0,1]2 | || f(s) - g(t)||  e } white points free space of f and g The free space in one cell is an ellipse.

19 Free Space Diagram Monotone path encodes reparametrizations of f and g
b g f Monotone path encodes reparametrizations of f and g dF(f,g)  e iff there is a monotone path in the free space from (0,0) to (1,1)

20 Compute the Fréchet Distance
g 1 Solve the decision problem dF(f,g)  e in O(mn) time: Find monotone path using DP: On each cell boundary compute the interval of all points that are reachable by a monotone path from (0,0) Compute a monotone path by backtracking a f b 1 Solve the optimization problem In practice in O(mn log b) time with binary search and b-bit precision In O(mn log mn) time [AG95] using parametric search (using Cole‘s sorting trick) In O(mn log mn) expected time [HR14] using a random sampling approach [AG95] H. Alt, M. Godau, Computing the Fréchet distance between two polygonal curves, IJCGA 5: 75-91, 1995. [HR14] S. Har-Peled, B. Raichel, The Fréchet Distance Revisited and Extended, ACM TALG 10(1): 3:1-3:22, 2014.

21 Fréchet Variants Weak Fréchet distance Discrete Fréchet distance
Fréchet distance with speed limits Integral or summed Fréchet distance Partial Fréchet distance ...

22 Weak Fréchet Distance Fréchet distance: dF(f,g) = inf max ||f(a(t))-g(b(t))|| a,b:[0,1] [0,1] t [0,1] where a and b range over continuous monotone increasing reparameterizations only. Weak Fréchet distance dwF(f,g): Allow any continuous reparameterizations a and b dH(f,g)  dwF(f,g)  dF(f,g)

23 Weak Fréchet Distance: Free Space Cell
< e2 < e3 < e4 e1 e2 e4 e3 e3 Store e2 as the weight of the vertical free space boundary

24 Free Space Graph Encodes connectivity information of the free space.
For each cell boundary store optimal e as its weight Weak Fréchet distance = maximum of all e’s along an optimal path in the free space graph Run Dijkstra’s algorithm to find a shortest path (with minimum total e) Runtime O(mn log mn) (or O(mn) for planar graphs)

25 Discrete Fréchet Distance
Given two sequences of points ( trajectories), compute the discrete Fréchet distance by allowing only monotone assignments between points („couplings“) Free space = grid of black and white points Find path with dynamic programming g g f f [EM94] Eiter, Mannila, technical report, Technical University Vienna,1994.

26 Partial Fréchet Distance
For a given e>0, compute a monotone path in the free space diagram that is allowed to pass through both white and black regions and that maximizes the portion of the path within the white regions. Apply DP approach as before, but on each cell boundary maintain a function (instead of an interval). This function measures the maximum length of any monotone path from the lower left corner to the point on the boundary. For technical reasons the L1-distance is used to measure the Fréchet distance (hence the free space is polygonal) Runtime O(n3 log n) This partial distance identifies portions of the two curves that correspond to each other [BBW09] K. Buchin, M. Buchin, Y. Wang, Exact Partial Curve Matching under the Fréchet Distance, SODA: , 2009.

27 Map-Matching

28 Carola Wenk, Tulane University
Map Matching Given: A graph G, a curve l, and a distance parameter e. Task: Find a path p in G such that dF(l,p)≤e p B e l A G Application: GPS routing; use GPS data from vehicle fleets to build data base of current travel times Carola Wenk, Tulane University

29 GPS Trajectories from Vehicles
Measurement error: GPS points generally do not lie on the road map Sampling error: The GPS trajectory is a by-product and is usually sampled every 30s  The GPS trajectory does not lie on the road map Map matching: Find a path in the graph which corresponds to the GPS trajectory (curve). Find a path in the graph with minimal distance to the GPS curve (partial matching) Road map of Athens GPS trajectoriy Corresponding path in the road map

30 Map Matching: Free Space Diagram
FDi,j j f j (i,j) (i,j) i i f For every edge (i,j) in G: FDi,j = FD( f, (i,j)) For every vertex i in G: sei FDi = FD( f, i ) 1-dimensional [AERW03] H. Alt, A. Efrat, G. Rote, C. Wenk, Matching Planar Maps, J. of Algorithms 49: , 2003. [BPSW05] S. Brakatsoulas, D. Pfoser, R. Salas, C. Wenk, On Map-Matching Vehicle Tracking Data , VLDB , 2005. [WSP06] C. Wenk, R. Salas, D. Pfoser, Adressing the Need for Map-Matching Speed…, SSDBM: , 2006.

31 Free Space Surface G Glue the free space diagrams FDi,j together according to adjacency information in G Free space surface of f and G [AERW03] H. Alt, A. Efrat, G. Rote, C. Wenk, Matching Planar Maps, J. of Algorithms 49: , 2003. [BPSW05] S. Brakatsoulas, D. Pfoser, R. Salas, C. Wenk, On Map-Matching Vehicle Tracking Data , VLDB , 2005. [WSP06] C. Wenk, R. Salas, D. Pfoser, Adressing the Need for Map-Matching Speed…, SSDBM: , 2006.

32 Free Space Surface G Task: Find a monotone path in the free space surface that starts in a lower left corner and ends in an upper right corner [AERW03] H. Alt, A. Efrat, G. Rote, C. Wenk, Matching Planar Maps, J. of Algorithms 49: , 2003. [BPSW05] S. Brakatsoulas, D. Pfoser, R. Salas, C. Wenk, On Map-Matching Vehicle Tracking Data , VLDB , 2005. [WSP06] C. Wenk, R. Salas, D. Pfoser, Adressing the Need for Map-Matching Speed…, SSDBM: , 2006.

33 Sweep Sweep all FDi,j with a sweep line from left to right G
[AERW03] H. Alt, A. Efrat, G. Rote, C. Wenk, Matching Planar Maps, J. of Algorithms 49: , 2003. [BPSW05] S. Brakatsoulas, D. Pfoser, R. Salas, C. Wenk, On Map-Matching Vehicle Tracking Data , VLDB , 2005. [WSP06] C. Wenk, R. Salas, D. Pfoser, Adressing the Need for Map-Matching Speed…, SSDBM: , 2006.

34 Sweep Sweep all FDi,j with a sweep line from left to right G
[AERW03] H. Alt, A. Efrat, G. Rote, C. Wenk, Matching Planar Maps, J. of Algorithms 49: , 2003. [BPSW05] S. Brakatsoulas, D. Pfoser, R. Salas, C. Wenk, On Map-Matching Vehicle Tracking Data , VLDB , 2005. [WSP06] C. Wenk, R. Salas, D. Pfoser, Adressing the Need for Map-Matching Speed…, SSDBM: , 2006.

35 Sweep Sweep all FDi,j with a sweep line from left to right G
[AERW03] H. Alt, A. Efrat, G. Rote, C. Wenk, Matching Planar Maps, J. of Algorithms 49: , 2003. [BPSW05] S. Brakatsoulas, D. Pfoser, R. Salas, C. Wenk, On Map-Matching Vehicle Tracking Data , VLDB , 2005. [WSP06] C. Wenk, R. Salas, D. Pfoser, Adressing the Need for Map-Matching Speed…, SSDBM: , 2006.

36 Sweep Sweep all FDi,j with a sweep line from left to right G
[AERW03] H. Alt, A. Efrat, G. Rote, C. Wenk, Matching Planar Maps, J. of Algorithms 49: , 2003. [BPSW05] S. Brakatsoulas, D. Pfoser, R. Salas, C. Wenk, On Map-Matching Vehicle Tracking Data , VLDB , 2005. [WSP06] C. Wenk, R. Salas, D. Pfoser, Adressing the Need for Map-Matching Speed…, SSDBM: , 2006.

37 Sweep Sweep all FDi,j with a sweep line from left to right G
[AERW03] H. Alt, A. Efrat, G. Rote, C. Wenk, Matching Planar Maps, J. of Algorithms 49: , 2003. [BPSW05] S. Brakatsoulas, D. Pfoser, R. Salas, C. Wenk, On Map-Matching Vehicle Tracking Data , VLDB , 2005. [WSP06] C. Wenk, R. Salas, D. Pfoser, Adressing the Need for Map-Matching Speed…, SSDBM: , 2006.

38 Sweep Sweep all FDi,j with a sweep line from left to right G
[AERW03] H. Alt, A. Efrat, G. Rote, C. Wenk, Matching Planar Maps, J. of Algorithms 49: , 2003. [BPSW05] S. Brakatsoulas, D. Pfoser, R. Salas, C. Wenk, On Map-Matching Vehicle Tracking Data , VLDB , 2005. [WSP06] C. Wenk, R. Salas, D. Pfoser, Adressing the Need for Map-Matching Speed…, SSDBM: , 2006.

39 Sweep Sweep all FDi,j with a sweep line from left to right G
[AERW03] H. Alt, A. Efrat, G. Rote, C. Wenk, Matching Planar Maps, J. of Algorithms 49: , 2003. [BPSW05] S. Brakatsoulas, D. Pfoser, R. Salas, C. Wenk, On Map-Matching Vehicle Tracking Data , VLDB , 2005. [WSP06] C. Wenk, R. Salas, D. Pfoser, Adressing the Need for Map-Matching Speed…, SSDBM: , 2006.

40 Compute Reachable Points
G During the sweep: Compute points on the free space surface, to the left of the sweep line, which are reachable by a monotone path from a lower left corner. [AERW03] H. Alt, A. Efrat, G. Rote, C. Wenk, Matching Planar Maps, J. of Algorithms 49: , 2003. [BPSW05] S. Brakatsoulas, D. Pfoser, R. Salas, C. Wenk, On Map-Matching Vehicle Tracking Data , VLDB , 2005. [WSP06] C. Wenk, R. Salas, D. Pfoser, Adressing the Need for Map-Matching Speed…, SSDBM: , 2006.

41 Compute Reachable Points
G During the sweep: Compute points on the free space surface, to the left of the sweep line, which are reachable by a monotone path from a lower left corner. [AERW03] H. Alt, A. Efrat, G. Rote, C. Wenk, Matching Planar Maps, J. of Algorithms 49: , 2003. [BPSW05] S. Brakatsoulas, D. Pfoser, R. Salas, C. Wenk, On Map-Matching Vehicle Tracking Data , VLDB , 2005. [WSP06] C. Wenk, R. Salas, D. Pfoser, Adressing the Need for Map-Matching Speed…, SSDBM: , 2006.

42 Compute Reachable Points
G During the sweep: Compute points on the free space surface, to the left of the sweep line, which are reachable by a monotone path from a lower left corner. [AERW03] H. Alt, A. Efrat, G. Rote, C. Wenk, Matching Planar Maps, J. of Algorithms 49: , 2003. [BPSW05] S. Brakatsoulas, D. Pfoser, R. Salas, C. Wenk, On Map-Matching Vehicle Tracking Data , VLDB , 2005. [WSP06] C. Wenk, R. Salas, D. Pfoser, Adressing the Need for Map-Matching Speed…, SSDBM: , 2006.

43 Compute Reachable Points
G During the sweep: Compute points on the free space surface, to the left of the sweep line, which are reachable by a monotone path from a lower left corner. [AERW03] H. Alt, A. Efrat, G. Rote, C. Wenk, Matching Planar Maps, J. of Algorithms 49: , 2003. [BPSW05] S. Brakatsoulas, D. Pfoser, R. Salas, C. Wenk, On Map-Matching Vehicle Tracking Data , VLDB , 2005. [WSP06] C. Wenk, R. Salas, D. Pfoser, Adressing the Need for Map-Matching Speed…, SSDBM: , 2006.

44 Update Reachable Points
G During the sweep: Update reachable points Dijkstra-style Use a data structure which supports reachability queries in the free space surface [AERW03] H. Alt, A. Efrat, G. Rote, C. Wenk, Matching Planar Maps, J. of Algorithms 49: , 2003. [BPSW05] S. Brakatsoulas, D. Pfoser, R. Salas, C. Wenk, On Map-Matching Vehicle Tracking Data , VLDB , 2005. [WSP06] C. Wenk, R. Salas, D. Pfoser, Adressing the Need for Map-Matching Speed…, SSDBM: , 2006.

45 Update Reachable Points
G During the sweep: Update reachable points Dijkstra-style Use a data structure which supports reachability queries in the free space surface [AERW03] H. Alt, A. Efrat, G. Rote, C. Wenk, Matching Planar Maps, J. of Algorithms 49: , 2003. [BPSW05] S. Brakatsoulas, D. Pfoser, R. Salas, C. Wenk, On Map-Matching Vehicle Tracking Data , VLDB , 2005. [WSP06] C. Wenk, R. Salas, D. Pfoser, Adressing the Need for Map-Matching Speed…, SSDBM: , 2006.

46 Update Reachable Points
G During the sweep: Update reachable points Dijkstra-style Use a data structure which supports reachability queries in the free space surface [AERW03] H. Alt, A. Efrat, G. Rote, C. Wenk, Matching Planar Maps, J. of Algorithms 49: , 2003. [BPSW05] S. Brakatsoulas, D. Pfoser, R. Salas, C. Wenk, On Map-Matching Vehicle Tracking Data , VLDB , 2005. [WSP06] C. Wenk, R. Salas, D. Pfoser, Adressing the Need for Map-Matching Speed…, SSDBM: , 2006.

47 Update Reachable Points
G During the sweep: Update reachable points Dijkstra-style Use a data structure which supports reachability queries in the free space surface [AERW03] H. Alt, A. Efrat, G. Rote, C. Wenk, Matching Planar Maps, J. of Algorithms 49: , 2003. [BPSW05] S. Brakatsoulas, D. Pfoser, R. Salas, C. Wenk, On Map-Matching Vehicle Tracking Data , VLDB , 2005. [WSP06] C. Wenk, R. Salas, D. Pfoser, Adressing the Need for Map-Matching Speed…, SSDBM: , 2006.

48 Update Reachable Points
G During the sweep: Update reachable points Dijkstra-style Use a data structure which supports reachability queries in the free space surface [AERW03] H. Alt, A. Efrat, G. Rote, C. Wenk, Matching Planar Maps, J. of Algorithms 49: , 2003. [BPSW05] S. Brakatsoulas, D. Pfoser, R. Salas, C. Wenk, On Map-Matching Vehicle Tracking Data , VLDB , 2005. [WSP06] C. Wenk, R. Salas, D. Pfoser, Adressing the Need for Map-Matching Speed…, SSDBM: , 2006.

49 Update Reachable Points
G During the sweep: Update reachable points Dijkstra-style Use a data structure which supports reachability queries in the free space surface [AERW03] H. Alt, A. Efrat, G. Rote, C. Wenk, Matching Planar Maps, J. of Algorithms 49: , 2003. [BPSW05] S. Brakatsoulas, D. Pfoser, R. Salas, C. Wenk, On Map-Matching Vehicle Tracking Data , VLDB , 2005. [WSP06] C. Wenk, R. Salas, D. Pfoser, Adressing the Need for Map-Matching Speed…, SSDBM: , 2006.

50 Update Reachable Points
G During the sweep: Update reachable points Dijkstra-style Use a data structure which supports reachability queries in the free space surface [AERW03] H. Alt, A. Efrat, G. Rote, C. Wenk, Matching Planar Maps, J. of Algorithms 49: , 2003. [BPSW05] S. Brakatsoulas, D. Pfoser, R. Salas, C. Wenk, On Map-Matching Vehicle Tracking Data , VLDB , 2005. [WSP06] C. Wenk, R. Salas, D. Pfoser, Adressing the Need for Map-Matching Speed…, SSDBM: , 2006.

51 Update Reachable Points
G During the sweep: Update reachable points Dijkstra-style Use a data structure which supports reachability queries in the free space surface [AERW03] H. Alt, A. Efrat, G. Rote, C. Wenk, Matching Planar Maps, J. of Algorithms 49: , 2003. [BPSW05] S. Brakatsoulas, D. Pfoser, R. Salas, C. Wenk, On Map-Matching Vehicle Tracking Data , VLDB , 2005. [WSP06] C. Wenk, R. Salas, D. Pfoser, Adressing the Need for Map-Matching Speed…, SSDBM: , 2006.

52 Update Reachable Points
G During the sweep: Update reachable points Dijkstra-style Use a data structure which supports reachability queries in the free space surface [AERW03] H. Alt, A. Efrat, G. Rote, C. Wenk, Matching Planar Maps, J. of Algorithms 49: , 2003. [BPSW05] S. Brakatsoulas, D. Pfoser, R. Salas, C. Wenk, On Map-Matching Vehicle Tracking Data , VLDB , 2005. [WSP06] C. Wenk, R. Salas, D. Pfoser, Adressing the Need for Map-Matching Speed…, SSDBM: , 2006.

53 Backtracking After the sweep: G
Construct a monotone path via backtracking [AERW03] H. Alt, A. Efrat, G. Rote, C. Wenk, Matching Planar Maps, J. of Algorithms 49: , 2003. [BPSW05] S. Brakatsoulas, D. Pfoser, R. Salas, C. Wenk, On Map-Matching Vehicle Tracking Data , VLDB , 2005. [WSP06] C. Wenk, R. Salas, D. Pfoser, Adressing the Need for Map-Matching Speed…, SSDBM: , 2006.

54 Map-Matching Algorithm for decision problem takes O(mn log(mn)) time and O(mn) space. Optimization problem with parametric search: O(mn log2(mn)) time Not really practicable for road maps with m= edges [AERW03] H. Alt, A. Efrat, G. Rote, C. Wenk, Matching Planar Maps, J. of Algorithms 49: , 2003. [BPSW05] S. Brakatsoulas, D. Pfoser, R. Salas, C. Wenk, On Map-Matching Vehicle Tracking Data , VLDB , 2005. [WSP06] C. Wenk, R. Salas, D. Pfoser, Adressing the Need for Map-Matching Speed…, SSDBM: , 2006.

55 Using the Weak Fréchet Distance
Use the same algorithm as for the weak Frechet distance between curves: Consider any (non-monotone) path in the free space Convert the problem into a shortest-path problem in the free space graph Run Dijkstra’s shortest paths algo. and construct free space on the fly. Runtime O(K log K) with K=size of traversed free space  Output-sensitive algorithm which needs much less space in practice and is extremely fast  Computes free space graph on the fly [AERW09] H. Alt, A. Efrat, G. Rote, C. Wenk, Matching Planar Maps, J. of Algorithms 49: , 2003. [BPSW05] S. Brakatsoulas, D. Pfoser, R. Salas, C. Wenk, On Map-Matching Vehicle Tracking Data , VLDB , 2005.

56 Uncertainty Model for Trajectories
Consider data acquisition errors: measurement error sampling error Additional information for each data point: Velocity Active region for one line segment:  Represents all possible positions Sequence of all active regions:  Represents all possible trajectories  Error-aware representation of the vehicle trajectory

57 Error-Aware Map-Matching
Find curve that fulfills the following properties: Starts at the origin Stops at the destination Intersects measurement error disks around all position samples Is within active regions

58 Adaptive Clipping Algorithm
Incremental algorithm For each active region of an edge Run output-sensitive weak-Frechet/Dijkstra algorithm Stitch Dijkstra graphs together at active regions of vertices Construct overall result by tracing back stitched-together Dijkstra graphs Solves error-aware map-matching task Corresponds to pruning/clipping the Fréchet-based algorithm The clipping immensely reduces K. In practice K is almost constant. The algorithm is very fast, almost O(n log n) runtime [WSP06] C. Wenk, R. Salas, D. Pfoser, Addressing the Need for Map-Matching Speed…, SSDBM: , 2006.

59 [NK09] HMM Map-Matching Define a Hidden Markov Model for Map-Matching:
States: r1,…,rm road segments Observations: Sequence of GPS locations z1,…,zn Goal: Label each observation zj with the correct road segment ri. Probabilities: Emission probabilities: P(zj | ri) = 𝒩(xij,s), where xij is the point on ri closest to zj Priors (initial state probabilities): P(z1 | ri) Transition probabilities: P(zi → zi+1 ) = Exp(b,|| zi+1 - zi || - a), Parameters a, b, s are estimated from matching data by hand DP: Use Viterbi algorithm to construct the labels in O(m2n) time → Speedup runtime by only considering roads within 200m Run output-sensitive weak-Frechet/Dijkstra algorithm Stitch Dijkstra graphs together at active regions of vertices Construct overall result by tracing back stitched-together Dijkstra graphs Solves error-aware map-matching task Corresponds to pruning/clipping the Fréchet-based algorithm The clipping immensely reduces K. In practice K is almost constant. The algorithm is very fast, almost O(n log n) runtime [NK09] P. Newson and J. Krumm, Hidden Markov Map Matching Through Noise and Sparseness, ACM SIGSPATIAL 2009.

60 Discussion and Open Problems
How to find good reparameterizations for map-matching? Can one compute map-matching using locally correct Fréchet? HMM was the algorithm of choice for SIGSPATIAL cup 2012 → What is the best-quality map-matcher? How to map travel times (traffic lights at intersections)

61

62 Integral Fréchet Distance
Fréchet distances strongly affected by outliers, since they take the maximum over a set of distances: dF(f,g) = inf max ||f(a(t))-g(b(t))|| a,b:[0,1] [0,1] t [0,1] Integral Fréchet distance: replace the maximum with a path integral over the reparameterization curve (a(t),b(t)): dF(f,g) = inf  ||f(a(t))-g(b(t))|| a,b:[0,1] [0,1] (a,b)  Hard to compute explicitly (variational calculus)  Does not fulfill triangle inequality.  Heuristically approximate using grid-sampling and summations. [B07] M. Buchin, On the Computability of the Frechet Distance Between Triangulated Surfaces, PhD thesis, Free University Berlin, 2007. [MSS16] A. Maheshwari, J.-R. Sack, C. Scheffer, Approximating the Integral Frechet Distance, SWAT 26:1-26:14, 2016.

63 Fréchet Distance with Speed Limits
Given two polygonal curves, as well as a range [vmin(S),vmax(S)] of allowed speeds for each line segment S In each free space cell, the speed ranges for the two involved line segments define a range for the allowed slope.  Only consider paths in the free space that obey the given slope range in each free space cell  Slope ranges can be incorporated in DP during propagation of reachability information. Runtime O(n3) for decision problem, since the complexity of maintaining the reachable intervals on the cell boundary has increased [MSSZ11] Maheshwari, Sack, Shahbaz, Zarrabi-Zadeh, Fréchet Distance with Speed Limits”, CGTA 44(2): , 2011.

64 Other Distance Measures for Curves
Turn-angle distance: Lp-distance of turning function Invariant under translations Dynamic time warping Longest common subsequence [VH01] R.C. Veltkamp, M. Hagedoorn, State-of-the-art … In M. Lew (eds), Principles of Visual Information Retrieval: , [AG99] H. Alt, L. Guibas, Discrete Geometric Shapes…, Handbook of Computational Geometry: , [KP00] E. Keogh, M. Pazzani, Scaling Up Dynamic Time Warping for Datamining Applications, PADKK: , [VGD04] M. Vlachos, D. Gunopulos, G. Das, Rotation invariant distance measure for trajectories, ACM SIGKDD: , 2004

65 Reconciling Trajectory Sets

66 Reconciling Trajectory Sets
Given a set of trajectories Compute an average/mean or median trajectory Reconcile the set into one representative trajectory Prerequisite for k-means and k-medoid clustering Related: Curve Simplification (reduce complexity) Compute (sub-)trajectory clusters Find similar parts of the trajectories For each cluster, compute a reconciled representation Compute a road network Find a graph structure representing all trajectories

67 Curve Simplification Given one polygonal curve f with n vertices, find another curve g with fewer vertices that is similar to f.  Reduce the complexity to store f  Need similarity measure d for curves min-#: Given a fixed e, find g with minimum number of vertices, such that d(f,g)e. min-e: Given a fixed k, find g with at most k vertices such that d(f,g) is minimized. Use only existing vertices of f, i.e., g is a subsequence of f g can contain completely new vertices not present in f [VH01] R.C. Veltkamp, M. Hagedoorn, State-of-the-art in shape matching. In M. Lew (eds), Principles of Visual Information Retrieval: , [AG99] H. Alt, L. Guibas, Discrete Geometric Shapes…, Handbook of Computational Geometry: , 1999.

68 Curve Simplification Arbitrary vertices:
min-#: Compute a minimum link path that stabs e-neighborhoods around vertices of f in the correct order. O(n) time. min-e: Binary search on critical values. O(n2) time. Subsequence of original vertices: Douglas-Peucker algorithm, O(n log n) time. min-#: Add shortcut-edges between vertices if shortcut is within error e. Then find a path with min-# edges. O(n2) time, and O(n4/3+d) for x-monotone chains. [AG99] H. Alt, L. Guibas, Discrete Geometric Shapes…, Handbook of Computational Geometry: , [GHMS93] L. Guibas, J. Hershberger, J. Mitchell, J. Snoeyink, Approximating …, minimum link paths, IJCGA 3(4): , 1993 [II88] H. Imai, M. Iri, Polygonal approximations of a curve…, in Computational Morphology, Toussaint (eds): 71-86, 1988

69 Scale Space Heuristic simplification based on curvature scale space.
Convolve the coordinate functions x(t) and y(t) with a Gaussian kernel: Evolution for increasing s [VH01] R.C. Veltkamp, M. Hagedoorn, State-of-the-art in shape matching. In M. Lew (eds), Principles of Visual Information Retrieval: , [AG99] H. Alt, L. Guibas, Discrete Geometric Shapes…, Handbook of Computational Geometry: , 1999.

70 Average/Mean Curve Given a set f1,…,fk :[0,1] R2 of trajectories/curves, compute one reconciled curve that represents all curves in the set: Point-wise average: f(t) = 1/n i=1 fi for all t[0,1].  O(kn) time. But only works if parameterizations of curves correspond to each other! Compute k-dimensional free space (use concept of Fréchet distance for sets of curves). Instead of Euclidean distance use the radius of the minimum enclosing disk for k points.  O(nk) time. Tries out all joint reparameterizations of curves. n [DR04] A. Dumitrescu, G. Rote, On the Fréchet Distance of a Set of Curves, CCCG: , 2004. [HR11] S. Har-Peled, B. Raichel, The Fréchet Distance Revisited and Extended, ACM SoCG: , 2011.

71 Average vs. Median The average is allowed to introduce new vertices and curve pieces. Can one compute a median, which uses only existing curve pieces and which is central with respect to number of trajectories? E.g., 2 hiking trajectories on one side of lake, 3 on other side of lake. Average trajectory would go through lake. Median of k numbers is the k/2-smallest number. k/2-level in arrangement of lines (has O(k4/3) complexity): [BBKLSWW12] K. & M. Buchin, M. van Kreveld, M. Löffler, R. Silveira, C. Wenk, L. Wiratma, Median Trajectories, Algorithmica, Online First, 2012.

72 Median Analogous to line arrangements, the number of trajectories that have to be crossed from any point on median trajectory to reach the outer face is k/2. Simple median: Switch trajectory at every intersection. But, bad behavior: [BBKLSWW12] K. & M. Buchin, M. van Kreveld, M. Löffler, R. Silveira, C. Wenk, L. Wiratma, Median Trajectories, Algorithmica, Online First, 2012.

73 Homotopic Median Places poles in large faces of arrangement, and require median to go around the poles in the same way as the input trajectories (same homotopy class) Two trajectories are homotopic, if they can be continuously transformed into each other without passing over any pole. If all input trajectories are homotopic w.r.t. poles: Modify switching algorithm: At intersection with new trajectory f, only switch to f if median so far concatenated with f until the endpoint t has the same homotopy type as input trajectories. [BBKLSWW12] K. & M. Buchin, M. van Kreveld, M. Löffler, R. Silveira, C. Wenk, L. Wiratma, Median Trajectories, Algorithmica, Online First, 2012.

74 Other Input Models If region-based representation for the trajectories is given, how can a representative curve be computed? Compute a “joint” region (union, intersection?) Compute a centerline curve using data skeletonization techniques Related to medial axis computation of a polygon (tree, not curve) [[CSM07] N. Cornea, D. Silver, P. Min, Curve-Skeleton Properties, Applications, and Algorithms, IEEE Trans. Visualization and Computer Graphics 13(3): , 2007.

75 Other Input Models Point sets, compute principle curve that has smoothness condition (related to linear regression and principal components) Point sets with probability densities, principle curve is the “ridge” of the probability density “terrain” [HS89] T. Hastie, W. Stuetzle, Principal Curves, J. American Statistical Association 84 (406): , [OE11] U. Ozertem, D. Erdogmus, Locally Defined Principal Curves, J. Machine Learning Research 12: , 2011.

76 Sub-Trajectory Clustering
Find similar portions in trajectories Lots of algorithms for finding clusters in point sets Harder for trajectories since you need to figure out where to break the trajectories into pieces

77 Sub-Trajectory Clustering
A. Asahara, A. Sato, and K. Maruyama. Evaluation of trajectory clustering based on information criteria for human activity analysis. In 10th Int. Conf. on Mobile Data Management: Systems, Services and Middleware (MDM), pages , 2009. K. Buchin, M. Buchin, J. Gudmundsson, M. Löffler, and J. Luo. Detecting commuting patterns by clustering subtrajectories. International Journal of Computational Geome- try and Applications, special issue on 19th International Symposium on Algorithms and Computation (ISAAC), 2010. K. Buchin, M. Buchin, M. van Kreveld, and J. Luo. Finding long and similar parts of trajectories. In 17th ACM SIGSPATIAL International Conference on Advances in Geographic Information Systems (ACM GIS), pages , 2010. A. Dahlbom and L. Niklasson. Trajectory clustering for coastal surveillance. In 10th Int. Conf. on Information Fusion, pages 1-8, 2007. J. Lee, J. Han, and K.-Y. Whang. Trajectory clustering: A partition-and-group framework. In Proc. ACM SIGMOD International Conference on Management of Data, pages , 2007.

78 Sub-Trajectory Clustering
X. Li, W. Hu, and W. Hu. A coarse-to-ne strategy for vehicle motion trajectory clustering. In 18th Int. Conf. on Pattern Recognition (ICPR), volume 1, pages , 2006. Z. Li. Incremental clustering for trajectories. Master's thesis, University of Illinois at Urbana-Champaign, 2010. Z. Li, J.-G. Lee, X. Li, and J. Han. Incremental clustering for trajectories. In Proc. 15th Int. Conf. Database Systems for Advanced Applications (DASFAA), pages 32-46, 2010. T.W. Liao. Clustering of time series data - a survey. Pattern Recognition, 38: , 2005. Y. Zhang and D. Pi. A trajectory clustering algorithm based on symmetric neighborhood. In WRI World Congrees on Computer Science and Information Engineering, volume 3, pages , 2009.

79 Fréchet-Based Clustering
Given an input set of trajectories, append them all to form a single trajectory f Compute the free space diagram of f with itself (comparing f with f) Find clusters of monotone curve pieces in the (white) free space  Sweep free space from left to right, maintain data structure [BBGLL10] K. Buchin, M. Buchin, J. Gudmundsson, M. Löffler, J. Luo. Detecting commuting patterns…, IJCGA, 2010.

80 Map Construction Given a set of trajectories, compute the underlying road network Capturing constrained movement (explicit or implicit streets/routes, animal behavior) OpenStreetMap

81 Map Construction Geometric reconstruction problem:
Given a set of movement-constrained trajectories, extract the underlying geometric structure Reconstruct a geometric domain that has been sampled with continuous curves that are subject to noise Sampling with organized data (trajectories) instead of point clouds Need to identify combinatorial information (edges, vertices), as well as geometric representation/embedding Clustering & how to represent an edge/street

82 Some Results [CGHS10]: First algorithm with quality guarantees. Subsamples trajectories  Dense point cloud. Uses local neighborhood simplicial complexes. Reconstructs “good” portions of edges. [ACCGGM11]: Reconstruct “metric graph” from point cloud. Compute almost isometric space with lower complexity. Focuses on combinatorial information and not on embedding. Quality guarantees assume dense sampling. [GSBW11]: Topological approach on neighborhood complex. Uses Reeb graph to model skeleton graph (branching structure) [ACCGGM11] M. Aanjaneya, F. Chazal, D. Chen, M. Glisse, L. Guibas, D. Morozov. Metric graph reconstruction…, SoCG, [CGHS10] D. Chen, L. Guibas, J. Hershberger, J. Sun, Road network reconstruction for organizing paths, SODA, [GSBW11] X. Ge, I. Safa, M. Belkin, Y. Wang, Data skeletonization via Reeb graphs, Conf. Neural Inf. Proc. Systems: , 2011.

83 Some More Results [FK10]: First identify intersections (vertices) using a shape descriptor, then fill in edges. [AW12]: Use trajectory information. Incrementally add one trajectory after another. Use partial Fréchet distance to identify new and existing portions. Use min-link algorithm to compute representative curve/edge. [FK10] A. Fathi, J. Krumm, Detecting road intersections from GPS traces, Geographic Information Science, LNCS 6292: 56-69, [AW12] M. Ahmed, C. Wenk, Constructing Street Networks from GPS Trajectories, ESA, to appear, 2012.

84 [CGHS10] Algorithm Steps
Compute be-net (subsample to obtain point cloud) Compute Voronoi diagram for point cloud Compute clean, restricted Delaunay graph Reconstruct primitive chains Collapse primitive chains; compute links between Voronoi cell boundaries Expand and combine primitive chains and links

85 Algorithm Steps 1. Compute be-net 2. Compute Voronoi diagram

86 Algorithm Steps 3a. Compute Delaunay graph 3b. Compute restricted Delaunay graph

87 Algorithm Steps 3a. Compute Delaunay graph 3b. Compute restricted Delaunay graph

88 Algorithm Steps 3c. Compute graph between “clean” Voronoi cells:  degree 2  there is an input path cutting “properly” through cell Clean Clean Clean Clean Clean Not Clean Clean Clean Clean Clean

89 Algorithm Steps 4. Reconstruct primitive chains in clean graph Clean
Not Clean Clean Clean Clean Clean

90 Algorithm Steps 5. Collapse primitive chains; compute links between Voronoi cell boundaries Clean Not Clean

91 Algorithm Steps 6. Expand and combine primitive chains and links

92 Assumptions No sharp turns
Road fragments are ”good” and long. “good”: Every small circle intersects in just two points Close fragments must have an intersection point Each input trajectory is close to a graph edge Each graph edge is sampled by an input trajectory g1 ≤3e p1 g2 ≤3e p2 [CGHS10] D. Chen, L. Guibas, J. Hershberger, J. Sun, Road network reconstruction for organizing paths, SODA, 2010.

93 Quality Guarantees Prove that if the assumptions are fulfilled, then:
The reconstructed primitive chains sample the good sections of the input graph. The number of edges in the reconstructed graph is three times the number of edges in the original graph. [CGHS10] D. Chen, L. Guibas, J. Hershberger, J. Sun, Road network reconstruction for organizing paths, SODA, 2010.

94 [AW12] Incrementally add one trajectory after another. For each trajectory: Use partial Fréchet distance to identify new and existing portions by combining mapmatching with partial Fréchet distance: Compute free space surface (à la map-matching) Find path that minimizes black portions, but measure path length only along the curve (not along graph)  Project free space onto curve, yielding sequence of intervals which is easy to process. Use min-link algorithm to reconcile existing portions [AW12] M. Ahmed, C. Wenk, Constructing Street Networks from GPS Trajectories, ESA, to appear, 2012.

95 Assumptions Reuse assumptions 2 and 3:
Road fragments are ”good” and long. “good”: Every small circle intersects in just two points Close fragments must have an intersection point  Projection approach is justified, because free space has special structure. Trajectory can only sample one good section in original network. g1 ≤3e p1 g2 ≤3e p2 [AW12] M. Ahmed, C. Wenk, Constructing Street Networks from GPS Trajectories, ESA, to appear, 2012.

96 Good and bad regions Good regions: We prove the quality guarantee that there is a 1-to-1 correspondence with bounded description complexity between well-separable good portions of original network and reconstructed graph. Bad regions: We give the first description and analysis of vertex regions.  It is relatively easy to handle well-sampled clean data. Deal with noisy data that is not well-sampled and give quality guarantees. [AW12] M. Ahmed, C. Wenk, Constructing Street Networks from GPS Trajectories, ESA, to appear, 2012.

97 Discussion Develop uncertainty models for the input (= trajectories) and the output. Develop algorithms (reconciling, map construction, etc.) for these models. Dual problem, keep trajectories for each road segment Use information from usual routes that people take Find combination of trajectories to route. Use results of previous queries/views to compute routing.


Download ppt "Algorithms for Map Construction and Comparison:"

Similar presentations


Ads by Google