gem / oq-irmt-qgis

QGIS plugin to drive the OpenQuake Engine, to develop Social Vulnerability and Integrated Risk composite indices, and to predict building recovery times following an earthquake
https://plugins.qgis.org/plugins/svir/
8 stars 3 forks source link

Bug when loading losses layers #729

Open CatalinaYepes opened 4 years ago

CatalinaYepes commented 4 years ago

When trying to load the Average Asset Losses from the Scenario Risk Demo, the following error appears

2020-04-20T16:36:01 WARNING Traceback (most recent call last): File "/Users/cyepes/Library/Application Support/QGIS/QGIS3/profiles/default/python/plugins/svir/dialogs/load_output_as_layer_dialog.py", line 875, in accept self.load_from_npz() File "/Users/cyepes/Library/Application Support/QGIS/QGIS3/profiles/default/python/plugins/svir/dialogs/load_losses_by_asset_as_layer_dialog.py", line 186, in load_from_npz loss_type=loss_type) File "/Users/cyepes/Library/Application Support/QGIS/QGIS3/profiles/default/python/plugins/svir/dialogs/load_output_as_layer_dialog.py", line 492, in build_layer row_wkt_geom_types=row_wkt_geom_types) File "/Users/cyepes/Library/Application Support/QGIS/QGIS3/profiles/default/python/plugins/svir/dialogs/load_losses_by_asset_as_layer_dialog.py", line 147, in read_npz_into_layer self.npz_file, rlz_or_stat, loss_type, taxonomy) File "/Users/cyepes/Library/Application Support/QGIS/QGIS3/profiles/default/python/plugins/svir/dialogs/load_losses_by_asset_as_layer_dialog.py", line 201, in group_by_site loss_by_site[rec['lon'], rec['lat']] += rec[loss_type] ValueError: no field of name b'structural'

ptormene commented 4 years ago

On my machine I can not reproduce this error. I will check on MacOS, to see if the behavior is different.

ptormene commented 1 month ago

@CatalinaYepes is this still occurring on your MacOS machine? Otherwise we can close this issue.