def as_dict(): """Return metadata as a dictionary. This is a static method. You can use it to get the metadata in dictionary format for an impact function. :returns: A dictionary representing all the metadata for the concrete impact function. :rtype: dict """ dict_meta = { 'id': 'FloodPolygonBuildingFunction', 'name': tr('Polygon flood on buildings'), 'impact': tr('Be flooded'), 'title': tr('Be flooded'), 'function_type': 'qgis2.0', 'author': 'Dmitry Kolesov', 'date_implemented': 'N/A', 'overview': tr('N/A'), 'detailed_description': tr('N/A'), 'hazard_input': '', 'exposure_input': '', 'output': '', 'actions': '', 'limitations': [], 'citations': [], 'layer_requirements': { 'hazard': { 'layer_mode': layer_mode_classified, 'layer_geometries': [layer_geometry_polygon], 'hazard_categories': [ hazard_category_single_event, hazard_category_multiple_event ], 'hazard_types': [hazard_flood], 'continuous_hazard_units': [], 'vector_hazard_classifications': [ flood_vector_hazard_classes], 'raster_hazard_classifications': [], 'additional_keywords': [] }, 'exposure': { 'layer_mode': layer_mode_classified, 'layer_geometries': [layer_geometry_polygon], 'exposure_types': [exposure_structure], 'exposure_units': [], 'exposure_class_fields': [structure_class_field], 'additional_keywords': [] } }, 'parameters': OrderedDict([ ('postprocessors', OrderedDict([ ('BuildingType', building_type_postprocessor()) ])) ]) } return dict_meta
def as_dict(): """Return metadata as a dictionary. This is a static method. You can use it to get the metadata in dictionary format for an impact function. :returns: A dictionary representing all the metadata for the concrete impact function. :rtype: dict """ dict_meta = { 'id': 'FloodPolygonBuildingFunction', 'name': tr('Polygon flood on buildings'), 'impact': tr('Be flooded'), 'title': tr('Be flooded'), 'function_type': 'qgis2.0', 'author': 'Dmitry Kolesov', 'date_implemented': 'N/A', 'overview': tr('N/A'), 'detailed_description': tr('N/A'), 'hazard_input': '', 'exposure_input': '', 'output': '', 'actions': '', 'limitations': [], 'citations': [], 'categories': { 'hazard': { 'definition': hazard_definition, 'subcategories': [hazard_flood, hazard_tsunami], 'units': [unit_wetdry], 'layer_constraints': [layer_vector_polygon] }, 'exposure': { 'definition': exposure_definition, 'subcategories': [exposure_structure], 'units': [unit_building_type_type], 'layer_constraints': [layer_vector_polygon] } }, 'parameters': OrderedDict([ # This field of the exposure layer contains # information about building types ('building_type_field', 'TYPE'), # This field of the hazard layer contains information # about inundated areas ('affected_field', 'FLOODPRONE'), # This value in 'affected_field' of the hazard layer # marks the areas as inundated ('affected_value', 'YES'), ('postprocessors', OrderedDict([ ('BuildingType', building_type_postprocessor()) ])) ]) } return dict_meta
def as_dict(): """Return metadata as a dictionary. This is a static method. You can use it to get the metadata in dictionary format for an impact function. :returns: A dictionary representing all the metadata for the concrete impact function. :rtype: dict """ dict_meta = { 'id': 'VolcanoPointBuildingFunction', 'name': tr('Point volcano on buildings'), 'impact': tr('Be affected'), 'title': tr('Be affected'), 'function_type': 'old-style', 'author': 'AIFDR', 'date_implemented': 'N/A', 'overview': tr('To assess the impacts of volcano points on buildings.'), 'detailed_description': '', 'hazard_input': tr('The hazard layer must be a point layer. ' 'This point will be buffered with the radii specified in ' 'the parameters as the hazard zone. If you want to see ' 'the name of the volcano in the result, you need to ' 'specify the volcano name attribute in the Impact Function ' 'option.'), 'exposure_input': tr('Vector polygon layer extracted from OSM where each ' 'polygon represents the footprint of a building.'), 'output': tr('Vector layer contains Map of building exposed to ' 'volcanic hazard zones for each radius.'), 'actions': tr('Provide details about how many building would likely be ' 'affected by each hazard zones.'), 'limitations': [], 'citations': [], 'layer_requirements': { 'hazard': { 'layer_mode': layer_mode_classified, 'layer_geometries': [layer_geometry_point], 'hazard_categories': [ hazard_category_multiple_event, hazard_category_single_event ], 'hazard_types': [hazard_volcano], 'continuous_hazard_units': [], 'vector_hazard_classifications': [], 'raster_hazard_classifications': [], 'additional_keywords': [volcano_name_field] }, 'exposure': { 'layer_mode': layer_mode_classified, 'layer_geometries': [layer_geometry_polygon, layer_geometry_point], 'exposure_types': [exposure_structure], 'exposure_units': [], 'exposure_class_fields': [structure_class_field], 'additional_keywords': [] } }, 'parameters': OrderedDict([ # The list of radii in km for volcano point hazard ('distances', distance()), ('postprocessors', OrderedDict([('BuildingType', building_type_postprocessor()) ])) ]) } return dict_meta
def as_dict(): """Return metadata as a dictionary. This is a static method. You can use it to get the metadata in dictionary format for an impact function. :returns: A dictionary representing all the metadata for the concrete impact function. :rtype: dict """ dict_meta = { 'id': 'VolcanoPointBuildingFunction', 'name': tr('Point volcano on buildings'), 'impact': tr('Be affected'), 'title': tr('Be affected'), 'function_type': 'old-style', 'author': 'AIFDR', 'date_implemented': 'N/A', 'overview': tr( 'To assess the impacts of volcano points on buildings.'), 'detailed_description': '', 'hazard_input': tr( 'The hazard layer must be a point layer. ' 'This point will be buffered with the radii specified in ' 'the parameters as the hazard zone. If you want to see ' 'the name of the volcano in the result, you need to ' 'specify the volcano name attribute in the Impact Function ' 'option.'), 'exposure_input': tr( 'Vector polygon layer extracted from OSM where each ' 'polygon represents the footprint of a building.'), 'output': tr( 'Vector layer contains Map of building exposed to ' 'volcanic hazard zones for each radius.'), 'actions': tr( 'Provide details about how many building would likely be ' 'affected by each hazard zones.'), 'limitations': [], 'citations': [], 'categories': { 'hazard': { 'definition': hazard_definition, 'subcategories': [hazard_volcano], 'units': [unit_volcano_categorical], 'layer_constraints': [ layer_vector_point ] }, 'exposure': { 'definition': exposure_definition, 'subcategories': [exposure_structure], 'units': [ unit_building_type_type, unit_building_generic], 'layer_constraints': [ layer_vector_polygon, layer_vector_point] } }, 'parameters': OrderedDict([ # The list of radii in km for volcano point hazard ('distances [km]', [3, 5, 10]), # The attribute for name of the volcano in hazard layer ('volcano name attribute', 'NAME'), ('postprocessors', OrderedDict([ ('BuildingType', building_type_postprocessor())])) ]) } return dict_meta
def as_dict(): """Return metadata as a dictionary. This is a static method. You can use it to get the metadata in dictionary format for an impact function. :returns: A dictionary representing all the metadata for the concrete impact function. :rtype: dict """ dict_meta = { 'id': 'ClassifiedPolygonHazardBuildingFunction', 'name': tr('Classified polygon hazard on buildings'), 'impact': tr('Be affected'), 'title': tr('Be affected'), 'function_type': 'qgis2.0', 'author': 'Akbar Gumbira ([email protected])', 'date_implemented': '17/04/2015', 'overview': tr('To assess the impact of each hazard zone on buildings.'), 'detailed_description': '', 'hazard_input': tr('The hazard layer must be a polygon layer. This layer ' 'must have an attribute representing the hazard ' 'zone that can be specified in the impact function options.'), 'exposure_input': tr('Vector polygon layer extracted from OSM where each ' 'polygon represents the footprint of a building.'), 'output': tr('A vector layer of buildings with each tagged according to ' 'the hazard zone in which it falls.'), 'actions': tr('Provide details about how many buildings fall within ' 'each hazard zone.'), 'limitations': [], 'citations': [{ 'text': None, 'link': None }], 'legend_title': tr('Building count'), 'legend_units': tr('(building)'), 'legend_notes': tr('Thousand separator is represented by %s' % get_thousand_separator()), 'layer_requirements': { 'hazard': { 'layer_mode': layer_mode_classified, 'layer_geometries': [layer_geometry_polygon], 'hazard_categories': [ hazard_category_multiple_event, hazard_category_single_event ], 'hazard_types': hazard_all, 'continuous_hazard_units': [], 'vector_hazard_classifications': [generic_vector_hazard_classes], 'raster_hazard_classifications': [], 'additional_keywords': [] }, 'exposure': { 'layer_mode': layer_mode_classified, 'layer_geometries': [layer_geometry_point, layer_geometry_polygon], 'exposure_types': [exposure_structure], 'exposure_units': [], 'exposure_class_fields': [structure_class_field], 'additional_keywords': [] } }, 'parameters': OrderedDict([('postprocessors', OrderedDict([('BuildingType', building_type_postprocessor())]))]) } return dict_meta
def as_dict(): """Return metadata as a dictionary. This is a static method. You can use it to get the metadata in dictionary format for an impact function. :returns: A dictionary representing all the metadata for the concrete impact function. :rtype: dict """ dict_meta = { 'id': 'ClassifiedRasterHazardBuildingFunction', 'name': tr('Classified raster hazard on buildings'), 'impact': tr('Be impacted'), 'title': tr('Be impacted in each hazard class'), 'function_type': 'old-style', 'author': 'Dianne Bencito', 'date_implemented': 'N/A', 'overview': tr( 'To assess the impacts of a classified hazard in raster ' 'format on a buildings vector layer.'), 'detailed_description': tr( 'This function will treat the values in the hazard raster ' 'layer as classes representing low, medium and high ' 'impact. You need to ensure that the keywords for the hazard ' 'layer have been set appropriately to define these classes.' 'The number of buildings that will be impacted will be ' 'calculated for each class. The report will show the total ' 'number of buildings that will be affected for each ' 'hazard class.'), 'hazard_input': tr( 'A hazard raster layer where each cell represents the ' 'class of the hazard. There should be 3 classes: e.g. ' '1, 2, and 3.'), 'exposure_input': tr( 'A vector polygon layer which can be extracted from OSM ' 'where each polygon represents the footprint of a ' 'building.'), 'output': tr( 'The impact layer will contain all structures that were ' 'exposed to the highest class (3) and a summary table ' 'containing the number of structures in each class.'), 'actions': tr( 'Provide details about the number of buildings that are ' 'within each hazard class.'), 'limitations': [tr('The number of classes is three.')], 'citations': [], 'legend_notes': '', 'map_title': tr('Buildings affected'), 'legend_units': tr('(Low, Medium, High)'), 'legend_title': tr('Structure inundated status'), 'layer_name': tr('Estimated buildings affected'), 'layer_requirements': { 'hazard': { 'layer_mode': layer_mode_classified, 'layer_geometries': [layer_geometry_raster], 'hazard_categories': [ hazard_category_single_event, hazard_category_multiple_event ], 'hazard_types': hazard_all, 'continuous_hazard_units': [], 'vector_hazard_classifications': [], 'raster_hazard_classifications': [ generic_raster_hazard_classes ], 'additional_keywords': [] }, 'exposure': { 'layer_mode': layer_mode_classified, 'layer_geometries': [ layer_geometry_point, layer_geometry_polygon ], 'exposure_types': [exposure_structure], 'exposure_units': [], 'exposure_class_fields': [structure_class_field], 'additional_keywords': [] } }, # parameters 'parameters': OrderedDict([ ('Categorical hazards', categorical_hazards()), ('postprocessors', OrderedDict([ ('BuildingType', building_type_postprocessor()) ])) ]) } return dict_meta
def as_dict(): """Return metadata as a dictionary. This is a static method. You can use it to get the metadata in dictionary format for an impact function. :returns: A dictionary representing all the metadata for the concrete impact function. :rtype: dict """ dict_meta = { 'id': 'VolcanoPolygonBuildingFunction', 'name': tr('Polygon volcano on buildings'), 'impact': tr('Be affected'), 'title': tr('Be affected'), 'function_type': 'old-style', 'author': 'AIFDR', 'date_implemented': 'N/A', 'overview': tr( 'To assess the impacts of volcano eruption on building.'), 'detailed_description': '', 'hazard_input': tr( 'The hazard layer must be a polygon layer. This layer ' 'must have an attribute representing the volcano hazard ' 'zone that can be specified in the impact function option.' 'The valid values for the volcano hazard zone are "Kawasan ' 'Rawan Bencana I", "Kawasan Rawan Bencana II", ' 'or "Kawasan Rawan Bencana III." If you want to see the ' 'name of the volcano in the result, you need to specify ' 'the volcano name attribute in the Impact Function ' 'options.'), 'exposure_input': tr( 'Vector polygon layer extracted from OSM where each ' 'polygon represents the footprint of a building.'), 'output': tr( 'Vector layer contains Map of building exposed to ' 'volcanic hazard zones for each Kawasan Rawan Bencana.'), 'actions': tr( 'Provide details about the number of buildings that are ' 'within each hazard zone.'), 'limitations': [], 'citations': [], 'layer_requirements': { 'hazard': { 'layer_mode': layer_mode_classified, 'layer_geometries': [layer_geometry_polygon], 'hazard_categories': [ hazard_category_multiple_event, hazard_category_single_event ], 'hazard_types': [hazard_volcano], 'continuous_hazard_units': [], 'vector_hazard_classifications': [ volcano_vector_hazard_classes], 'raster_hazard_classifications': [], 'additional_keywords': [ volcano_name_field] }, 'exposure': { 'layer_mode': layer_mode_classified, 'layer_geometries': [ layer_geometry_polygon, layer_geometry_point ], 'exposure_types': [exposure_structure], 'exposure_units': [], 'exposure_class_fields': [structure_class_field], 'additional_keywords': [] } }, 'parameters': OrderedDict([ ('postprocessors', OrderedDict([( 'BuildingType', building_type_postprocessor())])) ]) } return dict_meta
def as_dict(): """Return metadata as a dictionary. This is a static method. You can use it to get the metadata in dictionary format for an impact function. :returns: A dictionary representing all the metadata for the concrete impact function. :rtype: dict """ dict_meta = { 'id': 'VolcanoPolygonBuildingFunction', 'name': tr('Polygon volcano on buildings'), 'impact': tr('Be affected'), 'title': tr('Be affected'), 'function_type': 'old-style', 'author': 'AIFDR', 'date_implemented': 'N/A', 'overview': tr( 'To assess the impacts of volcano eruption on building.'), 'detailed_description': '', 'hazard_input': tr( 'The hazard layer must be a polygon layer. This layer ' 'must have an attribute representing the volcano hazard ' 'zone that can be specified in the impact function option. ' 'There are three classes low, medium, and high. The default ' 'values are "Kawasan Rawan Bencana I" for low, "Kawasan Rawan ' 'Bencana II" for medium, and "Kawasan Rawan Bencana III for ' 'high." If you want to see the name of the volcano in the ' 'result, you need to specify the volcano name attribute in ' 'the Impact Function options.'), 'exposure_input': tr( 'Vector polygon layer extracted from OSM where each ' 'polygon represents the footprint of a building.'), 'output': tr( 'Vector layer contains Map of building exposed to ' 'volcanic hazard zones for each Kawasan Rawan Bencana.'), 'actions': tr( 'Provide details about the number of buildings that are ' 'within each hazard zone.'), 'limitations': [], 'citations': [ { 'text': None, 'link': None } ], 'legend_title': tr('Building count'), 'legend_units': tr('(building)'), 'legend_notes': tr( 'Thousand separator is represented by %s' % get_thousand_separator()), 'layer_requirements': { 'hazard': { 'layer_mode': layer_mode_classified, 'layer_geometries': [layer_geometry_polygon], 'hazard_categories': [ hazard_category_multiple_event, hazard_category_single_event ], 'hazard_types': [hazard_volcano], 'continuous_hazard_units': [], 'vector_hazard_classifications': [ volcano_vector_hazard_classes], 'raster_hazard_classifications': [], 'additional_keywords': [ volcano_name_field] }, 'exposure': { 'layer_mode': layer_mode_classified, 'layer_geometries': [ layer_geometry_polygon, layer_geometry_point ], 'exposure_types': [exposure_structure], 'exposure_units': [], 'exposure_class_fields': [structure_class_field], 'additional_keywords': [] } }, 'parameters': OrderedDict([ ('postprocessors', OrderedDict([( 'BuildingType', building_type_postprocessor())])) ]) } return dict_meta
def as_dict(): """Return metadata as a dictionary. This is a static method. You can use it to get the metadata in dictionary format for an impact function. :returns: A dictionary representing all the metadata for the concrete impact function. :rtype: dict """ dict_meta = { 'id': 'ClassifiedPolygonHazardBuildingFunction', 'name': tr('Classified polygon hazard on buildings'), 'impact': tr('Be affected'), 'title': tr('Be affected'), 'function_type': 'qgis2.0', 'author': 'Akbar Gumbira ([email protected])', 'date_implemented': '17/04/2015', 'overview': tr( 'To assess the impact of each hazard zone on buildings.'), 'detailed_description': '', 'hazard_input': tr( 'The hazard layer must be a polygon layer. This layer ' 'must have an attribute representing the hazard ' 'zone that can be specified in the impact function options.'), 'exposure_input': tr( 'Vector polygon layer extracted from OSM where each ' 'polygon represents the footprint of a building.'), 'output': tr( 'A vector layer of buildings with each tagged according to ' 'the hazard zone in which it falls.'), 'actions': tr( 'Provide details about how many buildings fall within ' 'each hazard zone.'), 'limitations': [], 'citations': [ { 'text': None, 'link': None } ], 'map_title': tr('Buildings affected'), 'legend_title': tr('Building count'), 'legend_units': tr('(building)'), 'legend_notes': tr( 'Thousand separator is represented by %s' % get_thousand_separator()), 'layer_name': tr('Buildings affected'), 'layer_requirements': { 'hazard': { 'layer_mode': layer_mode_classified, 'layer_geometries': [layer_geometry_polygon], 'hazard_categories': [ hazard_category_multiple_event, hazard_category_single_event ], 'hazard_types': hazard_all, 'continuous_hazard_units': [], 'vector_hazard_classifications': [ generic_vector_hazard_classes], 'raster_hazard_classifications': [], 'additional_keywords': [] }, 'exposure': { 'layer_mode': layer_mode_classified, 'layer_geometries': [ layer_geometry_point, layer_geometry_polygon ], 'exposure_types': [exposure_structure], 'exposure_units': [], 'exposure_class_fields': [structure_class_field], 'additional_keywords': [] } }, 'parameters': OrderedDict([ ('postprocessors', OrderedDict([( 'BuildingType', building_type_postprocessor())])) ]) } return dict_meta
def as_dict(): """Return metadata as a dictionary. This is a static method. You can use it to get the metadata in dictionary format for an impact function. :returns: A dictionary representing all the metadata for the concrete impact function. :rtype: dict """ dict_meta = { 'id': 'ClassifiedPolygonHazardBuildingFunction', 'name': tr('Classified polygon hazard on buildings'), 'impact': tr('Be affected'), 'title': tr('Be affected'), 'function_type': 'old-style', 'author': 'Akbar Gumbira ([email protected])', 'date_implemented': '17/04/2015', 'overview': tr( 'To assess the impact of each hazard zone on buildings.'), 'detailed_description': '', 'hazard_input': tr( 'The hazard layer must be a polygon layer. This layer ' 'must have an attribute representing the hazard ' 'zone that can be specified in the impact function options.'), 'exposure_input': tr( 'Vector polygon layer extracted from OSM where each ' 'polygon represents the footprint of a building.'), 'output': tr( 'A vector layer of buildings with each tagged according to ' 'the hazard zone in which it falls.'), 'actions': tr( 'Provide details about how many buildings fall within ' 'each hazard zone.'), 'limitations': [], 'citations': [], 'categories': { 'hazard': { 'definition': hazard_definition, 'subcategories': hazard_all, 'units': [unit_classified], 'layer_constraints': [layer_vector_polygon] }, 'exposure': { 'definition': exposure_definition, 'subcategories': [exposure_structure], 'units': [ unit_building_type_type, unit_building_generic], 'layer_constraints': [ layer_vector_polygon, layer_vector_point] } }, 'parameters': OrderedDict([ # The attribute of hazard zone in hazard layer ('hazard zone attribute', 'KRB'), ('postprocessors', OrderedDict([( 'BuildingType', building_type_postprocessor())])) ]) } return dict_meta
def as_dict(): """Return metadata as a dictionary. This is a static method. You can use it to get the metadata in dictionary format for an impact function. :returns: A dictionary representing all the metadata for the concrete impact function. :rtype: dict """ dict_meta = { 'id': 'ClassifiedPolygonHazardBuildingFunction', 'name': tr('Classified polygon hazard on buildings'), 'impact': tr('Be affected'), 'title': tr('Be affected'), 'function_type': 'old-style', 'author': 'Akbar Gumbira ([email protected])', 'date_implemented': '17/04/2015', 'overview': tr('To assess the impact of each hazard zone on buildings.'), 'detailed_description': '', 'hazard_input': tr('The hazard layer must be a polygon layer. This layer ' 'must have an attribute representing the hazard ' 'zone that can be specified in the impact function options.'), 'exposure_input': tr('Vector polygon layer extracted from OSM where each ' 'polygon represents the footprint of a building.'), 'output': tr('A vector layer of buildings with each tagged according to ' 'the hazard zone in which it falls.'), 'actions': tr('Provide details about how many buildings fall within ' 'each hazard zone.'), 'limitations': [], 'citations': [], 'categories': { 'hazard': { 'definition': hazard_definition, 'subcategories': hazard_all, 'units': [unit_classified], 'layer_constraints': [layer_vector_polygon] }, 'exposure': { 'definition': exposure_definition, 'subcategories': [exposure_structure], 'units': [unit_building_type_type, unit_building_generic], 'layer_constraints': [layer_vector_polygon, layer_vector_point] } }, 'parameters': OrderedDict([ # The attribute of hazard zone in hazard layer ('hazard zone attribute', 'KRB'), ('postprocessors', OrderedDict([('BuildingType', building_type_postprocessor()) ])) ]) } return dict_meta
def as_dict(): """Return metadata as a dictionary. This is a static method. You can use it to get the metadata in dictionary format for an impact function. :returns: A dictionary representing all the metadata for the concrete impact function. :rtype: dict """ dict_meta = { 'id': 'VolcanoPolygonBuildingFunction', 'name': tr('Polygon volcano on buildings'), 'impact': tr('Be affected'), 'title': tr('Be affected'), 'function_type': 'old-style', 'author': 'AIFDR', 'date_implemented': 'N/A', 'overview': tr('To assess the impacts of volcano eruption on building.'), 'detailed_description': '', 'hazard_input': tr('The hazard layer must be a polygon layer. This layer ' 'must have an attribute representing the volcano hazard ' 'zone that can be specified in the impact function option.' 'The valid values for the volcano hazard zone are "Kawasan ' 'Rawan Bencana I", "Kawasan Rawan Bencana II", ' 'or "Kawasan Rawan Bencana III." If you want to see the ' 'name of the volcano in the result, you need to specify ' 'the volcano name attribute in the Impact Function ' 'options.'), 'exposure_input': tr('Vector polygon layer extracted from OSM where each ' 'polygon represents the footprint of a building.'), 'output': tr('Vector layer contains Map of building exposed to ' 'volcanic hazard zones for each Kawasan Rawan Bencana.'), 'actions': tr('Provide details about the number of buildings that are ' 'within each hazard zone.'), 'limitations': [], 'citations': [], 'categories': { 'hazard': { 'definition': hazard_definition, 'subcategories': [hazard_volcano], 'units': [unit_volcano_categorical], 'layer_constraints': [layer_vector_polygon] }, 'exposure': { 'definition': exposure_definition, 'subcategories': [exposure_structure], 'units': [unit_building_type_type, unit_building_generic], 'layer_constraints': [layer_vector_polygon, layer_vector_point] } }, 'parameters': OrderedDict([ # The attribute of hazard zone in hazard layer ('hazard zone attribute', 'KRB'), # The attribute for name of the volcano in hazard layer ('volcano name attribute', 'NAME'), ('postprocessors', OrderedDict([('BuildingType', building_type_postprocessor()) ])) ]) } return dict_meta
def as_dict(): """Return metadata as a dictionary. This is a static method. You can use it to get the metadata in dictionary format for an impact function. :returns: A dictionary representing all the metadata for the concrete impact function. :rtype: dict """ dict_meta = { "id": "FloodRasterBuildingFunction", "name": tr("Raster flood on buildings"), "impact": tr("Be flooded"), "title": tr("Be flooded"), "function_type": "old-style", # should be a list, but we can do it later. "author": "Ole Nielsen and Kristy van Putten", "date_implemented": "N/A", "overview": tr( "To assess the impacts of (flood or tsunami) inundation " "on building footprints originating from OpenStreetMap " "(OSM)." ), "detailed_description": tr( "The inundation status is calculated for each building " "(using the centroid if it is a polygon) based on the " "hazard levels provided. if the hazard is given as a " "raster a threshold of 1 meter is used. This is " "configurable through the InaSAFE interface. If the " "hazard is given as a vector polygon layer buildings are " "considered to be impacted depending on the value of " 'hazard attributes (in order) affected" or "FLOODPRONE": ' "If a building is in a region that has attribute " '"affected" set to True (or 1) it is impacted. If ' 'attribute "affected" does not exist but "FLOODPRONE" ' "does, then the building is considered impacted if " '"FLOODPRONE" is "yes". If neither affected" nor ' '"FLOODPRONE" is available, a building will be impacted ' "if it belongs to any polygon. The latter behaviour is " 'implemented through the attribute "inapolygon" which is ' "automatically assigned." ), "hazard_input": tr("A hazard raster layer where each cell represents flood " "depth (in meters)."), "exposure_input": tr( "Vector polygon or point layer extracted from OSM where " "each feature represents the footprint of a building." ), "output": tr( "Vector layer contains building is estimated to be " "flooded and the breakdown of the building by type." ), "actions": tr("Provide details about where critical infrastructure " "might be flooded."), "limitations": [ tr( "This function only flags buildings as impacted or not " "either based on a fixed threshold in case of raster " "hazard or the the attributes mentioned under input " "in case of vector hazard." ) ], "citations": [], "categories": { "hazard": { "definition": hazard_definition, "subcategories": [hazard_flood, hazard_tsunami], "units": [unit_metres_depth, unit_feet_depth], "layer_constraints": [layer_raster_continuous], }, "exposure": { "definition": exposure_definition, "subcategories": [exposure_structure], "units": [unit_building_type_type, unit_building_generic], "layer_constraints": [layer_vector_polygon, layer_vector_point], }, }, "parameters": OrderedDict( [ ("threshold [m]", 1.0), ("postprocessors", OrderedDict([("BuildingType", building_type_postprocessor())])), ] ), } return dict_meta
def as_dict(): """Return metadata as a dictionary. This is a static method. You can use it to get the metadata in dictionary format for an impact function. :returns: A dictionary representing all the metadata for the concrete impact function. :rtype: dict """ dict_meta = { 'id': 'FloodPolygonBuildingFunction', 'name': tr('Polygon flood on buildings'), 'impact': tr('Be flooded'), 'title': tr('Be flooded'), 'function_type': 'qgis2.0', 'author': 'Dmitry Kolesov', 'date_implemented': 'N/A', 'overview': tr( 'To assess the impacts of (flood or tsunami) inundation ' 'on building footprints with hazard in vector format.'), 'detailed_description': tr( 'The inundation status is calculated for each building ' '(using the centroid if it is a polygon) based on the value ' 'of hazard attribute. The attribute and the values that are ' 'considered as flooded can be configured in impact function ' 'options.'), 'hazard_input': tr( 'A hazard vector layer whose attribute that can be used to ' 'mark whether a polygon is flood or not.'), 'exposure_input': tr( 'Vector polygon or point layer extracted from OSM where ' 'each feature represents the footprint of a building.'), 'output': tr( 'Vector layer contains building is estimated to be ' 'flooded and the breakdown of the building by type.'), 'actions': '', 'limitations': [], 'citations': [], 'legend_units': '', 'legend_notes': '', 'map_title': tr('Buildings inundated'), 'legend_title': tr('Structure inundated status'), 'layer_name': tr('Flooded buildings'), 'layer_requirements': { 'hazard': { 'layer_mode': layer_mode_classified, 'layer_geometries': [layer_geometry_polygon], 'hazard_categories': [ hazard_category_single_event, hazard_category_multiple_event ], 'hazard_types': [hazard_flood], 'continuous_hazard_units': [], 'vector_hazard_classifications': [ flood_vector_hazard_classes], 'raster_hazard_classifications': [], 'additional_keywords': [] }, 'exposure': { 'layer_mode': layer_mode_classified, 'layer_geometries': [ layer_geometry_polygon, layer_geometry_point], 'exposure_types': [exposure_structure], 'exposure_units': [], 'exposure_class_fields': [structure_class_field], 'additional_keywords': [] } }, 'parameters': OrderedDict([ ('postprocessors', OrderedDict([ ('BuildingType', building_type_postprocessor()) ])) ]) } return dict_meta
def as_dict(): """Return metadata as a dictionary. This is a static method. You can use it to get the metadata in dictionary format for an impact function. :returns: A dictionary representing all the metadata for the concrete impact function. :rtype: dict """ dict_meta = { 'id': 'FloodPolygonBuildingFunction', 'name': tr('Polygon flood on buildings'), 'impact': tr('Be flooded'), 'title': tr('Be flooded'), 'function_type': 'qgis2.0', 'author': 'Dmitry Kolesov', 'date_implemented': 'N/A', 'overview': tr('N/A'), 'detailed_description': tr('N/A'), 'hazard_input': '', 'exposure_input': '', 'output': '', 'actions': '', 'limitations': [], 'citations': [], 'categories': { 'hazard': { 'definition': hazard_definition, 'subcategories': [hazard_flood, hazard_tsunami], 'units': [unit_wetdry], 'layer_constraints': [layer_vector_polygon] }, 'exposure': { 'definition': exposure_definition, 'subcategories': [exposure_structure], 'units': [unit_building_type_type], 'layer_constraints': [layer_vector_polygon] } }, 'parameters': OrderedDict([ # This field of the exposure layer contains # information about building types ('building_type_field', 'TYPE'), # This field of the hazard layer contains information # about inundated areas ('affected_field', 'FLOODPRONE'), # This value in 'affected_field' of the hazard layer # marks the areas as inundated ('affected_value', 'YES'), ('postprocessors', OrderedDict([('BuildingType', building_type_postprocessor()) ])) ]) } return dict_meta
def as_dict(): """Return metadata as a dictionary. This is a static method. You can use it to get the metadata in dictionary format for an impact function. :returns: A dictionary representing all the metadata for the concrete impact function. :rtype: dict """ dict_meta = { 'id': 'VolcanoPointBuildingFunction', 'name': tr('Point volcano on buildings'), 'impact': tr('Be affected'), 'title': tr('Be affected'), 'function_type': 'old-style', 'author': 'AIFDR', 'date_implemented': 'N/A', 'overview': tr( 'To assess the impacts of volcano points on buildings.'), 'detailed_description': '', 'hazard_input': tr( 'The hazard layer must be a point layer. This point will be ' 'buffered with the radii (in kilometer) specified in the ' 'parameters as the hazard zone. If you want to see the name ' 'of the volcano in the result, you need to specify the ' 'volcano name attribute in the Impact Function option.'), 'exposure_input': tr( 'Vector polygon layer extracted from OSM where each polygon ' 'represents the footprint of a building.'), 'output': tr( 'Vector layer contains Map of building exposed to volcanic ' 'hazard zones for each radius.'), 'actions': tr( 'Provide details about how many building would likely be ' 'affected by each hazard zones.'), 'limitations': [], 'citations': [], 'layer_requirements': { 'hazard': { 'layer_mode': layer_mode_classified, 'layer_geometries': [layer_geometry_point], 'hazard_categories': [ hazard_category_multiple_event, hazard_category_single_event ], 'hazard_types': [hazard_volcano], 'continuous_hazard_units': [], 'vector_hazard_classifications': [], 'raster_hazard_classifications': [], 'additional_keywords': [volcano_name_field] }, 'exposure': { 'layer_mode': layer_mode_classified, 'layer_geometries': [ layer_geometry_polygon, layer_geometry_point], 'exposure_types': [exposure_structure], 'exposure_units': [], 'exposure_class_fields': [structure_class_field], 'additional_keywords': [] } }, 'parameters': OrderedDict([ # The list of radii in km for volcano point hazard ('distances', distance()), ('postprocessors', OrderedDict([ ('BuildingType', building_type_postprocessor())])) ]) } return dict_meta
def as_dict(): """Return metadata as a dictionary. This is a static method. You can use it to get the metadata in dictionary format for an impact function. :returns: A dictionary representing all the metadata for the concrete impact function. :rtype: dict """ dict_meta = { 'id': 'EarthquakeBuildingFunction', 'name': tr('Earthquake on buildings'), 'impact': tr('Be affected'), 'title': tr('Be affected'), 'function_type': 'old-style', 'author': 'N/A', 'date_implemented': 'N/A', 'overview': tr( 'This impact function will calculate the impact of an ' 'earthquake on buildings, reporting how many are expected ' 'to be damaged.'), 'detailed_description': '', 'hazard_input': '', 'exposure_input': '', 'output': '', 'actions': '', 'limitations': [], 'citations': [], 'map_title': tr('Building affected by earthquake'), 'legend_notes': tr( 'The level of the impact is according to the threshold the ' 'user input.'), 'legend_units': tr('(mmi)'), 'legend_title': tr('Impact level'), 'layer_name': tr('Estimated buildings affected'), 'layer_requirements': { 'hazard': { 'layer_mode': layer_mode_continuous, 'layer_geometries': [layer_geometry_raster], 'hazard_categories': [ hazard_category_single_event, hazard_category_multiple_event ], 'hazard_types': [hazard_earthquake], 'continuous_hazard_units': [unit_mmi], 'vector_hazard_classifications': [], 'raster_hazard_classifications': [], 'additional_keywords': [] }, 'exposure': { 'layer_mode': layer_mode_classified, 'layer_geometries': [ layer_geometry_point, layer_geometry_polygon ], 'exposure_types': [exposure_structure], 'exposure_units': [], 'exposure_class_fields': [structure_class_field], 'additional_keywords': [] } }, 'parameters': OrderedDict( [('low_threshold', low_threshold()), ('medium_threshold', medium_threshold()), ('high_threshold', high_threshold()), ('postprocessors', OrderedDict([ ('BuildingType', building_type_postprocessor())]))] ) } return dict_meta
def as_dict(): """Return metadata as a dictionary. This is a static method. You can use it to get the metadata in dictionary format for an impact function. :returns: A dictionary representing all the metadata for the concrete impact function. :rtype: dict """ dict_meta = { 'id': 'EarthquakeBuildingFunction', 'name': tr('Earthquake on buildings'), 'impact': tr('Be affected'), 'title': tr('Be affected'), 'function_type': 'old-style', 'author': 'N/A', 'date_implemented': 'N/A', 'overview': tr( 'This impact function will calculate the impact of an ' 'earthquake on buildings, reporting how many are expected ' 'to be damaged.'), 'detailed_description': '', 'hazard_input': '', 'exposure_input': '', 'output': '', 'actions': '', 'limitations': [], 'citations': [], 'layer_requirements': { 'hazard': { 'layer_mode': layer_mode_continuous, 'layer_geometries': [layer_geometry_raster], 'hazard_categories': [ hazard_category_single_event, hazard_category_multiple_event ], 'hazard_types': [hazard_earthquake], 'continuous_hazard_units': [unit_mmi], 'vector_hazard_classifications': [], 'raster_hazard_classifications': [], 'additional_keywords': [] }, 'exposure': { 'layer_mode': layer_mode_classified, 'layer_geometries': [ layer_geometry_point, layer_geometry_polygon ], 'exposure_types': [exposure_structure], 'exposure_units': [], 'exposure_class_fields': [structure_class_field], 'additional_keywords': [] } }, 'parameters': OrderedDict( [('low_threshold', low_threshold()), ('medium_threshold', medium_threshold()), ('high_threshold', high_threshold()), ('postprocessors', OrderedDict([ ('BuildingType', building_type_postprocessor())]))] ) } return dict_meta
def as_dict(): """Return metadata as a dictionary. This is a static method. You can use it to get the metadata in dictionary format for an impact function. :returns: A dictionary representing all the metadata for the concrete impact function. :rtype: dict """ dict_meta = { 'id': 'ClassifiedRasterHazardBuildingFunction', 'name': tr('Classified raster hazard on buildings'), 'impact': tr('Be impacted'), 'title': tr('Be impacted in each hazard class'), 'function_type': 'old-style', 'author': 'Dianne Bencito', 'date_implemented': 'N/A', 'overview': tr( 'To assess the impacts of a classified hazard in raster ' 'format on a buildings vector layer.'), 'detailed_description': tr( 'This function will treat the values in the hazard raster ' 'layer as classes representing low, medium and high ' 'impact. You need to ensure that the keywords for the hazard ' 'layer have been set appropriately to define these classes.' 'The number of buildings that will be impacted will be ' 'calculated for each class. The report will show the total ' 'number of buildings that will be affected for each ' 'hazard class.'), 'hazard_input': tr( 'A hazard raster layer where each cell represents the ' 'class of the hazard. There should be 3 classes: e.g. ' '1, 2, and 3.'), 'exposure_input': tr( 'A vector polygon layer which can be extracted from OSM ' 'where each polygon represents the footprint of a ' 'building.'), 'output': tr( 'The impact layer will contain all structures that were ' 'exposed to the highest class (3) and a summary table ' 'containing the number of structures in each class.'), 'actions': tr( 'Provide details about the number of buildings that are ' 'within each hazard class.'), 'limitations': [tr('The number of classes is three.')], 'citations': [ { 'text': None, 'link': None } ], 'legend_notes': '', 'legend_units': tr('(Low, Medium, High)'), 'legend_title': tr('Structure inundated status'), 'layer_requirements': { 'hazard': { 'layer_mode': layer_mode_classified, 'layer_geometries': [layer_geometry_raster], 'hazard_categories': [ hazard_category_single_event, hazard_category_multiple_event ], 'hazard_types': hazard_all, 'continuous_hazard_units': [], 'vector_hazard_classifications': [], 'raster_hazard_classifications': [ generic_raster_hazard_classes ], 'additional_keywords': [] }, 'exposure': { 'layer_mode': layer_mode_classified, 'layer_geometries': [ layer_geometry_point, layer_geometry_polygon ], 'exposure_types': [exposure_structure], 'exposure_units': [], 'exposure_class_fields': [structure_class_field], 'additional_keywords': [] } }, # parameters 'parameters': OrderedDict([ ('postprocessors', OrderedDict([ ('BuildingType', building_type_postprocessor()) ])) ]) } return dict_meta
def as_dict(): """Return metadata as a dictionary. This is a static method. You can use it to get the metadata in dictionary format for an impact function. :returns: A dictionary representing all the metadata for the concrete impact function. :rtype: dict """ dict_meta = { 'id': 'FloodRasterBuildingFunction', 'name': tr('Raster flood on buildings'), 'impact': tr('Be flooded'), 'title': tr('Be flooded'), 'function_type': 'old-style', # should be a list, but we can do it later. 'author': 'Ole Nielsen and Kristy van Putten', 'date_implemented': 'N/A', 'overview': tr( 'To assess the impacts of (flood or tsunami) inundation ' 'on building footprints originating from OpenStreetMap ' '(OSM) with hazard in raster format.'), 'detailed_description': tr( 'The inundation status is calculated for each building ' '(using the centroid if it is a polygon) based on the ' 'flood threshold. The threshold can be configured in ' 'impact function options.'), 'hazard_input': tr( 'A hazard raster layer where each cell represents flood ' 'depth (in meters).'), 'exposure_input': tr( 'Vector polygon or point layer extracted from OSM where ' 'each feature represents the footprint of a building.'), 'output': tr( 'Vector layer contains building is estimated to be ' 'flooded and the breakdown of the building by type.'), 'actions': tr( 'Provide details about where critical infrastructure ' 'might be flooded.'), 'limitations': [ tr('This function only flags buildings as impacted or not ' 'either based on a fixed threshold') ], 'citations': [ { 'text': None, 'link': None } ], 'legend_notes': '', 'legend_title': tr('Flooded structure status'), 'legend_units': tr('(flooded, wet, or dry)'), 'layer_requirements': { 'hazard': { 'layer_mode': layer_mode_continuous, 'layer_geometries': [layer_geometry_raster], 'hazard_categories': [ hazard_category_single_event, hazard_category_multiple_event ], 'hazard_types': [hazard_flood], 'continuous_hazard_units': [unit_feet, unit_metres], 'vector_hazard_classifications': [], 'raster_hazard_classifications': [], 'additional_keywords': [] }, 'exposure': { 'layer_mode': layer_mode_classified, 'layer_geometries': [ layer_geometry_point, layer_geometry_polygon ], 'exposure_types': [exposure_structure], 'exposure_units': [], 'exposure_class_fields': [structure_class_field], 'additional_keywords': [] } }, 'parameters': OrderedDict([ ('threshold', threshold()), ('postprocessors', OrderedDict([ ('BuildingType', building_type_postprocessor()) ])) ]) } return dict_meta
def as_dict(): """Return metadata as a dictionary. This is a static method. You can use it to get the metadata in dictionary format for an impact function. :returns: A dictionary representing all the metadata for the concrete impact function. :rtype: dict """ dict_meta = { 'id': 'TsunamiRasterBuildingFunction', 'name': tr('Raster tsunami on buildings'), 'impact': tr('Be inundated'), 'title': tr('Be inundated'), 'function_type': 'old-style', # should be a list, but we can do it later. 'author': 'Ole Nielsen, Kristy van Putten, and Ismail Sunni', 'date_implemented': 'N/A', 'overview': tr('To assess the impacts of tsunami inundation on building ' 'footprints in vector format with hazard in raster format.'), 'detailed_description': tr('The inundation status is calculated for each building ' '(using the centroid if it is a polygon) based on the ' 'tsunami threshold. The threshold can be configured in ' 'impact function options.'), 'hazard_input': tr('A hazard raster layer where each cell represents tsunami ' 'inundation depth (in meters).'), 'exposure_input': tr('Vector polygon or point layer where each feature represents ' 'the footprint of a building.'), 'output': tr('Vector layer contains building is estimated to be ' 'inundated and the breakdown of the building by type.'), 'actions': tr('Provide details about where critical infrastructure ' 'might be inundated.'), 'limitations': [ tr('This function only flags buildings as impacted or not either ' 'based on a fixed threshold') ], 'citations': [{ 'text': tr('Papadopoulos, Gerassimos A., and Fumihiko Imamura. ' '"A proposal for a new tsunami intensity scale." ' 'ITS 2001 proceedings, no. 5-1, pp. 569-577. 2001.'), 'link': None }], 'legend_notes': '', 'legend_title': tr('Inundated structure status'), 'legend_units': tr('(low, medium, high, and very high)'), 'layer_requirements': { 'hazard': { 'layer_mode': layer_mode_continuous, 'layer_geometries': [layer_geometry_raster], 'hazard_categories': [ hazard_category_single_event, hazard_category_multiple_event ], 'hazard_types': [hazard_tsunami], 'continuous_hazard_units': [unit_feet, unit_metres], 'vector_hazard_classifications': [], 'raster_hazard_classifications': [], 'additional_keywords': [] }, 'exposure': { 'layer_mode': layer_mode_classified, 'layer_geometries': [layer_geometry_point, layer_geometry_polygon], 'exposure_types': [exposure_structure], 'exposure_units': [], 'exposure_class_fields': [structure_class_field], 'additional_keywords': [] } }, 'parameters': OrderedDict([('low_threshold', low_threshold()), ('medium_threshold', medium_threshold()), ('high_threshold', high_threshold()), ('postprocessors', OrderedDict([('BuildingType', building_type_postprocessor())]))]) } return dict_meta
def as_dict(): """Return metadata as a dictionary. This is a static method. You can use it to get the metadata in dictionary format for an impact function. :returns: A dictionary representing all the metadata for the concrete impact function. :rtype: dict """ dict_meta = { 'id': 'FloodPolygonBuildingFunction', 'name': tr('Polygon flood on buildings'), 'impact': tr('Be flooded'), 'title': tr('Be flooded'), 'function_type': 'qgis2.0', 'author': 'Dmitry Kolesov', 'date_implemented': 'N/A', 'overview': tr('To assess the impacts of (flood or tsunami) inundation ' 'on building footprints with hazard in vector format.'), 'detailed_description': tr('The inundation status is calculated for each building ' '(using the centroid if it is a polygon) based on the value ' 'of hazard attribute. The attribute and the values that are ' 'considered as flooded can be configured in impact function ' 'options.'), 'hazard_input': tr('A hazard vector layer whose attribute that can be used to ' 'mark whether a polygon is flood or not.'), 'exposure_input': tr('Vector polygon or point layer extracted from OSM where ' 'each feature represents the footprint of a building.'), 'output': tr('Vector layer contains building is estimated to be ' 'flooded and the breakdown of the building by type.'), 'actions': '', 'limitations': [], 'citations': [], 'layer_requirements': { 'hazard': { 'layer_mode': layer_mode_classified, 'layer_geometries': [layer_geometry_polygon], 'hazard_categories': [ hazard_category_single_event, hazard_category_multiple_event ], 'hazard_types': [hazard_flood], 'continuous_hazard_units': [], 'vector_hazard_classifications': [flood_vector_hazard_classes], 'raster_hazard_classifications': [], 'additional_keywords': [] }, 'exposure': { 'layer_mode': layer_mode_classified, 'layer_geometries': [layer_geometry_polygon, layer_geometry_point], 'exposure_types': [exposure_structure], 'exposure_units': [], 'exposure_class_fields': [structure_class_field], 'additional_keywords': [] } }, 'parameters': OrderedDict([('postprocessors', OrderedDict([('BuildingType', building_type_postprocessor())]))]) } return dict_meta
def as_dict(): """Return metadata as a dictionary. This is a static method. You can use it to get the metadata in dictionary format for an impact function. :returns: A dictionary representing all the metadata for the concrete impact function. :rtype: dict """ dict_meta = { 'id': 'FloodRasterBuildingFunction', 'name': tr('Raster flood on buildings'), 'impact': tr('Be flooded'), 'title': tr('Be flooded'), 'function_type': 'old-style', # should be a list, but we can do it later. 'author': 'Ole Nielsen and Kristy van Putten', 'date_implemented': 'N/A', 'overview': tr( 'To assess the impacts of (flood or tsunami) inundation ' 'on building footprints originating from OpenStreetMap ' '(OSM).'), 'detailed_description': tr( 'The inundation status is calculated for each building ' '(using the centroid if it is a polygon) based on the ' 'hazard levels provided. if the hazard is given as a ' 'raster a threshold of 1 meter is used. This is ' 'configurable through the InaSAFE interface. If the ' 'hazard is given as a vector polygon layer buildings are ' 'considered to be impacted depending on the value of ' 'hazard attributes (in order) affected" or "FLOODPRONE": ' 'If a building is in a region that has attribute ' '"affected" set to True (or 1) it is impacted. If ' 'attribute "affected" does not exist but "FLOODPRONE" ' 'does, then the building is considered impacted if ' '"FLOODPRONE" is "yes". If neither affected" nor ' '"FLOODPRONE" is available, a building will be impacted ' 'if it belongs to any polygon. The latter behaviour is ' 'implemented through the attribute "inapolygon" which is ' 'automatically assigned.'), 'hazard_input': tr( 'A hazard raster layer where each cell represents flood ' 'depth (in meters).'), 'exposure_input': tr( 'Vector polygon or point layer extracted from OSM where ' 'each feature represents the footprint of a building.'), 'output': tr( 'Vector layer contains building is estimated to be ' 'flooded and the breakdown of the building by type.'), 'actions': tr( 'Provide details about where critical infrastructure ' 'might be flooded.'), 'limitations': [ tr('This function only flags buildings as impacted or not ' 'either based on a fixed threshold in case of raster ' 'hazard or the the attributes mentioned under input ' 'in case of vector hazard.') ], 'citations': [], 'categories': { 'hazard': { 'definition': hazard_definition, 'subcategories': [ hazard_flood, hazard_tsunami ], 'units': [ unit_metres_depth, unit_feet_depth], 'layer_constraints': [ layer_raster_continuous, ] }, 'exposure': { 'definition': exposure_definition, 'subcategories': [exposure_structure], 'units': [ unit_building_type_type, unit_building_generic], 'layer_constraints': [ layer_vector_polygon, layer_vector_point ] } }, 'parameters': OrderedDict([ ('threshold [m]', 1.0), ('postprocessors', OrderedDict([ ('BuildingType', building_type_postprocessor()) ])) ]) } return dict_meta
def as_dict(): """Return metadata as a dictionary. This is a static method. You can use it to get the metadata in dictionary format for an impact function. :returns: A dictionary representing all the metadata for the concrete impact function. :rtype: dict """ dict_meta = { 'id': 'TsunamiRasterBuildingFunction', 'name': tr('Raster tsunami on buildings'), 'impact': tr('Be inundated'), 'title': tr('Be inundated'), 'function_type': 'old-style', # should be a list, but we can do it later. 'author': 'Ole Nielsen, Kristy van Putten, and Ismail Sunni', 'date_implemented': 'N/A', 'overview': tr( 'To assess the impacts of tsunami inundation on building ' 'footprints in vector format with hazard in raster format.'), 'detailed_description': tr( 'The inundation status is calculated for each building ' '(using the centroid if it is a polygon) based on the ' 'tsunami threshold. The threshold can be configured in ' 'impact function options.'), 'hazard_input': tr( 'A hazard raster layer where each cell represents tsunami ' 'inundation depth (in meters).'), 'exposure_input': tr( 'Vector polygon or point layer where each feature represents ' 'the footprint of a building.'), 'output': tr( 'Vector layer contains building is estimated to be ' 'inundated and the breakdown of the building by type.'), 'actions': tr( 'Provide details about where critical infrastructure ' 'might be inundated.'), 'limitations': [tr( 'This function only flags buildings as impacted or not either ' 'based on a fixed threshold') ], 'citations': [ tr('Papadopoulos, Gerassimos A., and Fumihiko Imamura. ' '"A proposal for a new tsunami intensity scale." ' 'ITS 2001 proceedings, no. 5-1, pp. 569-577. 2001.') ], 'legend_notes': '', 'map_title': tr('Inundated buildings'), 'legend_title': tr('Inundated structure status'), 'legend_units': tr('(low, medium, high, and very high)'), 'layer_name': tr('Estimated buildings affected'), 'layer_requirements': { 'hazard': { 'layer_mode': layer_mode_continuous, 'layer_geometries': [layer_geometry_raster], 'hazard_categories': [ hazard_category_single_event, hazard_category_multiple_event ], 'hazard_types': [hazard_tsunami], 'continuous_hazard_units': [unit_feet, unit_metres], 'vector_hazard_classifications': [], 'raster_hazard_classifications': [], 'additional_keywords': [] }, 'exposure': { 'layer_mode': layer_mode_classified, 'layer_geometries': [ layer_geometry_point, layer_geometry_polygon ], 'exposure_types': [exposure_structure], 'exposure_units': [], 'exposure_class_fields': [structure_class_field], 'additional_keywords': [] } }, 'parameters': OrderedDict( [ ('low_threshold', low_threshold()), ('medium_threshold', medium_threshold()), ('high_threshold', high_threshold()), ('postprocessors', OrderedDict( [ ('BuildingType', building_type_postprocessor()) ]) ) ]) } return dict_meta
def as_dict(): """Return metadata as a dictionary. This is a static method. You can use it to get the metadata in dictionary format for an impact function. :returns: A dictionary representing all the metadata for the concrete impact function. :rtype: dict """ dict_meta = { 'id': 'FloodRasterBuildingFunction', 'name': tr('Raster flood on buildings'), 'impact': tr('Be flooded'), 'title': tr('Be flooded'), 'function_type': 'old-style', # should be a list, but we can do it later. 'author': 'Ole Nielsen and Kristy van Putten', 'date_implemented': 'N/A', 'overview': tr( 'To assess the impacts of (flood or tsunami) inundation ' 'on building footprints originating from OpenStreetMap ' '(OSM).'), 'detailed_description': tr( 'The inundation status is calculated for each building ' '(using the centroid if it is a polygon) based on the ' 'hazard levels provided. if the hazard is given as a ' 'raster a threshold of 1 meter is used. This is ' 'configurable through the InaSAFE interface. If the ' 'hazard is given as a vector polygon layer buildings are ' 'considered to be impacted depending on the value of ' 'hazard attributes (in order) affected" or "FLOODPRONE": ' 'If a building is in a region that has attribute ' '"affected" set to True (or 1) it is impacted. If ' 'attribute "affected" does not exist but "FLOODPRONE" ' 'does, then the building is considered impacted if ' '"FLOODPRONE" is "yes". If neither affected" nor ' '"FLOODPRONE" is available, a building will be impacted ' 'if it belongs to any polygon. The latter behaviour is ' 'implemented through the attribute "inapolygon" which is ' 'automatically assigned.'), 'hazard_input': tr( 'A hazard raster layer where each cell represents flood ' 'depth (in meters).'), 'exposure_input': tr( 'Vector polygon or point layer extracted from OSM where ' 'each feature represents the footprint of a building.'), 'output': tr( 'Vector layer contains building is estimated to be ' 'flooded and the breakdown of the building by type.'), 'actions': tr( 'Provide details about where critical infrastructure ' 'might be flooded.'), 'limitations': [ tr('This function only flags buildings as impacted or not ' 'either based on a fixed threshold in case of raster ' 'hazard or the the attributes mentioned under input ' 'in case of vector hazard.') ], 'citations': [], 'layer_requirements': { 'hazard': { 'layer_mode': layer_mode_continuous, 'layer_geometries': [layer_geometry_raster], 'hazard_categories': [ hazard_category_single_event, hazard_category_multiple_event ], 'hazard_types': [hazard_flood, hazard_tsunami], 'continuous_hazard_units': [unit_feet, unit_metres], 'vector_hazard_classifications': [], 'raster_hazard_classifications': [], 'additional_keywords': [] }, 'exposure': { 'layer_mode': layer_mode_classified, 'layer_geometries': [ layer_geometry_point, layer_geometry_polygon ], 'exposure_types': [exposure_structure], 'exposure_units': [], 'exposure_class_fields': [structure_class_field], 'additional_keywords': [] } }, 'parameters': OrderedDict([ ('threshold', threshold()), ('postprocessors', OrderedDict([ ('BuildingType', building_type_postprocessor()) ])) ]) } return dict_meta