eclipse-sumo / sumo

Eclipse SUMO is an open source, highly portable, microscopic and continuous traffic simulation package designed to handle large networks. It allows for intermodal simulation including pedestrians and comes with a large set of tools for scenario creation.
https://eclipse.dev/sumo
Eclipse Public License 2.0
2.54k stars 1.43k forks source link

Duarouter unable to find route for intermodal trip #15318

Closed 1BlattPapier closed 1 month ago

1BlattPapier commented 2 months ago

I created demand for a multimodal simulation and stored in a trips.xml. I can run the simulation without errors. However, when I run duaIterate.py to reach an equilibrium, duaIterate does not seem to be able to handle and find routes for the multimodal trips.

SUMO-version: 1.20

operating system: Rocky Linux 8.9

Error message:

Warning: No connection between edge '1226623062#0' and edge '78059338' found.
Error: No route for trip in person '8340001'.
Quitting (on error).

Trip in question:

<person id="8340001" depart="25500">
    <personTrip from="1226623062#0" to="78059338" modes="public"/>
</person>

To reproduce:

  1. Unzip folder (files_to_reproduce_error.zip).
  2. Run python3 sumo/tools/assign/duaIterate.py -n wedding.net.xml -t 'trips.xml,gtfs_pt_vehicles.add.xml' -+ 'gtfs_pt_stops.add.xml,vtypes.xml' --skip-first-routing
m-kro commented 2 months ago

You'll have to work on your network to connect places better with each other. At various intersections crossings for pedestrians are missing. So it is not a surprise some relations are unfeasible. If you want to try first to run duaIterate.py and ignore errors call it with duarouter--ignore-errors true (see doc / duarouter arguments).

1BlattPapier commented 2 months ago

Thanks for the reply! I know that the network is not optimal and has, e.g., missing crossings. Sadly it is not feasible for me to resolve all those issues as I want to scale the size of the network later on. However, I do catch non-existing relations before by checking whether a route exists between given edges using traci before adding it to trips.xml.

Also, the problem is that the relation does seem to be feasible when running it like that with SUMO as a route does seem to exist. Only when using duaIterate.py I get that error.

This should be visible when running the command I provided above as --skip-first-routing should just run the demand and not reroute as well as when running the demand with sumo like the following: sumo --net-file wedding.net.xml --additional-files 'vtypes.xml,gtfs_pt_stops.add.xml' --route-files 'gtfs_pt_vehicles.add.xml,trips_modified.xml'

Glad if you point me to where I am missing something!

1BlattPapier commented 2 months ago

Hey I want to comment again as I am not sure whether I was clear enough:

Normal routing and running the simulation with SUMO works fine without errors and there are routes found for the intermodal trips. Only when using duaIterate.py it does not find routes.

m-kro commented 2 months ago

The public transport files are not added to the duarouter call for unknown reasons. As the person needs to take public transport, the trip fails.

m-kro commented 2 months ago

Please try

python3 sumo/tools/assign/duaIterate.py -n wedding.net.xml -t trips.xml -+ vtypes.xml,gtfs_pt_stops.add.xml,gtfs_pt_vehicles.add.xml --skip-first-routing duarouter--additional-files vtypes.xml,gtfs_pt_stops.add.xml,gtfs_pt_vehicles.add.xml

See docs. You can always load a route file as an additional file as well. This has some implications regarding the loading order and time but in this context it seems right as you don't want to change the public transport schedule.