Codota Logo
PreProcessDijkstra.run
Code IndexAdd Codota to your IDE (free)

How to use
run
method
in
org.matsim.core.router.util.PreProcessDijkstra

Best Java code snippets using org.matsim.core.router.util.PreProcessDijkstra.run (Showing top 7 results out of 315)

  • Common ways to obtain PreProcessDijkstra
private void myMethod () {
PreProcessDijkstra p =
  • Codota Iconnew PreProcessDijkstra()
  • Smart code suggestions by Codota
}
origin: matsim-org/matsim

@Override
public void run(final Network network) {
  super.run(network);
  if (!checkLinkLengths(network)) {
    log.warn("There are links with stored length smaller than their Euclidean distance in this network. Thus, A* cannot guarantee to calculate the least-cost paths between two nodes.");
  }
  updateMinTravelCostPerLength(network);
}
origin: matsim-org/matsim

  @Override
  public synchronized LeastCostPathCalculator createPathCalculator(final Network network, final TravelDisutility travelCosts, final TravelTime travelTimes) {
    if (this.usePreProcessData) {
      PreProcessDijkstra preProcessDijkstra = this.preProcessData.get(network);
      if (preProcessDijkstra == null) {
        preProcessDijkstra = new PreProcessDijkstra();
        preProcessDijkstra.run(network);
        this.preProcessData.put(network, preProcessDijkstra);
      }
      return new Dijkstra(network, travelCosts, travelTimes, preProcessDijkstra);
    }
    return new Dijkstra(network, travelCosts, travelTimes);
  }
}
origin: matsim-org/matsim

  @Override
  public synchronized LeastCostPathCalculator createPathCalculator(final Network network, final TravelDisutility travelCosts, final TravelTime travelTimes) {		
    if (this.usePreProcessData) {
      PreProcessDijkstra preProcessDijkstra = this.preProcessData.get(network);
      if (preProcessDijkstra == null) {
        preProcessDijkstra = new PreProcessDijkstra();
        preProcessDijkstra.run(network);
        this.preProcessData.put(network, preProcessDijkstra);
      }
      return new MultiNodeDijkstra(network, travelCosts, travelTimes, preProcessDijkstra, this.searchAllEndNodes);
    }
    
    return new MultiNodeDijkstra(network, travelCosts, travelTimes, this.searchAllEndNodes);
  }
}
origin: matsim-org/matsim

public TransitRouterVariableImpl(final TransitRouterConfig config, final TransitRouterNetworkTravelTimeAndDisutility ttCalculator, final TransitRouterNetworkWW routerNetwork) {
  this.config = config;
  this.transitNetwork = routerNetwork;
  this.ttCalculator = ttCalculator;
  this.dijkstra = new MultiNodeDijkstra(this.transitNetwork, this.ttCalculator, this.ttCalculator);
  PreProcessDijkstra preProcessDijkstra = new PreProcessDijkstra();
  preProcessDijkstra.run(routerNetwork);
  mDijkstra = new MultiDestinationDijkstra(routerNetwork, this.ttCalculator, this.ttCalculator, preProcessDijkstra);
}

origin: matsim-org/matsim

  @Override
  public synchronized LeastCostPathCalculator createPathCalculator(final Network network, final TravelDisutility travelCosts, final TravelTime travelTimes) {
    RoutingNetwork routingNetwork = this.routingNetworks.get(network);
    PreProcessDijkstra preProcessDijkstra = this.preProcessData.get(network);

    if (routingNetwork == null) {
      routingNetwork = this.routingNetworkFactory.createRoutingNetwork(network);
      
      if (this.usePreProcessData) {
        if (preProcessDijkstra == null) {
          preProcessDijkstra = new PreProcessDijkstra();
          preProcessDijkstra.run(network);
          this.preProcessData.put(network, preProcessDijkstra);
          
          for (RoutingNetworkNode node : routingNetwork.getNodes().values()) {
            node.setDeadEndData(preProcessDijkstra.getNodeData(node.getNode()));
          }
        }
      }
      
      this.routingNetworks.put(network, routingNetwork);
    }
    FastRouterDelegateFactory fastRouterFactory = new ArrayFastRouterDelegateFactory();
    
    return new FastDijkstra(routingNetwork, travelCosts, travelTimes, preProcessDijkstra, fastRouterFactory);
  }
}
origin: matsim-org/matsim

  @Override
  public synchronized LeastCostPathCalculator createPathCalculator(final Network network, final TravelDisutility travelCosts, final TravelTime travelTimes) {
    
    RoutingNetwork routingNetwork = this.routingNetworks.get(network);
    PreProcessDijkstra preProcessDijkstra = this.preProcessData.get(network);

    if (routingNetwork == null) {
      routingNetwork = this.routingNetworkFactory.createRoutingNetwork(network);
      
      if (this.usePreProcessData) {
        if (preProcessDijkstra == null) {
          preProcessDijkstra = new PreProcessDijkstra();
          preProcessDijkstra.run(network);
          this.preProcessData.put(network, preProcessDijkstra);

          for (RoutingNetworkNode node : routingNetwork.getNodes().values()) {
            node.setDeadEndData(preProcessDijkstra.getNodeData(node.getNode()));
          }
        }
      }
      
      this.routingNetworks.put(network, routingNetwork);
    }
    FastRouterDelegateFactory fastRouterFactory = new ArrayFastRouterDelegateFactory();
    
    return new FastMultiNodeDijkstra(routingNetwork, travelCosts, travelTimes, preProcessDijkstra, fastRouterFactory, this.searchAllEndNodes);
  }
}
origin: matsim-org/matsim

  @Override
  public LeastCostPathCalculator createPathCalculator(final Network network, final TravelDisutility travelCosts, final TravelTime travelTimes) {
    
    RoutingNetwork routingNetwork = this.routingNetworks.get(network);
    PreProcessDijkstra preProcessDijkstra = this.preProcessData.get(network);
  
    if (routingNetwork == null) {
      routingNetwork = this.routingNetworkFactory.createRoutingNetwork(network);
      
      if (this.usePreProcessData) {
        if (preProcessDijkstra == null) {
          preProcessDijkstra = new PreProcessDijkstra();
          preProcessDijkstra.run(network);
          this.preProcessData.put(network, preProcessDijkstra);
        }
        if (preProcessDijkstra.containsData()) {
          for (RoutingNetworkNode node : routingNetwork.getNodes().values()) {
            node.setDeadEndData(preProcessDijkstra.getNodeData(node.getNode()));
          }
        }
      }
      
      this.routingNetworks.put(network, routingNetwork);
    }
    FastRouterDelegateFactory fastRouterFactory = new ArrayFastRouterDelegateFactory();
    
    return new BackwardFastMultiNodeDijkstra(routingNetwork, travelCosts, travelTimes, 
        preProcessDijkstra, fastRouterFactory, this.searchAllEndNodes);
  }
}
org.matsim.core.router.utilPreProcessDijkstrarun

Popular methods of PreProcessDijkstra

  • <init>
  • containsData
  • getNodeData
    Returns the role for the given Node. Creates a new Role if none exists yet.
  • getIncidentNodes
  • markDeadEnds
    Marks nodes that are in dead ends (i.e. nodes that are connected through a single node to the rest o

Popular in Java

  • Finding current android device location
  • getExternalFilesDir (Context)
  • scheduleAtFixedRate (ScheduledExecutorService)
    Creates and executes a periodic action that becomes enabled first after the given initial delay, and
  • putExtra (Intent)
  • Point (java.awt)
    A point representing a location in (x, y) coordinate space, specified in integer precision.
  • FileNotFoundException (java.io)
    Thrown when a file specified by a program cannot be found.
  • InetAddress (java.net)
    This class represents an Internet Protocol (IP) address. An IP address is either a 32-bit or 128-bit
  • Selector (java.nio.channels)
    A controller for the selection of SelectableChannel objects. Selectable channels can be registered w
  • Timer (java.util)
    A facility for threads to schedule tasks for future execution in a background thread. Tasks may be s
  • Table (org.hibernate.mapping)
    A relational table
Codota Logo
  • Products

    Search for Java codeSearch for JavaScript codeEnterprise
  • IDE Plugins

    IntelliJ IDEAWebStormAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimAtomGoLandRubyMineEmacsJupyter
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogCodota Academy Plugin user guide Terms of usePrivacy policyJava Code IndexJavascript Code Index
Get Codota for your IDE now