Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error in the reconstruction of a OSM geometry #994

Open
j3r3m1 opened this issue Sep 16, 2024 · 3 comments
Open

Error in the reconstruction of a OSM geometry #994

j3r3m1 opened this issue Sep 16, 2024 · 3 comments

Comments

@j3r3m1
Copy link
Collaborator

j3r3m1 commented Sep 16, 2024

When I run the following json file,

{
    "description": "Processing OSM data",
    "input": {
    	"area" : 100000,
    	"timeout": 9000,
	"maxsize":4294967296,
        "locations": [
            [51.2, 1.0, 51.4, 1.2]
        ]
    },
    "output": {
        "folder": "/tmp"
    },
    "parameters": {
        "rsu_indicators": {
            "indicatorUse": [
                "LCZ",
                "TEB"
            ],
            "svfSimplified": true,
            "estimateHeight": true
        }
    }
}

I get the following error message:

Exception lors de l'appel de la fonction définie par l'utilisateur: "intersection(POLYGON ((374379.0533518583 5688047.310188733, 374380.46387517086 5688051.381206891, 374387.76897208317 5688051.947139655, 374392.19804044906 5688049.791007236, 374390.3633792737 5688043.493979111, 374385.4619225159 5688041.745187085, 374379.51445349754 5688043.382319197, 374379.0533518583 5688047.310188733), (374343.1856932173 5688054.511769417, 374344.90738304134 5688034.096770712, 374355.8946427107 5688012.330209435, 374375.4493779954 5688007.031745351, 374384.47568311135 5688011.260502016, 374399.58793831663 5688006.438493751, 374412.9078766183 5688019.451876591, 374423.34204334795 5688035.874150383, 374423.6279998345 5688062.548518093, 374412.0891129635 5688076.907093986, 374393.28206247045 5688082.554227708, 374383.9454566629 5688095.757223021, 374370.2533379167 5688097.94077391, 374355.9282182272 5688089.402825621, 374345.52126637433 5688074.092667036, 374343.1856932173 5688054.511769417)), POLYGON ((360271.0706458315 5673966.967184718, 360877.1545035015 5696205.923488882, 374788.37189143745 5695845.264689232, 374242.92491750914 5673605.747899836, 360271.0706458315 5673966.967184718))): unable to assign free hole to a shell [ (374344.90738304134, 5688034.096770712) ]"
Exception calling user-defined function: "intersection(POLYGON ((374379.0533518583 5688047.310188733, 374380.46387517086 5688051.381206891, 374387.76897208317 5688051.947139655, 374392.19804044906 5688049.791007236, 374390.3633792737 5688043.493979111, 374385.4619225159 5688041.745187085, 374379.51445349754 5688043.382319197, 374379.0533518583 5688047.310188733), (374343.1856932173 5688054.511769417, 374344.90738304134 5688034.096770712, 374355.8946427107 5688012.330209435, 374375.4493779954 5688007.031745351, 374384.47568311135 5688011.260502016, 374399.58793831663 5688006.438493751, 374412.9078766183 5688019.451876591, 374423.34204334795 5688035.874150383, 374423.6279998345 5688062.548518093, 374412.0891129635 5688076.907093986, 374393.28206247045 5688082.554227708, 374383.9454566629 5688095.757223021, 374370.2533379167 5688097.94077391, 374355.9282182272 5688089.402825621, 374345.52126637433 5688074.092667036, 374343.1856932173 5688054.511769417)), POLYGON ((360271.0706458315 5673966.967184718, 360877.1545035015 5696205.923488882, 374788.37189143745 5695845.264689232, 374242.92491750914 5673605.747899836, 360271.0706458315 5673966.967184718))): unable to assign free hole to a shell [ (374344.90738304134, 5688034.096770712) ]"; SQL statement:
select id , st_intersection(a.the_geom, b.the_geom) as the_geom, a."natural", a."layer" FROM OSM_WATER_b983eb0f_dc2e_4415_8e43_f48e21b48fb6 AS a, ZONE_ENVELOPE_74cf877c_6fdb_47b1_89ef_773d100ad4a8 AS b WHERE a.the_geom && b.the_geom and (a."seamark:type" is null or a."seamark:type" in ('harbour_basin', 'harbour')) [90105-224]

The geometry causing the problem is the following: https://www.openstreetmap.org/relation/12219391

@ebocher, should we correct the geometry (there are only 3 issues on whole Europe, would be strange to change the way the algorithm work only for this case) ?

@ebocher
Copy link
Member

ebocher commented Sep 16, 2024

It seems that the geometry is incorrectly modeled in OSM : https://www.google.fr/maps/@51.3297726,1.1979136,295m/data=!3m1!1e3?entry=ttu&g_ep=EgoyMDI0MDkxMS4wIKXMDSoASAFQAw%3D%3D

It would be great to check how we construct this data with GeoClimate.
I will check it.

ebocher added a commit to ebocher/geoclimate-1 that referenced this issue Sep 16, 2024
@ebocher
Copy link
Member

ebocher commented Sep 16, 2024

Done here #996

geoms_pb

j3r3m1 added a commit that referenced this issue Sep 16, 2024
@ebocher
Copy link
Member

ebocher commented Nov 15, 2024

Fixed ?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants