bmetrafficlab / OSM2VISSIM

MIT License
6 stars 3 forks source link

Converted network does not have a correspondence with the basemap #3

Open temospena opened 1 day ago

temospena commented 1 day ago

Hi, First of all, thanks for this great script!

I was using this to convert an .osm file (exported directly from OSM web site) to VISSIM, for an intersection in Lisbon, Portugal.

I noticed that the resulted vissim network falls about -1km (X) and 4km (Y) aside where it was supposed to be located. I wonder why is that...

Here is an example, of where it "lands" image

and where it was supposed to be: image

I was looking at your code with @gmatosferreira and wonder if it comes from the conversion of CRS. So we tried to use a python library (from pyproj import Transformer) to deal directly with CRS transform, but the results were exactly the same, doesn't change anything.

We further investigated if this was a basemap error, but the misplace is exactly the same using photo Bing, OSM tiles, of PTV tiles.

Also, we tried to convert from an example closer to the 0,0 CRS, to check how the error would behave. And so, from an intersection in São Tomé, near the Equator (about 0.3 lat), it still is misplaced, but this time with only about 0.8 km (X) and 0.04 km (Y) image

Do you have any clue of what is happening here, and how to overcome that?

Sys info: I am using VISSIM 2024 and Python 3.12. Here are the OSM files used in both cases osm_files.zip

Thanks in advance

temospena commented 1 day ago

Would it have anything to do with this? https://alastaira.wordpress.com/2011/01/23/the-google-maps-bing-maps-spherical-mercator-projection/