Slideshare uses cookies to improve functionality and performance, and to provide you with relevant advertising. If you continue browsing the site, you agree to the use of cookies on this website. See our User Agreement and Privacy Policy.

Slideshare uses cookies to improve functionality and performance, and to provide you with relevant advertising. If you continue browsing the site, you agree to the use of cookies on this website. See our Privacy Policy and User Agreement for details.

Like this presentation? Why not share!

- How we use neo4j for finding public... by Evgenii Kozhanov 3763 views
- Wanderu - Lessons from Building a T... by Neo4j - The Faste... 5114 views
- Temporal graph by Vinay Sarda 1315 views
- FluxGraph: a time-machine for your ... by datablend 5269 views
- 40まで開発のリーダーだった男がインフラの運用のリーダー(見習い)にな... by Hiroyuki Hiki 6021 views
- Neo, Titan & Cassandra by johnrjenson 1040 views

2,013 views

1,765 views

1,765 views

Published on

No Downloads

Total views

2,013

On SlideShare

0

From Embeds

0

Number of Embeds

1

Shares

0

Downloads

45

Comments

0

Likes

2

No embeds

No notes for slide

- 1. Ben Earlam [@BenEarlam] Nima Montazeri [@Nimamon] [Presented By] Route Finding in Time Dependent Graphs [Located]
- 2. What are we going to cover? Introduction Why Graph? About The Data Time Independent Model Time-dependent Model Demo Q&A
- 3. How it all started? Experiment & Learn Real world problem 5 Week tech lab Produce working software Small team
- 4. Manchester
- 5. The Focus… Travel & Transport (Manchester) Open Data Open Source Metrolink System (25 Million Journeys p/a) Tech: Not Only SQL • Neo4J Experiment with Graph database as way of modeling a travel network Everything in the Cloud (AWS)
- 6. Tram Network
- 7. Why Graph database? 5 2 3 2 5 3 2 2 Map © Transport for Greater Manchester 2013
- 8. Tram Data… Tabular Data in text file (General Transit Feed Specification) 250 Cities publish GTFS data http://www.gtfs-data-exchange.com/agency/mta-new-york-citytransit/ Stops Stop_id Stop Times Trip_id Trips Service_id Route_id Routes Calendar
- 9. Earliest Arrival Time Problem Earliest Arrival Time (EAT) attempts to find the path through a network from source to destination, such that given a start time T we arrive at the destination at the earliest possible time after T.
- 10. Starting point… G1 G2 2 2 F1 7 [goes_to] A2 3 3 [goes_to] B1 [platform] [platform] A1 F2 C1 4 7 B2 4 C2
- 11. Iterations 1 2 3 4
- 12. Time Independent 3 B [goes_to] R1 C C D [Depart] [board] A 4 [Depart] [board] [goes_to] R1 B [Depart] [board] R1 A R2 B 5 [goes_to] R2 D
- 13. Applying the timetable Paths Timetable Invalid Paths Valid Paths
- 14. Different Graph at each point in time…
- 15. Different Graph at each point in time… Example: A -> E A B D C E 9:30 AM / Friday F
- 16. Different Graph at each point in time… Example: A -> E A B D C E 9:30 AM / Saturday F
- 17. Different Graph at each point in time… Example: A -> E A B D C E 10:00 AM / Saturday F
- 18. Modeling Time Time Expanded Model • Model temporal events as Nodes – – Arrivals – Department – Transfers • Duration as edge weight, use Dijkstra to find EAT Time Dependent Model • Model temporal data as properties • Model all distinct routes with 2 Node types – Station Station Route • Use modified Dijsktra to perform Travel Time Function during traversal
- 19. Time Dependent Model 3 [board] [goes_to] [goes_to] R1 C B [Depart] A 4 R1 B [Depart] [board] R1 A C
- 20. Modeling Time… Up to 900 Trams… A [T2] [T3] [T4] [T5] [T6] [T7] [T8] [T9] [T2] [T3] [T4] [T5] R1 B [board] 09:40 09:50 10:10 10:20 10:30 10:40 10:50 11:00 [Depart] [board] R1 A [T1] 09:33 300 Nodes 100K Relations 300K Properties B 09:43 09:53 10:13 10:23 [T7] 10:43 [T8] 10:53 [T9] 11:03 R1 C [Depart] [T1] 09:30 C
- 21. Modeling Time… "Time is a dimension in which events can be ordered from the past through the present into the future.” - Wikipedia
- 22. Modeling Time… 10:15 A [T2] [T3] [T4] [T5] [T6] [T7] [T8] [T9] [T2] [T3] [T4] [T5] R1 B [board] 09:40 09:50 10:10 10:20 10:30 10:40 10:50 11:00 [Depart] [board] R1 A [T1] 09:33 B 09:43 09:53 10:13 10:23 [T7] 10:43 [T8] 10:53 [T9] 11:03 R1 C [Depart] [T1] 09:30 C
- 23. Traversal Framework Traversal Framework Evaluator Path Expander Branch Selector
- 24. Path Expander The traversal framework use PathExpanders to discover the relationships that should be followed from a particular path to further branches in the traversal. public class TripPathExpander implements PathExpander<GraphState> { public Iterable<Relationship> expand(…) { } }
- 25. The App • http://www.tramchester.co.uk/
- 26. Any Questions? Follow us on Twitter: @tramchester
- 27. Traversal Framework Declarative Java API It enables the user to specify a set of constraints that limit the parts of the graph the traversal is allowed to visit Can specify which relationship types to follow, and in which direction (effectively specifying relationship filters) Can specify a user-defined path evaluator that is triggered with each node encountered
- 28. A nice problem to have…
- 29. Stop Trip Arr. Dept. 1 12:00 12:01 B 1 12:05 12:05 C 1 12:10 C 2 12:11 D 2 12:16 C 3 12:20 D 3 12:26 A Example - Time Dependent Model T1 Arr.12:00 Dept.12:01 R1 B T1 Arr.12:05 Dept.12:05 T2 Arr.12:10 Dept.12:21 T3 Arr.12:20 Dept.12:26 B R1 C R1 D C [Depart] [Depart] [board] A 12:21 [board] [board] [Depart] [board] R1 A 12:11 D
- 30. Spatial Indexes A B C D P

No public clipboards found for this slide

×
### Save the most important slides with Clipping

Clipping is a handy way to collect and organize the most important slides from a presentation. You can keep your great finds in clipboards organized around topics.

Be the first to comment