Upgrade to Pro — share decks privately, control downloads, hide ads and more …

Improving the usability of 3D city models

Hugo Ledoux
January 22, 2019

Improving the usability of 3D city models

Presented at the Universität Münster GI-Forum (https://www.uni-muenster.de/Geoinformatics/en/GI-Forum/index.php)

Hugo Ledoux

January 22, 2019
Tweet

More Decks by Hugo Ledoux

Other Decks in Research

Transcript

  1. 2

  2. More and more 3D (open) data from cities 5 Whole

    North Rhine-Westphalia: 10M+ LoD2 buildings
  3. More and more 3D (open) data from cities 8 Whole

    of the Netherlands: 10M+ LoD1 buildings + terrain, roads, forest
  4. 9 solar potential shadow analysis noise modelling energy estimation bomb

    detonation wind turbulence pollutant tracking
  5. BUT

  6. 1. CityGML hinders the processing of 3D data about cities

    2. Most 3D datasets are rigged with errors 2 major problems:
  7. CityGML files are very complex 14 • files are deeply

    nested, and large • no parsers in JavaScript • few software packages use CityGML • many diff ways to do one thing • I personally get each time I get a new file
  8. v0.8 released 17 1. "Building" 2. "BuildingPart" 3. "BuildingInstallation" 4.

    "Road" 5. "Railway" 6. "TransportSquare" 7. "TINRelief" 8. "WaterBody" 9. "PlantCover" 10. "SolitaryVegetationObject" 11. "LandUse" 12. "CityFurniture" 13. "GenericCityObject" 14. "Bridge" 15. "BridgePart" 16. "BridgeInstallation" 17. "BridgeConstructionElement" 18. "Tunnel" 19. "TunnelPart" 20. “TunnelInstallation” 21. “CityObjectGroup” • all modules mapped " • software for full conversion CityGML <-> CityJSON • software to visualise (azul) and to manipulate (cjio)
  9. Same information as CityGML, but in JSON format 18 {

    "type": “CityJSON", "version": “0.8”, "metadata": { "referenceSystem": "urn:ogc:def:crs:EPSG::7415", }, "CityObjects": { "id-1": { "type": "Building", "attributes": { "measuredHeight": 22.3, "roofType": "gable", "owner": “Elvis Presley" }, "geometry": [ { "type": "MultiSurface", "boundaries": [ [[0, 3, 2, 1]], [[4, 5, 6, 7]], [[0, 1, 5, 4]] ] } ] } }, "vertices": [ [23.1, 2321.2, 11.0], [111.1, 321.1, 12.0], ... ], "appearance": { "materials": [], "textures":[], "vertices-texture": [] } }
  10. A CityJSON file 19 version CityJSON { "type": “CityJSON", "version":

    “0.8”, "metadata": { "referenceSystem": "urn:ogc:def:crs:EPSG::7415", }, "CityObjects": { "id-1": { "type": "Building", "attributes": { "measuredHeight": 22.3, "roofType": "gable", "owner": “Elvis Presley" }, "geometry": [ { "type": "MultiSurface", "boundaries": [ [[0, 3, 2, 1]], [[4, 5, 6, 7]], [[0, 1, 5, 4]] ] } ] } }, "vertices": [ [23.1, 2321.2, 11.0], [111.1, 321.1, 12.0], ... ], "appearance": { "materials": [], "textures":[], "vertices-texture": [] } }
  11. A CityJSON file 20 metadata, ISO19115 “compliant” CityGML has no

    mechanism in v2.0 but we thought it’s important ALL geometries have the same CRS, unlike CityGML { "type": “CityJSON", "version": “0.8”, "metadata": { "referenceSystem": "urn:ogc:def:crs:EPSG::7415", }, "CityObjects": { "id-1": { "type": "Building", "attributes": { "measuredHeight": 22.3, "roofType": "gable", "owner": “Elvis Presley" }, "geometry": [ { "type": "MultiSurface", "boundaries": [ [[0, 3, 2, 1]], [[4, 5, 6, 7]], [[0, 1, 5, 4]] ] } ] } }, "vertices": [ [23.1, 2321.2, 11.0], [111.1, 321.1, 12.0], ... ], "appearance": { "materials": [], "textures":[], "vertices-texture": [] } }
  12. A CityJSON file 21 All City Objects listed here, indexed

    by their ID Each have geometries + attributes { "type": “CityJSON", "version": “0.8”, "metadata": { "referenceSystem": "urn:ogc:def:crs:EPSG::7415", }, "CityObjects": { "id-1": { "type": "Building", "attributes": { "measuredHeight": 22.3, "roofType": "gable", "owner": “Elvis Presley" }, "geometry": [ { "type": "MultiSurface", "boundaries": [ [[0, 3, 2, 1]], [[4, 5, 6, 7]], [[0, 1, 5, 4]] ] } ] } }, "vertices": [ [23.1, 2321.2, 11.0], [111.1, 321.1, 12.0], ... ], "appearance": { "materials": [], "textures":[], "vertices-texture": [] } }
  13. A CityJSON file 22 Geometry is ID of the vertex,

    global list compression + more “topology” { "type": “CityJSON", "version": “0.8”, "metadata": { "referenceSystem": "urn:ogc:def:crs:EPSG::7415", }, "CityObjects": { "id-1": { "type": "Building", "attributes": { "measuredHeight": 22.3, "roofType": "gable", "owner": “Elvis Presley" }, "geometry": [ { "type": "MultiSurface", "boundaries": [ [[0, 3, 2, 1]], [[4, 5, 6, 7]], [[0, 1, 5, 4]] ] } ] } }, "vertices": [ [23.1, 2321.2, 11.0], [111.1, 321.1, 12.0], ... ], "appearance": { "materials": [], "textures":[], "vertices-texture": [] } }
  14. A CityJSON file 23 material + texture possible { "type":

    “CityJSON", "version": “0.8”, "metadata": { "referenceSystem": "urn:ogc:def:crs:EPSG::7415", }, "CityObjects": { "id-1": { "type": "Building", "attributes": { "measuredHeight": 22.3, "roofType": "gable", "owner": “Elvis Presley" }, "geometry": [ { "type": "MultiSurface", "boundaries": [ [[0, 3, 2, 1]], [[4, 5, 6, 7]], [[0, 1, 5, 4]] ] } ] } }, "vertices": [ [23.1, 2321.2, 11.0], [111.1, 321.1, 12.0], ... ], "appearance": { "materials": [], "textures":[], "vertices-texture": [] } }
  15. BuildingParts: links between City Objects 24 "CityObjects": { "id-1": {

    "type": "Building", "attributes": { "roofType": "gable" }, "children": ["id-56", “id-832”, “mybalcony”] }, "id-56": { "type": “BuildingPart", "parent": “id-1", ... }, "mybalcony": { "type": "BuildingInstallation", "parent": “id-1”, ... } }
  16. BuildingParts: links between City Objects 25 "CityObjects": { "id-1": {

    "type": "Building", "attributes": { "roofType": "gable" }, "children": ["id-56", “id-832”, “mybalcony”] }, "id-56": { "type": “BuildingPart", "parent": “id-1", ... }, "mybalcony": { "type": "BuildingInstallation", "parent": “id-1”, ... } } goal == a flat schema
  17. Python parser is simple 27 import json fin = open('mycity.json')

    cm = json.loads(fin.read()) print "There are", len(cm['CityObjects']), "CityObjects" # list all ids for id in cm['CityObjects']: print "\t", id
  18. Compression factor == ~7X 29 Compression (v0.6) file CityGML size

    (original) CityGML size (w/o spaces) textures? CityJSON CityJSON compressed compression factor CityGML demo "GeoRes" 4.3MB 4.1MB yes 582KB 524KB 8.0 CityGML v2 demo "Railway" 45MB 34MB yes 4.5MB 4.3MB 8.1 Den Haag "tile 01" 23MB 18MB no, material 3.1MB 2.9MB 6.2 Montréal VM05 56MB 42MB yes 5.7MB 5.4MB 7.8 New York LoD2 (DA13) 590MB 574MB no 110MB 105MB 5.5 Rotterdam Delfshaven 16MB 15MB yes 2.8MB 2.6MB 5.4 Vienna 37MB 36MB no 5.6MB 5.3MB 6.8 5
  19. Fact: 2D real-world data are rarely valid 34 Validation of

    a polygon = a solved problem OGC Simple Features and ISO19107 rules: 1 no self-intersection 2 closed boundaries 3 rings can touch but not overlap 4 no duplicate points 5 no dangling edges 6 connected interior 7 etc p2 p4 p5 p6 p7 p8 p9 p3 p12 p11 p10 p1 exterior boundary interior boundary 8 / 26
  20. Automatic repairin With my colleague John Z of the most

    common err Another fact: 3D datasets are never valid 37
  21. We tested all freely available 3D datasets 39 • No

    CityGML dataset is 100% valid, not even LoD1 • Many simple errors, eg: • repeated vertices • non-planar polygons (most common error!) • Notice that these are often not visible
  22. 3D validation: own tool ‘val3dity’ 37 CityGML datasets from 9

    countries 40 million polygons in 3.6 million buildings (Solids + MultiSurfaces) our software: val3dity 40
  23. Error codes 41 LinearRing Polygon Point MultiSurface CompositeSurface MultiSolid CompositeSolid

    Solid CompositeSolid Solid & MultiSolid CompositeSurface MultiSurface LinearRing level 101 TOO_FEW_POINTS 102 CONSECUTIVE_POINTS_SAME 103 RING_NOT_CLOSED 104 RING_SELF_INTERSECTION Polygon level 201 INTERSECTION_RINGS 202 DUPLICATED_RINGS 203 NON_PLANAR_POLYGON_DISTANCE_PLANE 204 NON_PLANAR_POLYGON_NORMALS_DEVIATION 205 POLYGON_INTERIOR_DISCONNECTED 206 INNER_RING_OUTSIDE 207 INNER_RINGS_NESTED 208 ORIENTATION_RINGS_SAME Shell level 301 TOO_FEW_POLYGONS 302 SHELL_NOT_CLOSED 303 NON_MANIFOLD_CASE 305 MULTIPLE_CONNECTED_COMPONENTS 306 SHELL_SELF_INTERSECTION 307 POLYGON_WRONG_ORIENTATION Solid level 401 INTERSECTION_SHELLS 402 DUPLICATED_SHELLS 403 INNER_SHELL_OUTSIDE 404 SOLID_INTERIOR_DISCONNECTED 405 WRONG_ORIENTATION_SHELL Solid interactions level 501 INTERSECTION_SOLIDS 502 DUPLICATED_SOLIDS 503 DISCONNECTED_SOLIDS these 2 not possible for CompositeSurface
  24. ISO19107 for 3D primitives 42 s1 s2 s3 s4 invalid

    invalid valid valid s9 s10 s11 s12 invalid invalid valid invalid s5 s6 s7 s8 invalid invalid invalid valid
  25. Level of detail Primitive ID(a) Geometric validation Semantics(f) Schema 1xx

    2xx 3xx 4xx Total(b) LOD1 Solid 1 0 0 0 0 0 – 7 2 0 0 0 0 0 – 3 3 0 0 0 0 0 – 3 4 0 0 0 0 0 – 3 5 0 0 0 0 0 – 7 6 0 0 0 0 0 – 7 7 0 0 0 0 0 – 3 8 0 0 0 0 0 – 3 9 0 0 0 0 0 – 7 LOD2 MultiSurface 10 1 4 – – 5 (e) 3 11 0 0 – – 0 0 3 12 2 21 – – 23 45 3 13 10 2 – – 12 4 7 14 0 1 – – 1 12 3 15 0 9 – – 9 2 3 16 4 8 – – 12 1 7 17 5 0 – – 5 5 7 18 0 0 – – 0 4 7 19 0 0 – – 0 1 7 20 0 4 – – 4 6 7 21 0 1 – – 1 3 7 LOD2 Solid 22 0 42 58 0 100 – 3 23(c) – – – – – – 7 24 0 31 1 3 35 – 7 25 4 0 16 2 22 – 3 26(c) – – – – – – 7 27 22 17 50 0 89 – 3 LOD2 MultiSurface and Solid (d) 28 0 42 1 1 44 0 3 29 2 35 54 0 92 4 3 30 0 10 0 1 11 2 3 31 0 0 0 0 0 0 3 LOD3 MultiSurface 32 2 13 – – 15 54 3 33 6 5 – – 11 23 3 34 8 10 – – 19 45 3 35 5 0 – – 5 34 3 36 0 0 – – 0 1 7 LOD4 Solid 37 0 0 3 0 3 68 3 (a) % of invalid actually all between 99.5% and 99.9%
  26. Level of detail Primitive ID(a) Geometric validation Semantics(f) Schema 1xx

    2xx 3xx 4xx Total(b) LOD1 Solid 1 0 0 0 0 0 – 7 2 0 0 0 0 0 – 3 3 0 0 0 0 0 – 3 4 0 0 0 0 0 – 3 5 0 0 0 0 0 – 7 6 0 0 0 0 0 – 7 7 0 0 0 0 0 – 3 8 0 0 0 0 0 – 3 9 0 0 0 0 0 – 7 LOD2 MultiSurface 10 1 4 – – 5 (e) 3 11 0 0 – – 0 0 3 12 2 21 – – 23 45 3 13 10 2 – – 12 4 7 14 0 1 – – 1 12 3 15 0 9 – – 9 2 3 16 4 8 – – 12 1 7 17 5 0 – – 5 5 7 18 0 0 – – 0 4 7 19 0 0 – – 0 1 7 20 0 4 – – 4 6 7 21 0 1 – – 1 3 7 LOD2 Solid 22 0 42 58 0 100 – 3 23(c) – – – – – – 7 24 0 31 1 3 35 – 7 25 4 0 16 2 22 – 3 26(c) – – – – – – 7 27 22 17 50 0 89 – 3 LOD2 MultiSurface and Solid (d) 28 0 42 1 1 44 0 3 29 2 35 54 0 92 4 3 30 0 10 0 1 11 2 3 31 0 0 0 0 0 0 3 LOD3 MultiSurface 32 2 13 – – 15 54 3 33 6 5 – – 11 23 3 34 8 10 – – 19 45 3 35 5 0 – – 5 34 3 36 0 0 – – 0 1 7 LOD4 Solid 37 0 0 3 0 3 68 3 (a) % of invalid rather good, but it’s “easy”
  27. Level of detail Primitive ID(a) Geometric validation Semantics(f) Schema 1xx

    2xx 3xx 4xx Total(b) LOD1 Solid 1 0 0 0 0 0 – 7 2 0 0 0 0 0 – 3 3 0 0 0 0 0 – 3 4 0 0 0 0 0 – 3 5 0 0 0 0 0 – 7 6 0 0 0 0 0 – 7 7 0 0 0 0 0 – 3 8 0 0 0 0 0 – 3 9 0 0 0 0 0 – 7 LOD2 MultiSurface 10 1 4 – – 5 (e) 3 11 0 0 – – 0 0 3 12 2 21 – – 23 45 3 13 10 2 – – 12 4 7 14 0 1 – – 1 12 3 15 0 9 – – 9 2 3 16 4 8 – – 12 1 7 17 5 0 – – 5 5 7 18 0 0 – – 0 4 7 19 0 0 – – 0 1 7 20 0 4 – – 4 6 7 21 0 1 – – 1 3 7 LOD2 Solid 22 0 42 58 0 100 – 3 23(c) – – – – – – 7 24 0 31 1 3 35 – 7 25 4 0 16 2 22 – 3 26(c) – – – – – – 7 27 22 17 50 0 89 – 3 LOD2 MultiSurface and Solid (d) 28 0 42 1 1 44 0 3 29 2 35 54 0 92 4 3 30 0 10 0 1 11 2 3 31 0 0 0 0 0 0 3 LOD3 MultiSurface 32 2 13 – – 15 54 3 33 6 5 – – 11 23 3 34 8 10 – – 19 45 3 35 5 0 – – 5 34 3 36 0 0 – – 0 1 7 LOD4 Solid 37 0 0 3 0 3 68 3 (a) % of invalid some datasets couldn’t be read high % of invalid
  28. We tried voxelisation: so-so results 54 voxelisation Voxelization CityGML input

    Preprocessing Approach 1: Marching Cubes Approach 2: Dual Contouring CityGML output parser writer
  29. Results one neighbourhood Rotterdam 55 1207 buildings 116 valid (10%

    = ) after our automatic repair: 1159 valid (96% = )