-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Chore/352 osdamage analysis of the damage module returns a tuple (#441)
## Issue addressed Solves #<issue number> ## Code of conduct - [x] I HAVE NOT added sensitive or compromised (test) data to the repository. - [x] I HAVE NOT added vulnerabilities to the repository. - [x] I HAVE discussed my solution with (other) members of the RA2CE team. ## What has been done? Explain how you addressed the resolution of the related issue, what choices you made and why. ### Checklist - [ ] Code is formatted using our custom `black` and `isort` definitions. - [x] Tests are either added or updated. - [x] Branch is up to date with `master`. - [x] Updated documentation if needed. ## Additional Notes (optional) Add any additional notes or information that may be helpful.
- Loading branch information
Showing
29 changed files
with
486 additions
and
70 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
[project] | ||
name = beira | ||
|
||
[analysis1] | ||
name = OSdamage_direct_damage_event | ||
analysis = direct | ||
event_type = event | ||
damage_curve = OSD | ||
save_csv = True | ||
save_gpkg = True |
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
[project] | ||
name = beira | ||
|
||
[network] | ||
directed = False | ||
source = OSM download | ||
primary_file = None | ||
diversion_file = None | ||
file_id = rfid_c | ||
polygon = region_polygon.geojson | ||
network_type = drive | ||
road_types = motorway,motorway_link,primary,primary_link,secondary,secondary_link,tertiary,tertiary_link,residential | ||
save_gpkg = True | ||
|
||
[origins_destinations] | ||
origins = None | ||
destinations = None | ||
origins_names = None | ||
destinations_names = None | ||
id_name_origin_destination = None | ||
origin_count = None | ||
origin_out_fraction = None | ||
category = None | ||
|
||
[hazard] | ||
hazard_map = max_flood_depth.tif | ||
hazard_id = None | ||
hazard_field_name = waterdepth | ||
aggregate_wl = mean | ||
hazard_crs = EPSG:32736 | ||
|
||
[cleanup] | ||
snapping_threshold = None | ||
segmentation_length = None | ||
merge_lines = True | ||
merge_on_id = False | ||
cut_at_intersections = False |
Binary file added
BIN
+5.59 MB
examples/data/direct_analysis_huizinga/static/hazard/max_flood_depth.tif
Binary file not shown.
12 changes: 12 additions & 0 deletions
12
examples/data/direct_analysis_huizinga/static/hazard/max_flood_depth.tif.aux.xml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
<PAMDataset> | ||
<PAMRasterBand band="1"> | ||
<Metadata> | ||
<MDI key="STATISTICS_APPROXIMATE">YES</MDI> | ||
<MDI key="STATISTICS_MAXIMUM">15.197619438171</MDI> | ||
<MDI key="STATISTICS_MEAN">1.3522161249402</MDI> | ||
<MDI key="STATISTICS_MINIMUM">0.050009727478027</MDI> | ||
<MDI key="STATISTICS_STDDEV">2.4887893417283</MDI> | ||
<MDI key="STATISTICS_VALID_PERCENT">24.02</MDI> | ||
</Metadata> | ||
</PAMRasterBand> | ||
</PAMDataset> |
1 change: 1 addition & 0 deletions
1
examples/data/direct_analysis_huizinga/static/network/region_polygon.geojson
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
{"type":"FeatureCollection","features":[{"type":"Feature","properties":{},"geometry":{"coordinates":[[[34.83813584786725,-19.849253564071716],[34.85731866455188,-19.850207061044827],[34.87923074377409,-19.8538743037071],[34.89685398186816,-19.847713287630185],[34.908004968802516,-19.84155203240664],[34.85349769700147,-19.814263600532954],[34.83361306994894,-19.81492385983684],[34.82877837631224,-19.837591099222138],[34.83813584786725,-19.849253564071716]]],"type":"Polygon"}}]} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
[project] | ||
name = beira | ||
|
||
[analysis1] | ||
name = Huizinga_direct_damage_event | ||
analysis = direct | ||
event_type = event | ||
damage_curve = MAN | ||
save_csv = True | ||
save_gpkg = True |
8 changes: 8 additions & 0 deletions
8
examples/data/direct_analysis_manual/input_analysis_data/hazard_severity_damage fraction.csv
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
depth damage | ||
cm % of total construction costs | ||
0 0 | ||
100 0.1 | ||
200 0.2 | ||
400 0.4 | ||
800 0.8 | ||
12000 1 |
8 changes: 8 additions & 0 deletions
8
examples/data/direct_analysis_manual/input_analysis_data/max_damage_road_types.csv
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
Road_type \ lanes lanes | ||
unit euro/m | ||
tertiary_link 100 | ||
tertiary 100 | ||
secondary_link 10 | ||
secondary 10 | ||
residential 1000 | ||
['tertiary', 'residential'] 500 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
[project] | ||
name = beira | ||
|
||
[network] | ||
directed = False | ||
source = OSM download | ||
primary_file = None | ||
diversion_file = None | ||
file_id = rfid_c | ||
polygon = region_polygon.geojson | ||
network_type = drive | ||
road_types = motorway,motorway_link,primary,primary_link,secondary,secondary_link,tertiary,tertiary_link,residential | ||
save_gpkg = True | ||
|
||
[origins_destinations] | ||
origins = None | ||
destinations = None | ||
origins_names = None | ||
destinations_names = None | ||
id_name_origin_destination = None | ||
origin_count = None | ||
origin_out_fraction = None | ||
category = None | ||
|
||
[hazard] | ||
hazard_map = max_flood_depth.tif | ||
hazard_id = None | ||
hazard_field_name = waterdepth | ||
aggregate_wl = mean | ||
hazard_crs = EPSG:32736 | ||
|
||
[cleanup] | ||
snapping_threshold = None | ||
segmentation_length = None | ||
merge_lines = True | ||
merge_on_id = False | ||
cut_at_intersections = False |
Binary file added
BIN
+5.59 MB
examples/data/direct_analysis_manual/static/hazard/max_flood_depth.tif
Binary file not shown.
12 changes: 12 additions & 0 deletions
12
examples/data/direct_analysis_manual/static/hazard/max_flood_depth.tif.aux.xml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
<PAMDataset> | ||
<PAMRasterBand band="1"> | ||
<Metadata> | ||
<MDI key="STATISTICS_APPROXIMATE">YES</MDI> | ||
<MDI key="STATISTICS_MAXIMUM">15.197619438171</MDI> | ||
<MDI key="STATISTICS_MEAN">1.3522161249402</MDI> | ||
<MDI key="STATISTICS_MINIMUM">0.050009727478027</MDI> | ||
<MDI key="STATISTICS_STDDEV">2.4887893417283</MDI> | ||
<MDI key="STATISTICS_VALID_PERCENT">24.02</MDI> | ||
</Metadata> | ||
</PAMRasterBand> | ||
</PAMDataset> |
1 change: 1 addition & 0 deletions
1
examples/data/direct_analysis_manual/static/network/region_polygon.geojson
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
{"type":"FeatureCollection","features":[{"type":"Feature","properties":{},"geometry":{"coordinates":[[[34.83813584786725,-19.849253564071716],[34.85731866455188,-19.850207061044827],[34.87923074377409,-19.8538743037071],[34.89685398186816,-19.847713287630185],[34.908004968802516,-19.84155203240664],[34.85349769700147,-19.814263600532954],[34.83361306994894,-19.81492385983684],[34.82877837631224,-19.837591099222138],[34.83813584786725,-19.849253564071716]]],"type":"Polygon"}}]} |
Oops, something went wrong.