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.57k stars 1.44k forks source link

OSM Web Wizard error in generating scenario #15253

Open magni5 opened 4 months ago

magni5 commented 4 months ago

First of all, thank you for your work.

My situation is the following.

SUMO-version: 1.20.0 operating system: Fedora Linux 40

I have downloaded SUMO from FlatHub. From the file system location of the application I have run python osmWebWizard.py. Using the browser (tried both from Firefox and Brave) I have tried to Generate Scenario (both with default and custom configuration, even with less "resources" as possible). The generation starts but then it gives error. Below the output from the terminal.

Cannot create directory '/var/lib/flatpak/app/org.eclipse.sumo/x86_64/stable/17548b556b3903938ed1f4b8d2cda926484e7bbb21f0b2fce409a99b4b2d0039/files/share/sumo/tools/2024-07-22-12-39-47'.
Building scenario in '/home/marco/Sumo/2024-07-22-12-39-47'.
Downloading map data
200 OK
Converting map data
/var/lib/flatpak/app/org.eclipse.sumo/x86_64/stable/17548b556b3903938ed1f4b8d2cda926484e7bbb21f0b2fce409a99b4b2d0039/files/share/sumo/bin/netconvert: error while loading shared libraries: libgdal.so.35: cannot open shared object file: No such file or directory
/var/lib/flatpak/app/org.eclipse.sumo/x86_64/stable/17548b556b3903938ed1f4b8d2cda926484e7bbb21f0b2fce409a99b4b2d0039/files/share/sumo/bin/netconvert: error while loading shared libraries: libgdal.so.35: cannot open shared object file: No such file or directory
/var/lib/flatpak/app/org.eclipse.sumo/x86_64/stable/17548b556b3903938ed1f4b8d2cda926484e7bbb21f0b2fce409a99b4b2d0039/files/share/sumo/bin/polyconvert: error while loading shared libraries: libgdal.so.35: cannot open shared object file: No such file or directory
/var/lib/flatpak/app/org.eclipse.sumo/x86_64/stable/17548b556b3903938ed1f4b8d2cda926484e7bbb21f0b2fce409a99b4b2d0039/files/share/sumo/bin/polyconvert: error while loading shared libraries: libgdal.so.35: cannot open shared object file: No such file or directory
Traceback (most recent call last):
  File "/var/lib/flatpak/app/org.eclipse.sumo/x86_64/stable/17548b556b3903938ed1f4b8d2cda926484e7bbb21f0b2fce409a99b4b2d0039/files/share/sumo/tools/osmWebWizard.py", line 514, in build
    builder.build()
  File "/var/lib/flatpak/app/org.eclipse.sumo/x86_64/stable/17548b556b3903938ed1f4b8d2cda926484e7bbb21f0b2fce409a99b4b2d0039/files/share/sumo/tools/osmWebWizard.py", line 319, in build
    self.edges = sumolib.net.readNet(os.path.join(self.tmp, self.files["net"])).getEdges()
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/var/lib/flatpak/app/org.eclipse.sumo/x86_64/stable/17548b556b3903938ed1f4b8d2cda926484e7bbb21f0b2fce409a99b4b2d0039/files/share/sumo/tools/sumolib/net/__init__.py", line 968, in readNet
    for event, v in lxml.etree.iterparse(source, events=("start", "end")):
                    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "src/lxml/iterparse.pxi", line 77, in lxml.etree.iterparse.__init__
FileNotFoundError: [Errno 2] No such file or directory: '/home/marco/Sumo/2024-07-22-12-39-47/osm.net.xml.gz'

[Errno 2] No such file or directory: '/home/marco/Sumo/2024-07-22-12-39-47/osm.net.xml.gz' Recovering
[Errno 2] No such file or directory: '/home/marco/Sumo/2024-07-22-12-39-47/osm.net.xml.gz' Recovering
[Errno 2] No such file or directory: '/home/marco/Sumo/2024-07-22-12-39-47/osm.net.xml.gz' Recovering

In the folder /home/marco/Sumo/2024-07-22-12-39-47 is generated only a osm_bbox.osm.xml.gz file, but when uploaded to SUMO it gives Error: No option with the name 'tag' exists.

m-kro commented 4 months ago

osm_bbox.osm.xml.gz is the downloaded OSM file which still needs to be converted to a SUMO network file. In your case this process fails because libgdal / GDAL library cannot be found.

behrisch commented 3 months ago

The problem is that calling executables from inside the flatpak is not that easy. I tried to do flatpak run --command=bash org.eclipse.sumo. I can at least run netconvert then. But if I run the webWizard inside that bash, my browser refuses to connect to the index.html. The same thing happens if I start the web wizard from the flatpak directly. Can you recheck whether the bask workaround helps in your case?