Changeset 8429 for branches/RoutePlanning
- Timestamp:
- 08/08/12 13:40:03 (12 years ago)
- Location:
- branches/RoutePlanning
- Files:
-
- 1 added
- 1 deleted
- 9 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/RoutePlanning/HeuristicLab.Algorithms.GraphRouting/3.3/AStarAlgorithm.cs
r8362 r8429 5 5 namespace HeuristicLab.Algorithms.GraphRouting { 6 6 public class AStarAlgorithm : IRouter { 7 private Graph graph;7 private OsmGraph graph; 8 8 9 9 private Dictionary<long, float> distances; … … 14 14 private PriorityQueue<float, long> openList; 15 15 16 public AStarAlgorithm( Graph graph) {16 public AStarAlgorithm(OsmGraph graph) { 17 17 this.graph = graph; 18 18 } -
branches/RoutePlanning/HeuristicLab.Algorithms.GraphRouting/3.3/AStarAlgorithmV2.cs
r8426 r8429 5 5 namespace HeuristicLab.Algorithms.GraphRouting { 6 6 public class AStarAlgorithmV2 : IRouter { 7 private Graph graph;7 private OsmGraph graph; 8 8 9 9 private Dictionary<long, float> distances; … … 14 14 private Dictionary<long, NodeData> openListLookup; 15 15 16 public AStarAlgorithmV2( Graph graph) {16 public AStarAlgorithmV2(OsmGraph graph) { 17 17 this.graph = graph; 18 18 } -
branches/RoutePlanning/HeuristicLab.Algorithms.GraphRouting/3.3/BidirectionalDijkstraAlgorithm.cs
r8423 r8429 5 5 namespace HeuristicLab.Algorithms.GraphRouting { 6 6 public class BidrectionalDijkstraAlgorithm : IRouter { 7 private Graph graph;7 private OsmGraph graph; 8 8 9 9 private HashSet<long> visitedNodesForward; … … 16 16 private Dictionary<long, long> predecessorsBackward; 17 17 18 public BidrectionalDijkstraAlgorithm( Graph graph) {18 public BidrectionalDijkstraAlgorithm(OsmGraph graph) { 19 19 this.graph = graph; 20 20 } -
branches/RoutePlanning/HeuristicLab.Algorithms.GraphRouting/3.3/DijkstraAlgorithm.cs
r8314 r8429 5 5 namespace HeuristicLab.Algorithms.GraphRouting { 6 6 public class DijkstraAlgorithm : IRouter { 7 private Graph graph;7 private OsmGraph graph; 8 8 9 9 private HashSet<long> visitedNodes; … … 12 12 private Dictionary<long, long> predecessors; 13 13 14 public DijkstraAlgorithm( Graph graph) {14 public DijkstraAlgorithm(OsmGraph graph) { 15 15 this.graph = graph; 16 16 } -
branches/RoutePlanning/HeuristicLab.Problems.RoutePlanning.Test/Program.cs
r8426 r8429 23 23 24 24 IDataSource ds = TestLoad(file6); 25 Graph.Graph graph = new Graph.Graph(ds);26 TestRouter(new DijkstraAlgorithm(graph), 529102170, 31372732, false); // inz - hgb27 TestRouter(new AStarAlgorithm(graph), 529102170, 31372732, false); // inz - hgb25 OsmGraph graph = new OsmGraph(ds); 26 //TestRouter(new DijkstraAlgorithm(graph), 529102170, 31372732, false); // inz - hgb 27 //TestRouter(new AStarAlgorithm(graph), 529102170, 31372732, false); // inz - hgb 28 28 TestRouter(new AStarAlgorithmV2(graph), 529102170, 31372732, false); // inz - hgb 29 TestRouter(new BidrectionalDijkstraAlgorithm(graph), 529102170, 31372732, false); // inz - hgb29 //TestRouter(new BidrectionalDijkstraAlgorithm(graph), 529102170, 31372732, false); // inz - hgb 30 30 31 31 //TestLoadAndRouter(file6, typeof(DijkstraAlgorithm), 529102170, 31372732, false, false); // inz - hgb … … 96 96 Console.WriteLine("Loading Time: {0}", sw.Elapsed); 97 97 Console.WriteLine(); 98 Graph.Graph graph = new Graph.Graph(xmlDs);98 OsmGraph graph = new OsmGraph(xmlDs); 99 99 IRouter router = (IRouter)Activator.CreateInstance(routerType, graph); 100 100 Console.Write("Calculate route ... "); … … 122 122 } 123 123 124 private static void WriteGPXFile( Graph.Graph graph, long[] route, string file) {124 private static void WriteGPXFile(OsmGraph graph, long[] route, string file) { 125 125 XmlWriterSettings settings = new XmlWriterSettings(); 126 126 settings.Indent = true; -
branches/RoutePlanning/HeuristicLab.Problems.RoutePlanning/3.3/Graph/IEdge.cs
r8300 r8429 1 1 2 2 namespace HeuristicLab.Problems.RoutePlanning.Graph { 3 public interface IEdge< Vertex> {4 VertexSource { get; }5 VertexTarget { get; }3 public interface IEdge<T> { 4 T Source { get; } 5 T Target { get; } 6 6 } 7 7 } -
branches/RoutePlanning/HeuristicLab.Problems.RoutePlanning/3.3/HeuristicLab.Problems.RoutePlanning.csproj
r8408 r8429 57 57 <ItemGroup> 58 58 <Compile Include="Graph\Edge.cs" /> 59 <Compile Include="Graph\ Graph.cs" />59 <Compile Include="Graph\OsmGraph.cs" /> 60 60 <Compile Include="Graph\IEdge.cs" /> 61 61 <Compile Include="Graph\Route.cs" /> -
branches/RoutePlanning/HeuristicLab.Problems.RoutePlanning/3.3/RoutePlanningProblem.cs
r8301 r8429 27 27 using HeuristicLab.Parameters; 28 28 using HeuristicLab.Persistence.Default.CompositeSerializers.Storable; 29 using HeuristicLab.Problems.RoutePlanning.Graph; 29 30 using HeuristicLab.Problems.RoutePlanning.Osm; 30 31 using HeuristicLab.Problems.RoutePlanning.Osm.Data; … … 41 42 42 43 IDataSource dataSource; 43 Graph.Graph graph;44 OsmGraph graph; 44 45 45 46 #region Parameter Properties … … 105 106 FileInfo f = new FileInfo(file); 106 107 dataSource = new XmlDataSource(file); 107 graph = new Graph.Graph(dataSource);108 graph = new OsmGraph(dataSource); 108 109 109 110 Name = f.Name; -
branches/RoutePlanning/RoutePlanning.sln
r8350 r8429 9 9 EndProject 10 10 Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "HeuristicLab.Algorithms.GraphRouting", "HeuristicLab.Algorithms.GraphRouting\3.3\HeuristicLab.Algorithms.GraphRouting.csproj", "{4FE72407-6CAA-4F41-9F2D-D45FDA19ED3C}" 11 EndProject 12 Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution Items", "{9FD7CBFA-D7D9-4FA3-9038-CD867CA9B3B6}" 11 13 EndProject 12 14 Global
Note: See TracChangeset
for help on using the changeset viewer.