Skip to content
Snippets Groups Projects
Select Git revision
  • docs-patch
  • feature/110-compatibility-of-the-loss-calculator-with-aggregated-exposure-models
  • master default protected
  • feature/implement_security
  • feature/105-read-in-the-inundation-map
  • 98-the-api-needs-to-have-user-restrictions
  • bug/where_statement
  • 82-correct-the-entry-point-in-the-losscalculator
  • feature/76-add-ground-motion-values-to-the-damage-database
  • feature/78-changing-damage_calculator-py-to-match-new-result-database-table-name-changes
  • first_release_losscalculator
  • feature/devel
  • feature/api-rewrite-fix-docker
  • feature/exposure-damage-api
  • feature/refactor-argument-parsing
  • bugfix/remove-deprecated-arguments
  • feature/api
  • bugfix/example
  • feature/9-create-simple-test
  • 47-fix-ci
  • v1.0.1
  • v1.0.0
22 results

loss-calculator

  • Clone with SSH
  • Clone with HTTPS
  • user avatar
    Danijel Schorlemmer authored
    Initialize taxonomy map dictionary so that there is always a taxonomy map to work with (even if empty)
    52f4b95c
    History

    losscalculator

    This program computes the probabilities of occurrence of damage states for scenario earthquakes, given a ground-motion field, an exposure model representing the assets in the region of interest and fragility functions that model the probability of exceeding different damage states given an intensity measure level.

    Requirements

    • python3
    • pandas
    • numpy
    • scipy
    • pyproj
    • shapely

    Usage

    To run the program please call:

    python3 damage_calculator.py [OPTIONS] -c filepath -e filepath -f pathname -g filepath -p filepath -t filepath

    Required Parameters

    -c, --cell-ids=filepath

    Defines the filepath to the file with tile IDs.

    -e, --exposure=filepath

    Defines the filepath to the exposure model file.

    -f, --fragilities=pathname

    Defines the pathname of the directory with all fragility-function files.

    -g, --ground-motion-field=filepath

    Defines the filepath of the ground-motion field.

    -p, --geometry=filepath

    Defines the filepath of the polygon definitions.

    -t, --taxonomy-map=filepath

    Defines the filepath to the taxonomy file.

    Optional Parameters

    -h, --help

    Provides information on the inputs and terminates the program.

    -i, --interpolation-method={linear, nearest, cubic}

    Defines the method for interpolating ground-motion values. Default is linear.

    -o, --overwrite

    If set, an existing result file will be overwritten, otherwise the program will terminate.

    -r, --results=filepath

    Defines the result filepath. Default is damage_result.csv.

    -x, --exposure-type={cell, building}

    Defines the exposure type. Default is cell.

    Copyright and copyleft

    Copyright (C) 2020

    • Helmholtz-Zentrum Potsdam Deutsches GeoForschungsZentrum GFZ

    This program is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.

    This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Affero General Public License for more details.

    You should have received a copy of the GNU Affero General Public License along with this program. If not, see http://www.gnu.org/licenses/.

    Also add information on how to contact you by electronic and paper mail.

    If your software can interact with users remotely through a computer network, you should also make sure that it provides a way for users to get its source. For example, if your program is a web application, its interface could display a "Source" link that leads users to an archive of the code. There are many ways you could offer source, and different solutions will be better for different programs; see section 13 for the specific requirements.

    See the LICENSE for the full license text.