diff --git a/Level0/Unknown.obj b/Level0/Unknown.obj deleted file mode 100644 index d456ea9..0000000 --- a/Level0/Unknown.obj +++ /dev/null @@ -1,28 +0,0 @@ -# cerc-hub export -# building UUID_d281adfc-4901-0f52-540b-4cc1a9325f82 -g UUID_d281adfc-4901-0f52-540b-4cc1a9325f82 -s off -# surface 9a1623ed-cff3-46e3-b216-6b5bc34caf68 -v 0.0 5.0 6.517691453623996 -v 0.0 10.0 3.630940107675997 -v 0.0 10.0 0.0 -v 0.0 0.0 0.0 -v 0.0 0.0 3.630940107675997 -f 1 2 3 4 5 -# surface 6ac94b17-cc97-4b67-b79a-402cd0325917 -v 12.0 0.0 3.630940107675997 -v 12.0 0.0 0.0 -f 6 5 4 7 -# surface 429f5b6f-2818-4882-b8f4-f6983e707d86 -v 12.0 5.0 6.517691453623996 -v 12.0 10.0 0.0 -v 12.0 10.0 3.630940107675997 -f 8 6 7 9 10 -# surface e934907a-d808-45bc-bc8f-5ad17b0834f1 -f 1 8 10 2 -# surface 0e80bc1f-0b35-4917-ba25-98139457582c -f 2 10 9 3 -# surface d8ef7be5-3144-4947-b054-c9e39f548ad1 -f 6 8 1 5 -# surface f30c3309-acc2-46a8-aa15-e255c345d77c -f 7 4 3 9 diff --git a/README.md b/README.md index e395424..d62a14f 100644 --- a/README.md +++ b/README.md @@ -1,3 +1,3 @@ # Documentation -This repository contains the CERC development documentation and it's intended to be linked from different repositories and sites +This repository contains the CERC development documentation, and it's intended to be linked from different repositories and sites diff --git a/Level/FZK-Haus-LoD2-KIT-IAI-KHH-B36-V1.gml b/support_material/tutorial_0/FZK-Haus-LoD2-KIT-IAI-KHH-B36-V1.gml similarity index 98% rename from Level/FZK-Haus-LoD2-KIT-IAI-KHH-B36-V1.gml rename to support_material/tutorial_0/FZK-Haus-LoD2-KIT-IAI-KHH-B36-V1.gml index baf0544..04c9be7 100644 --- a/Level/FZK-Haus-LoD2-KIT-IAI-KHH-B36-V1.gml +++ b/support_material/tutorial_0/FZK-Haus-LoD2-KIT-IAI-KHH-B36-V1.gml @@ -1,240 +1,240 @@ - - - AC14-FZK-Haus - - - 457842 5439083 111.8 - 457854 5439093 118.317669 - - - - - FZK-Haus (Forschungszentrum Karlsruhe, now KIT), created by Karl-Heinz - Haefele - AC14-FZK-Haus - 2017-01-23 - entirelyAboveTerrain - - 120.00 - - - New Building - - - NO - - 1000 - 1000 - 1000 - 2020 - 1030 - 6.52 - 2 - 0 - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - Outer Wall 1 (West) - - - - - - - 457842 5439088 118.317691453624 - 457842 5439093 115.430940107676 - 457842 5439093 111.8 - 457842 5439083 111.8 - 457842 5439083 115.430940107676 - 457842 5439088 118.317691453624 - - - - - - - - - - - Outer Wall 2 (South) - - - - - - - 457854 5439083 115.430940107676 - 457842 5439083 115.430940107676 - 457842 5439083 111.8 - 457854 5439083 111.8 - 457854 5439083 115.430940107676 - - - - - - - - - - - Outer Wall 3 (East) - - - - - - - 457854 5439088 118.317691453624 - 457854 5439083 115.430940107676 - 457854 5439083 111.8 - 457854 5439093 111.8 - 457854 5439093 115.430940107676 - 457854 5439088 118.317691453624 - - - - - - - - - - - Roof 1 (North) - - - - - - - 457842 5439088 118.317691453624 - 457854 5439088 118.317691453624 - 457854 5439093 115.430940107676 - 457842 5439093 115.430940107676 - 457842 5439088 118.317691453624 - - - - - - - - - - - Outer Wall 4 (North) - - - - - - - 457842 5439093 115.430940107676 - 457854 5439093 115.430940107676 - 457854 5439093 111.8 - 457842 5439093 111.8 - 457842 5439093 115.430940107676 - - - - - - - - - - - Roof 2 (South) - - - - - - - 457854 5439083 115.430940107676 - 457854 5439088 118.317691453624 - 457842 5439088 118.317691453624 - 457842 5439083 115.430940107676 - 457854 5439083 115.430940107676 - - - - - - - - - - - Bodenplatte - Base Surface - - - - - - - 457854 5439083 111.8 - 457842 5439083 111.8 - 457842 5439093 111.8 - 457854 5439093 111.8 - 457854 5439083 111.8 - - - - - - - - - - - - - - Eggenstein-Leopoldshafen - - 4711 - Spöcker Straße - - - 76344 - - - - - - - - + + + AC14-FZK-Haus + + + 457842 5439083 111.8 + 457854 5439093 118.317669 + + + + + FZK-Haus (Forschungszentrum Karlsruhe, now KIT), created by Karl-Heinz + Haefele + AC14-FZK-Haus + 2017-01-23 + entirelyAboveTerrain + + 120.00 + + + New Building + + + NO + + 1000 + 1000 + 1000 + 2020 + 1030 + 6.52 + 2 + 0 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Outer Wall 1 (West) + + + + + + + 457842 5439088 118.317691453624 + 457842 5439093 115.430940107676 + 457842 5439093 111.8 + 457842 5439083 111.8 + 457842 5439083 115.430940107676 + 457842 5439088 118.317691453624 + + + + + + + + + + + Outer Wall 2 (South) + + + + + + + 457854 5439083 115.430940107676 + 457842 5439083 115.430940107676 + 457842 5439083 111.8 + 457854 5439083 111.8 + 457854 5439083 115.430940107676 + + + + + + + + + + + Outer Wall 3 (East) + + + + + + + 457854 5439088 118.317691453624 + 457854 5439083 115.430940107676 + 457854 5439083 111.8 + 457854 5439093 111.8 + 457854 5439093 115.430940107676 + 457854 5439088 118.317691453624 + + + + + + + + + + + Roof 1 (North) + + + + + + + 457842 5439088 118.317691453624 + 457854 5439088 118.317691453624 + 457854 5439093 115.430940107676 + 457842 5439093 115.430940107676 + 457842 5439088 118.317691453624 + + + + + + + + + + + Outer Wall 4 (North) + + + + + + + 457842 5439093 115.430940107676 + 457854 5439093 115.430940107676 + 457854 5439093 111.8 + 457842 5439093 111.8 + 457842 5439093 115.430940107676 + + + + + + + + + + + Roof 2 (South) + + + + + + + 457854 5439083 115.430940107676 + 457854 5439088 118.317691453624 + 457842 5439088 118.317691453624 + 457842 5439083 115.430940107676 + 457854 5439083 115.430940107676 + + + + + + + + + + + Bodenplatte + Base Surface + + + + + + + 457854 5439083 111.8 + 457842 5439083 111.8 + 457842 5439093 111.8 + 457854 5439093 111.8 + 457854 5439083 111.8 + + + + + + + + + + + + + + Eggenstein-Leopoldshafen + + 4711 + Spöcker Straße + + + 76344 + + + + + + + + \ No newline at end of file diff --git a/Level0/main.py b/support_material/tutorial_0/main_level_0.py similarity index 65% rename from Level0/main.py rename to support_material/tutorial_0/main_level_0.py index 9c8a674..47ea530 100644 --- a/Level0/main.py +++ b/support_material/tutorial_0/main_level_0.py @@ -1,13 +1,15 @@ -from hub.imports.geometry_factory import GeometryFactory -from hub.exports.exports_factory import ExportsFactory - - -gml_file = './FZK-Haus-LoD2-KIT-IAI-KHH-B36-V1.gml' -city = GeometryFactory('citygml', gml_file).city - -for building in city.buildings: - print(building.name) - print(building.volume) - print(building.floor_area) - -ExportsFactory('obj', city, './').export() +from pathlib import Path +from hub.imports.geometry_factory import GeometryFactory +from hub.exports.exports_factory import ExportsFactory + + +gml_file = 'FZK-Haus-LoD2-KIT-IAI-KHH-B36-V1.gml' +city = GeometryFactory('citygml', gml_file).city +path = Path(__file__).parent + +for building in city.buildings: + print(building.name) + print(building.volume) + print(building.floor_area) + +ExportsFactory('obj', city, path).export() diff --git a/Level0/FZK-Haus-LoD2-KIT-IAI-KHH-B36-V1.gml b/support_material/tutorial_1/FZK-Haus-LoD2-KIT-IAI-KHH-B36-V1.gml similarity index 98% rename from Level0/FZK-Haus-LoD2-KIT-IAI-KHH-B36-V1.gml rename to support_material/tutorial_1/FZK-Haus-LoD2-KIT-IAI-KHH-B36-V1.gml index baf0544..04c9be7 100644 --- a/Level0/FZK-Haus-LoD2-KIT-IAI-KHH-B36-V1.gml +++ b/support_material/tutorial_1/FZK-Haus-LoD2-KIT-IAI-KHH-B36-V1.gml @@ -1,240 +1,240 @@ - - - AC14-FZK-Haus - - - 457842 5439083 111.8 - 457854 5439093 118.317669 - - - - - FZK-Haus (Forschungszentrum Karlsruhe, now KIT), created by Karl-Heinz - Haefele - AC14-FZK-Haus - 2017-01-23 - entirelyAboveTerrain - - 120.00 - - - New Building - - - NO - - 1000 - 1000 - 1000 - 2020 - 1030 - 6.52 - 2 - 0 - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - Outer Wall 1 (West) - - - - - - - 457842 5439088 118.317691453624 - 457842 5439093 115.430940107676 - 457842 5439093 111.8 - 457842 5439083 111.8 - 457842 5439083 115.430940107676 - 457842 5439088 118.317691453624 - - - - - - - - - - - Outer Wall 2 (South) - - - - - - - 457854 5439083 115.430940107676 - 457842 5439083 115.430940107676 - 457842 5439083 111.8 - 457854 5439083 111.8 - 457854 5439083 115.430940107676 - - - - - - - - - - - Outer Wall 3 (East) - - - - - - - 457854 5439088 118.317691453624 - 457854 5439083 115.430940107676 - 457854 5439083 111.8 - 457854 5439093 111.8 - 457854 5439093 115.430940107676 - 457854 5439088 118.317691453624 - - - - - - - - - - - Roof 1 (North) - - - - - - - 457842 5439088 118.317691453624 - 457854 5439088 118.317691453624 - 457854 5439093 115.430940107676 - 457842 5439093 115.430940107676 - 457842 5439088 118.317691453624 - - - - - - - - - - - Outer Wall 4 (North) - - - - - - - 457842 5439093 115.430940107676 - 457854 5439093 115.430940107676 - 457854 5439093 111.8 - 457842 5439093 111.8 - 457842 5439093 115.430940107676 - - - - - - - - - - - Roof 2 (South) - - - - - - - 457854 5439083 115.430940107676 - 457854 5439088 118.317691453624 - 457842 5439088 118.317691453624 - 457842 5439083 115.430940107676 - 457854 5439083 115.430940107676 - - - - - - - - - - - Bodenplatte - Base Surface - - - - - - - 457854 5439083 111.8 - 457842 5439083 111.8 - 457842 5439093 111.8 - 457854 5439093 111.8 - 457854 5439083 111.8 - - - - - - - - - - - - - - Eggenstein-Leopoldshafen - - 4711 - Spöcker Straße - - - 76344 - - - - - - - - + + + AC14-FZK-Haus + + + 457842 5439083 111.8 + 457854 5439093 118.317669 + + + + + FZK-Haus (Forschungszentrum Karlsruhe, now KIT), created by Karl-Heinz + Haefele + AC14-FZK-Haus + 2017-01-23 + entirelyAboveTerrain + + 120.00 + + + New Building + + + NO + + 1000 + 1000 + 1000 + 2020 + 1030 + 6.52 + 2 + 0 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Outer Wall 1 (West) + + + + + + + 457842 5439088 118.317691453624 + 457842 5439093 115.430940107676 + 457842 5439093 111.8 + 457842 5439083 111.8 + 457842 5439083 115.430940107676 + 457842 5439088 118.317691453624 + + + + + + + + + + + Outer Wall 2 (South) + + + + + + + 457854 5439083 115.430940107676 + 457842 5439083 115.430940107676 + 457842 5439083 111.8 + 457854 5439083 111.8 + 457854 5439083 115.430940107676 + + + + + + + + + + + Outer Wall 3 (East) + + + + + + + 457854 5439088 118.317691453624 + 457854 5439083 115.430940107676 + 457854 5439083 111.8 + 457854 5439093 111.8 + 457854 5439093 115.430940107676 + 457854 5439088 118.317691453624 + + + + + + + + + + + Roof 1 (North) + + + + + + + 457842 5439088 118.317691453624 + 457854 5439088 118.317691453624 + 457854 5439093 115.430940107676 + 457842 5439093 115.430940107676 + 457842 5439088 118.317691453624 + + + + + + + + + + + Outer Wall 4 (North) + + + + + + + 457842 5439093 115.430940107676 + 457854 5439093 115.430940107676 + 457854 5439093 111.8 + 457842 5439093 111.8 + 457842 5439093 115.430940107676 + + + + + + + + + + + Roof 2 (South) + + + + + + + 457854 5439083 115.430940107676 + 457854 5439088 118.317691453624 + 457842 5439088 118.317691453624 + 457842 5439083 115.430940107676 + 457854 5439083 115.430940107676 + + + + + + + + + + + Bodenplatte + Base Surface + + + + + + + 457854 5439083 111.8 + 457842 5439083 111.8 + 457842 5439093 111.8 + 457854 5439093 111.8 + 457854 5439083 111.8 + + + + + + + + + + + + + + Eggenstein-Leopoldshafen + + 4711 + Spöcker Straße + + + 76344 + + + + + + + + \ No newline at end of file diff --git a/Level/main_level1.py b/support_material/tutorial_1/main_level_1.py similarity index 91% rename from Level/main_level1.py rename to support_material/tutorial_1/main_level_1.py index a5b76c3..91c669c 100644 --- a/Level/main_level1.py +++ b/support_material/tutorial_1/main_level_1.py @@ -1,33 +1,33 @@ -from hub.imports.geometry_factory import GeometryFactory -from hub.imports.construction_factory import ConstructionFactory -from hub.helpers.dictionaries import Dictionaries -from hub.exports.exports_factory import ExportsFactory - - -# Level0: -gml_file = './FZK-Haus-LoD2-KIT-IAI-KHH-B36-V1.gml' -city = GeometryFactory('citygml', gml_file, function_to_hub=Dictionaries().montreal_function_to_hub_function).city - -for building in city.buildings: - print(building.name) - print(building.volume) - print(building.floor_area) - - -# Level1: -city1 = city.copy - -for building in city1.buildings: - print ("Construction year of building in city1 is: ", building.year_of_construction) - print ("Building's function in city1 is: " , building.function) - -ConstructionFactory('nrcan',city1).enrich() - -for building in city1.buildings: - for internal_zone in building.internal_zones: - for thermal_zone in internal_zone.thermal_zones: - for thermal_boundary in thermal_zone.thermal_boundaries: - for layer in thermal_boundary.layers: - print(thermal_boundary.internal_surface.type) - print(layer.material.name) - +from hub.imports.geometry_factory import GeometryFactory +from hub.imports.construction_factory import ConstructionFactory +from hub.helpers.dictionaries import Dictionaries +from hub.exports.exports_factory import ExportsFactory + + +# tutorial_0: +gml_file = 'FZK-Haus-LoD2-KIT-IAI-KHH-B36-V1.gml' +city = GeometryFactory('citygml', gml_file, function_to_hub=Dictionaries().montreal_function_to_hub_function).city + +for building in city.buildings: + print(building.name) + print(building.volume) + print(building.floor_area) + + +# Level1: +city1 = city.copy + +for building in city1.buildings: + print ("Construction year of building in city1 is: ", building.year_of_construction) + print ("Building's function in city1 is: " , building.function) + +ConstructionFactory('nrcan',city1).enrich() + +for building in city1.buildings: + for internal_zone in building.internal_zones: + for thermal_zone in internal_zone.thermal_zones: + for thermal_boundary in thermal_zone.thermal_boundaries: + for layer in thermal_boundary.layers: + print(thermal_boundary.internal_surface.type) + print(layer.material.name) +