19
ORIGINAL PAPER Development of the OpenQuake engine, the Global Earthquake Model’s open-source software for seismic risk assessment Vitor Silva Helen Crowley Marco Pagani Damiano Monelli Rui Pinho Received: 3 October 2012 / Accepted: 24 February 2013 Ó Springer Science+Business Media Dordrecht 2013 Abstract The Global Earthquake Model aims to combine the main features of state-of- the-art science, global collaboration and buy-in, transparency and openness in an initiative to calculate and communicate earthquake risk worldwide. One of the first steps towards this objective has been the open-source development and release of software for seismic hazard and risk assessment called the OpenQuake engine. This software comprises a set of calculators capable of computing human or economic losses for a collection of assets, caused by a given scenario event, or by considering the probability of all possible events that might happen within a region within a certain time span. This paper provides an insight into the current status of the development of this tool and presents a comprehensive description of each calculator, with example results. Keywords Seismic hazard Seismic risk Loss assessment Open-source 1 Introduction The OpenQuake project (http://www.globalquakemodel.org/openquake/) was initiated as part of the Global Earthquake Model (GEM) (http://www.globalquakemodel.org) (Pinho 2012), a global collaborative effort that brings together state-of-the-art science and national/regional/international organizations and individuals with the aim of establishing uniform and open standards for calculating and communicating earthquake risk worldwide. OpenQuake is a web-based risk assessment platform, which will offer an integrated environment for modelling, viewing, exploring and managing earthquake risk. The engine behind the platform currently has five main calculators, each one contributing uniquely in the area of seismic risk assessment and mitigation. An overview of these calculators with a brief description of how one can benefit from the various outputs is presented in Table 1. V. Silva (&) H. Crowley M. Pagani R. Pinho GEM Foundation, Via Ferrata 1, 27100 Pavia, Italy e-mail: [email protected] D. Monelli Swiss Seismological Service, ETH, Sonneggstrasse 5, 8092 Zurich, Switzerland 123 Nat Hazards DOI 10.1007/s11069-013-0618-x

Development of the OpenQuake engine, the Global Earthquake Model’s open-source software for seismic risk assessment

Embed Size (px)

Citation preview

Page 1: Development of the OpenQuake engine, the Global Earthquake Model’s open-source software for seismic risk assessment

ORI GIN AL PA PER

Development of the OpenQuake engine, the GlobalEarthquake Model’s open-source software for seismicrisk assessment

Vitor Silva • Helen Crowley • Marco Pagani • Damiano Monelli •

Rui Pinho

Received: 3 October 2012 / Accepted: 24 February 2013� Springer Science+Business Media Dordrecht 2013

Abstract The Global Earthquake Model aims to combine the main features of state-of-

the-art science, global collaboration and buy-in, transparency and openness in an initiative

to calculate and communicate earthquake risk worldwide. One of the first steps towards

this objective has been the open-source development and release of software for seismic

hazard and risk assessment called the OpenQuake engine. This software comprises a set of

calculators capable of computing human or economic losses for a collection of assets,

caused by a given scenario event, or by considering the probability of all possible events

that might happen within a region within a certain time span. This paper provides an

insight into the current status of the development of this tool and presents a comprehensive

description of each calculator, with example results.

Keywords Seismic hazard � Seismic risk � Loss assessment � Open-source

1 Introduction

The OpenQuake project (http://www.globalquakemodel.org/openquake/) was initiated as

part of the Global Earthquake Model (GEM) (http://www.globalquakemodel.org) (Pinho

2012), a global collaborative effort that brings together state-of-the-art science and

national/regional/international organizations and individuals with the aim of establishing

uniform and open standards for calculating and communicating earthquake risk worldwide.

OpenQuake is a web-based risk assessment platform, which will offer an integrated

environment for modelling, viewing, exploring and managing earthquake risk. The engine

behind the platform currently has five main calculators, each one contributing uniquely in

the area of seismic risk assessment and mitigation. An overview of these calculators with a

brief description of how one can benefit from the various outputs is presented in Table 1.

V. Silva (&) � H. Crowley � M. Pagani � R. PinhoGEM Foundation, Via Ferrata 1, 27100 Pavia, Italye-mail: [email protected]

D. MonelliSwiss Seismological Service, ETH, Sonneggstrasse 5, 8092 Zurich, Switzerland

123

Nat HazardsDOI 10.1007/s11069-013-0618-x

Page 2: Development of the OpenQuake engine, the Global Earthquake Model’s open-source software for seismic risk assessment

In January 2009, GEM launched a pilot project named GEM1, which had the objective

of developing the initial IT infrastructure of GEM. As part of this effort, a number of

existing hazard and risk software applications were reviewed (Danciu et al. 2010; Crowley

et al. 2010). The purpose of this study was not to validate or test the accuracy of any of the

applications, but rather to understand their capabilities and limitations, thus allowing the

specification of the first scientific requirements of the OpenQuake engine. The selection of

the seismic risk software to be evaluated was based on the level of public availability,

reliability and openness, thus leaving commercial software out of this list. Table 2

describes some of the features of the seismic risk software evaluated in this first phase, as

well as their similarity with the current calculators implemented on OpenQuake.

It is important to mention that despite the fact that some of the aforementioned software

incorporates calculator philosophies identical to the ones implemented in the OpenQuake

engine, their implementation might vary significantly. For example, seismic hazard is not

calculated by some software (thus needing other tools for its computation), and in some

cases, the uncertainties in the various inputs are neglected.

The well-known HAZUS software (FEMA 2003) was also recognized in GEM1 as a

very useful tool and a pioneering application in seismic risk assessment because the

methodologies behind this software have been the basis for many of the codes tested in

GEM1; it was thus implicitly part of the GEM1 evaluation. These reviews are documented

in Crowley et al. (2010) and were fundamental in order to understand the current state of

the practice in seismic hazard and risk software, as well as to identify the standard

Table 1 Description of the calculators of the current OpenQuake engine

Calculator Symbol Purpose

Scenario risk SCN This calculator is capable of computing losses and loss statistics due to asingle, scenario earthquake, for a collection of assets, which isimportant, for example, for emergency management planning and forraising societal awareness of risk.

Scenario damageassessment

SDA This calculator is capable of estimating damage distribution due to asingle, scenario earthquake, for a collection of assets, which can be usedfor emergency management planning or to assess which assets are moreseismic vulnerable.

Probabilistic Event-based Risk

PEB This calculator computes the probability of losses and loss statistics for acollection of assets, based on the probabilistic hazard. The losses arecalculated with an event-based approach, such that the simultaneouslosses to a set (or portfolio) of assets can be calculated. The output ofthis calculator can be used to assess the aggregated expected losses for acollection of assets.

Classical PSHA-based Risk

CPB This calculator leads to the computation of the probability of losses andloss statistics for single assets, based on a probabilistic description ofthe hazard. The output of this calculator is useful for comparative riskassessment between assets at different locations, which can be used, forexample, for the prioritisation of risk mitigation efforts.

Benefit–cost ratio BCR This calculator is a decision-support tool for deciding whether theemployment of retrofitting/strengthening measures to a collection ofexisting buildings is advantageous from an economical point of view.This output can be used to prioritize the regions in need for retrofitting/strengthening activities or to assess which seismic design is moreeconomically adequate for a given region.

Nat Hazards

123

Page 3: Development of the OpenQuake engine, the Global Earthquake Model’s open-source software for seismic risk assessment

functionalities that the OpenQuake engine should feature and the gaps that it would need to

fill. The OpenQuake engine currently has the following characteristics:

• An open-source software license with the code available on a public repository;

• Technical support and documentation;

• Users can upload their own hazard, vulnerability and exposure models (and it is thus

not tied to any specific region in the world);

• Hazard and risk calculations (scenario and probabilistic) are combined within a single

software, but users are able to run hazard-only and risk-only calculations;

• Site amplification is considered through the specification of Vs30 values at each site

(the average shear wave velocity over the top 30 metres of soil);

• Logic trees are employed to model the epistemic uncertainty;

• Different types of assets can be modelled (e.g. buildings, population);

• Modelling of spatial correlation of ground-motion residuals is considered;

Table 2 Summary of the seismic risk software evaluated in GEM1

Software Institutiona Programminglanguage

Applicability Availabilityb Graphical userinterface

Type ofcalculatorsc

SELENAd NORSAR MATLAB/C User-defined OS Yes SCN/SDA/PEB

EQRMe GA Python User-defined OS No SCN/SDA/PEB

ELERf KOERI MATLAB User-defined SA Yes SCN/SDA

QLARMg WAPMERR Java World SC Yes SCN/SDA

CEDIMh CEDIM Visual Basic User-defined SC Yes SCN/SDA/CPB

CAPRAi World Bank Visual Basic CentralAmerica

SC Yes SCN/PEB

RiskScapej GNS Java NewZealand

SA Yes SCN/SDA

LNECLossk LNEC Fortran Portugal SC No SCN/SDA

MAEvizl MAECenter

Java User-defined OS Yes SCN/SDA/CPB

OpenRiskm SPA Risk Java USA SA Yes CPB/BCR

a Further information about each institution can be found in the references sectionb OS open-source (code on a public repository), SA standard application (available under request), SCsource code (available under request)c The definition of each acronym is described in Table 1d http://www.norsar.no/pc-35-68-SELENA.aspxe http://www.ga.gov.au/hazards/earthquakes.htmlf http://www.koeri.boun.edu.tr/depremmuh/eskig http://www.wapmerr.org/qlarm.asph http://www.cedim.dei http://www.ecapra.org/softwarej http://www.riskscape.org.nzk http://www-ext.lnec.pt/LNEC/DE/NESDEl http://rcp.ncsa.uiuc.edu/maeviz/about.htmlm http://www.risk-agora.org

Nat Hazards

123

Page 4: Development of the OpenQuake engine, the Global Earthquake Model’s open-source software for seismic risk assessment

• Modelling of the correlation of uncertainty in building vulnerability is considered;

• It is scalable, with parallelized calculators, and can be used on a single processor

laptop, as well as on a cluster or cloud computing infrastructure;

• A full spectrum of hazard and risk products such as stochastic event sets, ground-

motion fields, uniform hazard spectra, hazard curves and maps, disaggregation plots,

damage and loss curves and maps can be produced.

Despite this list of achievements, other important features were also identified during

the review of the various software, such as the need for a user-friendly and intuitive user

interface, or the capability of running the calculations on any platform (Windows, Mac,

Linux, etc.), which are still part of the OpenQuake engine development roadmap. The

current status of the supported calculators of the OpenQuake engine is described in this

paper, with emphasis given to those features which are more relevant to seismic risk.

2 OpenQuake engine: seismic hazard and risk software

The OpenQuake engine is open-source software written in the Python programming lan-

guage for calculating seismic hazard and risk at variable scales (from single sites to large

regions). The engine relies on two scientific Python libraries for hazard and risk compu-

tations, respectively, oq-hazardlib and oq-risklib. It also relies on a number of other,

independent, open-source projects such as Celery (http://celeryproject.org) and RabbitMQ

(http://www.rabbitmq.com). The current version of the OpenQuake engine (v0.8) is a

‘developer’ release that can be executed through a command line interface, though a

graphical user interface (GUI) is currently being developed. The OpenQuake engine is

licensed with an Affero General Public License (AGPL); therefore, it is Free Open Source

Software (FOSS), and it is currently hosted on GitHub (https://github.com/gem/oq-engine),

a web-based hosting service for open-source software development projects.

An important characteristic of the OpenQuake engine is the strong emphasis on testing,

which ensures that the same results are obtained following any changes or additions to the

code base. A number of verification tests have been implemented, such as the so-called

PEER tests that were set up by Thomas et al. (2010) to test hazard calculations in hazard

assessment software. All such testing ensures that the code is fully checked for correctness,

completeness and quality. For what concerns ‘‘validation’’ or ‘‘calibration’’ (i.e. checking

that the results match reality, and modifying them accordingly), such tests are not part of

the engine development and will instead be carried out as part of a wider GEM effort, as

these activities relate more to the testing of models rather than the software itself.

The scientific libraries of the OpenQuake engine rely on a data model to represent the

objects used in hazard and risk calculations; the latter is being developed in parallel to the

engine, and a transparent and standard markup language is utilized to transfer different

types of information within and out of the software. This language, which has been named

the Natural hazards Risk Markup Language (NRML), is XML-based and leverages from

the GEM1 experience (Pagani et al. 2010a) and existing standards, such as the Geography

Markup Language (GML).

NRML is being hosted on a repository at GitHub (https://github.com/gem/nrml), and

information regarding how to create and edit these files can be found within the Open-

Quake Engine User Manual (GEM 2012a). Although the present scope of NRML is for

seismic risk, it is planned to extend this markup language to cover other natural hazards

such as hurricanes, floods or tsunamis. Currently, NRML is being used to represent input

Nat Hazards

123

Page 5: Development of the OpenQuake engine, the Global Earthquake Model’s open-source software for seismic risk assessment

data such as hazard source zone models, logic trees, finite ruptures, vulnerability models,

fragility models, exposure models, all of which are described in the following sections.

2.1 Seismic source model

A seismic source model provides information about location, geometry, and activity of

seismic sources (described through magnitude frequency distributions). A seismic source

model is defined as a sequence of seismic sources, and in NRML, each seismic source can

be defined as one of four possible typologies:

• Area: Polygonal region describing area of uniform seismicity.

• Point: Single location describing a point of concentrated seismicity (Fig. 1).

• Simple (geometry) fault: 3D surface describing seismicity on a simple (i.e. regular)

fault plane.

• Complex (geometry) fault: 3D surface allowing description of seismicity occurring on

a complex fault plane (Fig. 1).

These four categories have been derived after an extensive evaluation of seismic hazard

models that was carried out during the GEM1 project (Pagani et al. 2010b). For instance,

area sources have been widely used during the GSHAP project (Giardini 1999), whilst

point, simple fault and complex fault sources are often utilized in the USGS models, such

as in the calculation of the latest hazard maps for the United States (Petersen et al. 2008).

Collections of point sources can be used to represent gridded seismicity models, whilst

simple fault sources are employed to describe active shallow crust sources, and complex

faults are usually adopted for modelling subduction interface seismicity.

2.2 Logic tree model

Logic trees are widely used in modern probabilistic seismic hazard assessment (PSHA)

(e.g. Bommer and Scherbaum 2008). The goal of a logic tree is to systematically describe

epistemic uncertainties (i.e. uncertainties arising from a lack of knowledge or data) that are

to be considered in a seismic hazard/risk analysis. In the current schema, a logic tree is

structured as a sequence of branching levels, each branching level containing one or more

branch sets. A branch set defines an uncertainty type (e.g. relative uncertainties on

Gutenberg–Richter maximum magnitude), and a branch describes a particular realization

of the uncertainty (e.g. ?0.5 to be added to the maximum magnitude) with a weight

representing the degree of belief or probability associated with that particular realization.

Options for defining branch sets that apply to specific sources or to sources belonging to

certain tectonic regions are available, hence allowing the definition of complex logic trees.

Fig. 1 Point sources (left) and complex geometry fault sources (right) modelled in the OpenQuake engine

Nat Hazards

123

Page 6: Development of the OpenQuake engine, the Global Earthquake Model’s open-source software for seismic risk assessment

2.3 Rupture model

The NRML schema allows the definition of a rupture model, which is a key input for

scenario risk and damage analysis. Together with an ID, name and description, a rupture is

specified by a magnitude and a geometry which can be described using the following

options:

• Point rupture (described by a focal mechanism and hypocentre location);

• Simple (geometry) fault rupture (described by a rake angle and simple fault geometrical

attributes, see Fig. 2);

• Complex (geometry) fault rupture (described by a rake angle and complex fault

geometrical attributes);

The above options offer a wide range of possibilities for rupture modelling. For

instance, a point rupture can be used if the ground-motion modelling is performed by

means of a ground-motion prediction equation (GMPE) that adopts hypocentral distance as

the distance metric. The three extended rupture options can be used depending on the level

of knowledge of the fault surface geometry, ranging from basic to very detailed.

2.4 Physical vulnerability model

Physical, or structural, vulnerability is defined as the probability distribution of a loss ratio,

given an intensity measure level. In the current version of the OpenQuake engine (or, more

precisely, its risk library: ‘oq-risklib’), discrete vulnerability functions are used to directly

model losses which might, for example, be fatalities or repair costs, where the loss ratio for

the former would be the ratio of fatalities to exposed population, and for the latter the ratio

would be that of cost of repair to cost of replacement for a given building typology.

Discrete vulnerability functions are described by a list of intensity measure levels and

corresponding mean loss ratio, associated coefficient of variation and probability distri-

bution. Currently, only structure-independent intensity measure levels are supported, such

as peak ground acceleration, peak ground velocity or spectral acceleration at a fixed period

Fig. 2 Simple rupture trace, with rake of 0� and dip of 90�

Nat Hazards

123

Page 7: Development of the OpenQuake engine, the Global Earthquake Model’s open-source software for seismic risk assessment

of vibration. The uncertainty in the loss ratio can be modelled with either a lognormal or a

beta distribution. Figure 3 presents an example of a discrete vulnerability function, com-

patible for use with the OpenQuake engine.

2.5 Fragility model

Fragility is defined as the probability of exceeding a set of limit states, given a range of

intensity measure levels. A fragility model can currently be defined in two manners:

following a discrete approach, in which a list of probabilities of exceedance per limit state

are provided for a set of intensity measure levels or, alternatively, by means of modelling

each limit state curve as a cumulative lognormal function, represented by a mean and

standard deviation, as illustrated in Fig. 4. The OpenQuake engine can accept fragility

models which use any number or nomenclature for the set of limit states.

2.6 Exposure model

The exposure model contains the information regarding the assets within the region of

interest, where the term asset is used to define something of value. A number of parameters

are required to define the characteristics of each asset, such as the taxonomy that allows the

engine to relate the asset with the appropriate vulnerability function, the value of the asset

and the geographic coordinates that will allow the calculators to relate the asset with the

respective seismic hazard. Taxonomy is a classification scheme and is of particular use for

buildings, which can have very different attributes (such as material, height, age) that need

to be documented. The user can apply any taxonomy, which might be the recently pro-

posed GEM Basic Building Taxonomy V0.2 (http://www.nexus.globalquakemodel.org/

gem-building-taxonomy/posts) or the HAZUS taxonomy (FEMA 2003), as long as the

same taxonomy is used for both the exposure and vulnerability models. Uncertainty in the

exposure model is not currently incorporated, but will be considered in future develop-

ment; furthermore, the extension of the logic tree to consider different exposure (and

vulnerability) models will also be undertaken.

3 OpenQuake engine calculation workflows

The OpenQuake engine currently comprises five risk calculation workflows: two that

compute losses and damage distributions due to a single event, another two that compute

Intensity Measure level - PGA (g)

0

0.2

0.4

0.6

0.8

1

Loss

rat

io

0 0.1 0.2 0.3 0.4 0.5 0.6 0.7

Fig. 3 Illustration of a discretevulnerability function

Nat Hazards

123

Page 8: Development of the OpenQuake engine, the Global Earthquake Model’s open-source software for seismic risk assessment

seismic risk due to a probabilistic description of the events and associated ground motions

that might occur in a given region within a certain time span, and a last one that uses

probabilistic modelling of losses to assess whether retrofitting measures would be eco-

nomically viable or not. Despite the fact that GEM is working closely with many regions in

the world to develop seismic hazard models, to collect information about the local building

typologies and to propose guidelines to estimate vulnerability and fragility models, it is

emphasized here that no data are currently provided with the OpenQuake engine. Instead,

users should provided their own models, defined according to the NRML format described

in the previous section. A comprehensive description of the methodologies included in the

engine can be found in the OpenQuake Book (GEM 2012b), whilst in the following

sections, a brief description of the properties characterizing each risk calculation meth-

odology is provided.

3.1 Scenario risk calculation workflow

This calculation workflow is capable of computing losses and loss statistics due to a single

event, for a collection of assets. The hazard input consists of a finite rupture and a single

GMPE. By repeating the same rupture, and sampling the inter- and intra-event variability

from the GMPE each time, many ground-motion fields can be computed to account for the

aleatory variability in the ground motion. During the generation of each ground-motion

field, the spatial correlation of the intra-event variability can be considered, to ensure assets

located close to each other will have similar ground-motion levels (see e.g. Crowley et al.

2008 for a summary of ground-motion variability treatment in loss models).

The set of ground-motion fields is then provided to the Scenario Risk calculator,

together with the vulnerability and exposure models, to compute the losses for each asset in

the exposure model, per ground-motion field. The correlation in the uncertainty in the

vulnerability functions is incorporated such that when sampling the uncertainty in the

vulnerability of two assets with the same taxonomy (i.e. of a given building typology), the

residuals can be uncorrelated or perfectly correlated. This modelling feature aims to model

the fact that buildings within a given region are likely to have been constructed with

similar materials and with similar construction techniques, and thus their behaviour will be

correlated, though not necessarily perfectly correlated.

Fig. 4 Continuous (left) and discrete (right) fragility models

Nat Hazards

123

Page 9: Development of the OpenQuake engine, the Global Earthquake Model’s open-source software for seismic risk assessment

The mean or median value of losses across all ground-motions fields can be found for a

given asset, and the spatial variation of this loss metric for a given asset typology can be

plotted in a loss map (see Sect. 4.2). The losses to all assets across the region of interest can

also be aggregated per ground-motion field, to obtain a list of aggregated losses, from

which the mean and standard deviation can then be calculated. Furthermore, confidence

intervals can be estimated from these statistics, as some users (perhaps without a scientific

background) might be more familiar with the concept of a range of values for a given level

of confidence, rather than the mean and standard deviation.

This calculation type was found in many of the codes reviewed in GEM1, but the robust

modelling of uncertainty and its correlation (in the ground-motion residuals and the vul-

nerability uncertainty) seemed to be missing in such software. In Fig. 5, the workflow of

this calculator is illustrated.

3.2 Scenario damage calculation workflow

This calculation workflow serves the purposes of estimating the distribution of damage due

to a single scenario earthquake, for a spatially distributed building portfolio. As with the

previous workflow, a finite rupture definition needs to be provided, along with the selected

GMPE. A set of ground-motion fields is computed, with the possibility of considering the

spatial correlation of the ground-motion residuals. Then, the Scenario Damage Distribution

calculator computes for each asset the fraction of buildings in each damage state using the

fragility models. This percentage of buildings in each damage state is calculated based on

the difference in probabilities of exceedance between consecutive limit state curves at a

given intensity measure level. By repeating this process for each ground-motion field, a list

of fractions (one per damage state) for each asset is obtained. The damage distribution

output is comprised by the mean and standard deviation of this list of fractions for each

asset. By multiplying the number or area of buildings by the respective fractions, the

absolute building damage distribution is attained. Again, confidence intervals can be

Finite Rupture Definition

Ground Motion Field Calculator

Scenario Risk Calculator

Ground Motion Fields Vulnerability Model Exposure Model

Loss Maps Loss Statistics

Data

Calculator

Fig. 5 Workflow of scenario risk assessment

Nat Hazards

123

Page 10: Development of the OpenQuake engine, the Global Earthquake Model’s open-source software for seismic risk assessment

extracted using the mean and standard deviation. Finally, the Scenario Damage Distribu-

tion calculator also uses the amount of buildings in the last damage state (commonly the

collapse damage state) to output collapse maps (i.e. a spatial distribution of the number or

area of collapsed buildings) (see Sect. 4.3). This calculator workflow is presented in Fig. 6.

3.3 Probabilistic Event-based Risk Calculation Workflow

This calculation workflow computes the probability of losses for a set of assets, based on

probabilistic hazard, with an event-based approach, such that the simultaneous losses to a

set of assets can be calculated per event. This workflow requires a number of calculators in

order to derive the ground-motion fields to be input into the risk calculators. Firstly, a

Logic Tree Processor calculator uses information contained within the seismic source

system together with a Monte Carlo approach to sample the logic tree structure and

produce a seismic source model (SSM). Each seismic source model computed is used by

the Earthquake Rupture Forecast (ERF) calculator to produce a list of all the possible

ruptures occurring on all the sources in the SSM; each rupture is associated with a

probability of occurrence in the time span specified by the user in the configuration file.

Then, the Stochastic Event Set calculator uses the ERF to create one or several groups of

ruptures. The generation of the stochastic event set is based on an original methodology,

though it has many similarities with other Monte Carlo-based methodologies (e.g. Musson

2000). Each group represents a possible realization of the seismicity generated in the

specified time span by the entire set of seismic sources included in the seismic source

model.

Afterwards, the Logic Tree Processor is again used to process the GMPEs system and

provide the ground-motion relationship that shall be used by the Ground-Motion Field

calculator, together with each earthquake rupture, to compute the ground-motion values at

a set of sites. The spatial correlation of the intra-event residuals of the ground-motion

model can also be considered. As mentioned previously, in that case, sites that are closer

Finite Rupture Definition

Ground Motion Field Calculator

Scenario Damage Distribution Calculator

Ground Motion Fields Fragility Model Exposure Model

Damage Distribution Collapse Maps

Data

Calculator

Fig. 6 Workflow of the scenario damage assessment

Nat Hazards

123

Page 11: Development of the OpenQuake engine, the Global Earthquake Model’s open-source software for seismic risk assessment

are more likely to have similar levels of ground motion. This set of ground-motion fields is

combined with the exposure and vulnerability model (again with the possibility to model

the correlation of the uncertainty in the vulnerability) in the Probabilistic Event-based Risk

calculator, to compute the losses for each asset per ground-motion field. The list of losses

per asset can be sorted from the largest to the smallest, and the number of times each loss is

exceeded over the total length of the catalogue is calculated to give the annual frequency of

exceedance, and then by assuming a Poisson model, a loss exceedance curve can be

computed (loss versus probability of exceedance in a given time span) (see Sect. 4.2). The

workflow in Fig. 7 describes this procedure.

This calculation type was found to be in only a few of the codes reviewed in GEM1

(SELENA, EQRM), and those where it was present did not include a robust modelling of

uncertainly and its correlation (in both the ground-motion residuals and the vulnerability

uncertainty).

3.4 Classical PSHA-based risk calculation workflow

This workflow has an initial architecture similar to the Probabilistic Event-based Risk

workflow, in which a Logic Tree Processor uses the structure defined in the Seismic Source

System to provide the required parameters to the ERF calculator, which produces a list of

all the possible ruptures occurring on all the sources included in the seismic hazard model.

Earthquake Rupture

Forecast Calculator

Stochastic Event Set

Generator

Stochastic Event Set

Ground Motion Field

Calculator

Probabilistic Event-

based Risk Calculator

Ground Motion FieldsVulnerability Model Exposure Model

Loss Curves Loss Maps

Data

Calculator

Source Model

Earthquake Rupture

Forecast GMPE

Logic Tree Processor

Seismic Hazard ModelSource model logic tree

GMPE logic tree

Earthquake Rupture

Forecast CalculatorGMPE

Logic Tree Processor

Data

Calculator

Source Model

Earthquake Rupture

Forecast

Classical PSHA-based

Risk Calculator

Hazard CurvesVulnerability Model Exposure Model

Loss Curves Loss Maps

Classical Hazard

Curves CalculatorHazard Maps

Seismic Hazard ModelSource model logic tree

GMPE logic tree

Fig. 7 Workflow of the Probabilistic Event-based Risk workflow (left) and Classical PSHA-based Riskworkflow (right)

Nat Hazards

123

Page 12: Development of the OpenQuake engine, the Global Earthquake Model’s open-source software for seismic risk assessment

Then, using the GMPEs system, the Logic Tree Processor provides the GMPEs that the

Classical Hazard Curves calculator will use. This calculator uses the classical PSHA

approach (Cornell 1968; McGuire 2004) following the methodology presented by Field et al.

(2003) to compute a hazard curve at each site. This set of hazard curves is then provided,

together with the vulnerability and exposure model, to the Classical PSHA-based Risk cal-

culator. The first step in the algorithm for this calculator is to convert each discrete vulner-

ability function into a loss ratio exceedance matrix (e.g. a matrix which describes the

probability of exceedance of each loss ratio for a discrete set of intensity measure levels).

Once these matrices are built, the values of each column are multiplied by the probability of

occurrence of the associated intensity measure level. This probability is obtained by math-

ematically differentiating the previously computed hazard curves. Finally, the list of prob-

abilities of exceedance of the loss ratio curve is obtained by summing all the values per loss

ratio. This loss ratio curve is then converted into a loss curve by multiplying each loss ratio by

the associated asset value. The workflow in Fig. 7 describes the architecture of this calculator.

Some of the software reviewed in GEM1 featured risk calculations based on hazard

maps (for a single return period), but only one software (OpenRisk) explicitly used hazard

curves with the method outlined herein (which ensures that the uncertainty in the vul-

nerability model is accounted for when estimating the probability of loss exceedance).

3.5 Retrofitting benefit–cost ratio calculation workflow

This calculation sequence provides a decision-support tool for deciding whether the

employment of retrofitting/strengthening measures to a collection of existing buildings is

advantageous from an economical point of view. This workflow uses loss exceedance

curves that can be computed using either the Probabilistic Event-based Risk or the Clas-

sical PSHA-based Risk workflow. Two sets of loss curves need to be calculated: the first

considering the original asset vulnerability, and the second one using the retrofitted vul-

nerability configuration. Then, the annual average loss (AAL) is estimated for each con-

figuration, by summing the product of each loss with the corresponding probability of

occurrence, extracted from the loss curves. The associated economic benefit is computed

using the AAL for both configurations, according to the following formula:

Benefit ¼ ðAALretroffited � AALoriginalÞ �ð1� ertÞ

rð1Þ

where t stands for the life expectancy of the building stock and r represents the discount

interest rate. The latter parameter serves the purpose of taking into account the variation of

building value throughout time. Thus, a rate close to zero signifies that no changes in the

building stock value are expected, whilst a positive discount rate indicates that each year

the economic value is reduced according to the associated rate. The final ratio is computed

by dividing the aforementioned benefit by the cost of retrofitting. The output of this

calculator is a spatial distribution of benefit/cost ratios, which if found to be higher than

1.0, indicate that employing a retrofitting intervention is economically viable. Figure 8

presents this calculator workflow.

4 OpenQuake engine output data

The Natural hazards Risk Markup Language (NRML) introduced previously for the input

data is also used for the OpenQuake engine output data, which currently include hazard

Nat Hazards

123

Page 13: Development of the OpenQuake engine, the Global Earthquake Model’s open-source software for seismic risk assessment

curves, hazard maps, ground-motion fields, loss curves and loss maps, and damage dis-

tributions, which are described in the following.

4.1 Hazard curves, hazard maps and ground-motion fields

The hazard outputs that can be produced as intermediate products of the Classical PSHA-

based Risk workflow presented in the previous chapter are hazard curves and hazard maps.

If the PSHA input model contains a logic tree structure for both seismic sources and

GMPEs, the OpenQuake engine generates several results, each one corresponding to a

specific realization of the logic tree structure (i.e. a single seismic source model and a set of

GMPEs—one for each tectonic region). The NRML schema allows the representation of

results referring to a single realization (i.e. a hazard map or curve computed with a given

seismic source model and set of GMPEs) as well as of results summarizing the entire set

produced, that is, results giving a description of the variability due to epistemic uncer-

tainty. In Fig. 9, a hazard map produced for Turkey using the OpenQuake engine is

illustrated.

Scenario hazard analysis produces sets of ground-motion fields, which can then be used

for risk calculations. The median ground-motion field or each of the randomly simulated

fields with modelled spatial correlation of the ground-motion residuals (Jayaram and Baker

2009) can be output (Fig. 10).

4.2 Loss maps and loss exceedance curves

Loss maps are composed of a set of ‘‘loss nodes’’, which are associated with a pair of

coordinates. For each node, one or more loss values might exist, due to the fact that several

different assets can be located at the same location. A probability of exceedance and time

span are also attributes of loss maps, if they contain results from a probabilistic risk

assessment (Classical PSHA-based or Probabilistic Event-based) rather than from a

Loss curves (original and retrofitted)

Benefit/Cost Ratio

Calculator

Seismic Hazard Vulnerability Model

(original and retrofitted) Exposure Model

Data

Calculator

Probabilistic Event-

based Risk Calculator

Classical PSHA-based

Risk Calculator

Benefit/Cost Ratio

Distribution

or

Fig. 8 Workflow of the benefit/cost ratio calculator

Nat Hazards

123

Page 14: Development of the OpenQuake engine, the Global Earthquake Model’s open-source software for seismic risk assessment

scenario risk assessment. Loss exceedance curves can be produced in the OpenQuake

engine through probabilistic risk assessment and are represented by a list of losses and their

respective probabilities of exceedance.

Loss exceedance curves can be produced separately for each asset within the exposure

model, or in the case of the Probabilistic Event-based Risk workflow, for all the assets

within the exposure model. In the latter case, all the losses throughout the region per

ground-motion field are summed and a total loss curve is obtained. The loss exceedance

Fig. 9 Example of PGA hazard map for a probability of exceedance of 10 % in 50 years for Turkey

Fig. 10 Median ground-motion field (left) and one of a set of randomly sampled ground-motion fields withmodelled spatial correlation of ground-motion residuals (right), using peak ground acceleration (g)

Nat Hazards

123

Page 15: Development of the OpenQuake engine, the Global Earthquake Model’s open-source software for seismic risk assessment

curves produced using the Probabilistic Event-based and the Classical PSHA-based

workflows can also be used to create loss maps representing the distribution of the mean

loss per location for a certain probability of exceedance within a given time span. Fur-

thermore, mean losses within the given time span (e.g. average annual loss) can also be

extracted by integrating the loss exceedance curves.

Example loss maps produced using OpenQuake and presenting the expected economic

losses for the Metropolitan Area of Istanbul from the Classical PSHA-based Risk workflow

are presented in Fig. 11, whilst loss exceedance curves with and without ground motion

and vulnerability uncertainty correlation (from the Probabilistic Event-based Risk work-

flow) are illustrated in Fig. 12.

4.3 Damage distribution and collapse maps

As discussed in Sect. 3.2, the OpenQuake engine is capable of estimating the distribution

of buildings in each damage state (according to a fragility model), due to the occurrence of

a single seismic event. The damage distribution output is comprised of a set of ‘‘damage

nodes’’ (defined by a pair of coordinates) for which the amount (number or area) of

buildings in each damage state is described. Currently, the OpenQuake engine can also

provide a damage distribution per building typology (amount of buildings in each damage

state within the same building class) or the total damage distribution (sum of all the

buildings in each damage state). Using the distribution of buildings in the last damage state

(usually defined as collapse or total destruction), collapse maps can be extracted (see

Fig. 13). In this output, the spatial distribution of the number of collapsed buildings is

provided.

4.4 Retrofitting benefit–cost ratio maps

A retrofitting benefit–cost ratio for a given building typology at each site in the exposure

model can be produced, as illustrated in Fig. 14. As mentioned previously, for values over

1.0, the retrofitting of buildings is estimated to be economically beneficial.

Fig. 11 Example of loss map with a probability of exceedance of 10 % (left) and 1 % (right) in 50 years

Nat Hazards

123

Page 16: Development of the OpenQuake engine, the Global Earthquake Model’s open-source software for seismic risk assessment

5 Conclusions

In this paper, an open-source software capable of computing seismic hazard and risk was

presented, with focus given to the risk component. At present, the OpenQuake engine is

comprised of five main calculation workflows: two capable of computing loss and damage

0.01

0.1

1

Pro

babi

lity

ofex

ceed

ance

in10

year

s

Aggregated Economic Losses

Type A

B

C

low highmedium

Type

Type

Fig. 12 Example of total economic loss exceedance curves for a portfolio of assets without ground motionand vulnerability uncertainty correlation (Type A), with just ground-motion correlation (Type B) and withboth uncertainty correlations modelled (Type C)

Fig. 13 Example of collapse map showing number of collapsed buildings in each grid cell for themetropolitan area of Istanbul

Nat Hazards

123

Page 17: Development of the OpenQuake engine, the Global Earthquake Model’s open-source software for seismic risk assessment

distribution due to single events, two with the purpose of estimating probabilistic seismic

risk considering a probabilistic description of the events and associated ground motions

that might occur in a given region within a certain time span, and a last one that uses loss

exceedance curves to carry out retrofitting benefit–cost analysis. The various outputs can

be used to carry out seismic risk reduction or mitigation measures, such as post-earthquake

emergency management planning or identification of the regions with higher seismic risk

within a certain country, where risk mitigation efforts should be prioritized.

Several other functionalities are planned for the future development of the OpenQuake

engine and its scientific libraries, such as the possibility to use structure-dependent

intensity measures, the disaggregation of losses, the employment of Nonlinear Static

Procedure-based methodologies for the estimation of building response, which can be

related to damage distributions [e.g.: N2 method (Fajfar 1999) or Capacity Spectrum

Method (Freeman 2004)] or the consideration of other elements such as networks or

infrastructures.

Due to its transparent, modular and test-driven development philosophy, the develop-

ment of the OpenQuake engine, and in particular its two Python libraries, will continue to

be a community effort where anyone can contribute with their own methods and formulae.

This differs from traditional practice, where a closed ‘‘enterprise’’ development tends to be

followed, even if the source code is eventually openly released at the end of the devel-

opment process.

The OpenQuake engine is being tested by several institutions and research projects in

the world for the calculation of seismic hazard and risk (such as the calculation of hazard

for Europe in the European Commission-funded SHARE project, www.share-eu.org),

which is helping the development team to better understand the regional requirements, and

to improve and extend the development plan accordingly.

Fig. 14 Example of retrofitting cost–benefit ratio map for a reinforced concrete building typology

Nat Hazards

123

Page 18: Development of the OpenQuake engine, the Global Earthquake Model’s open-source software for seismic risk assessment

Acknowledgments The authors would like to acknowledge the significant contribution of Joshua McK-enty in the design of the architecture of the OpenQuake engine, and for strictly instilling open-sourcepractices within the development team. Discussions with a number of individuals (Keith Porter, MarioOrdaz, Paolo Bazzurro, Nico Luco) have also been central to the development of many of the features of theOpenQuake engine’s scientific libraries. The authors would also like to thank Graeme Weatherill and PaulHenshaw for their advice during the drafting of the manuscript and support in the various calculations.

References

Bommer JJ, Scherbaum F (2008) The use and misuse of logic-trees in probabilistic seismic hazard analysis.Earthquake Spectra 24(4):997–1009

Cornell CA (1968) Engineering seismic risk analysis. Bull Seismol Soc Am 58:1583–1606Crowley H, Bommer JJ, Stafford PJ (2008) Recent developments in the treatment of ground-motion vari-

ability in earthquake loss models. J Earthquake Eng 12(1):71–80Crowley H, Colombi M, Crempien J, Erduran E, Lopez M, Liu H, Mayfield M, Milanesi M (2010) GEM1

seismic risk report: part 1, GEM technical report 2010–5. GEM Foundation, PaviaDanciu L, Monelli D, Pagani M, Wiemer S (2010) GEM1 hazard: review of PSHA software, GEM technical

report 2010–2. GEM Foundation, PaviaFajfar P (1999) Capacity spectrum method based on inelastic demand spectra. Earthquake Eng Struct Dyn

28(9):979–993FEMA (2003) HAZUS-MH technical manual. Federal Emergency Management Agency, Washington DCField EH, Jordan TH, Cornell CA (2003) OpenSHA: a developing community-modeling environment for

seismic hazard analysis. Seismol Res Lett 74:406–419Freeman S (2004) Review of the development of the capacity spectrum method. ISET J Earthquake Tech

41:1–13GEM (2012a) OpenQuake manual. Available from http://www.globalquakemodel.org/openquake/support/

documentation/GEM (2012b) OpenQuake book. Available from http://www.globalquakemodel.org/openquake/support/

documentation/Giardini D (1999) The global seismic hazard assessment program (GSHAP) 1992–1999. Ann Geofis

42(6):957–1230 (Summary Volume)Jayaram N, Baker JW (2009) Correlation model for spatially distributed ground-motion intensities. Earth-

quake Eng Struct Dyn 38(15):1687–1708McGuire RR (2004) Seismic hazard and risk analysis. Earthquake Engineering Research Institute publi-

cation no. MNO-10, second monograph seriesMusson RM (2000) The use of Monte Carlo simulations for seismic hazard assessment in the UK. Anna

Geofis 43(1)Pagani M, Danciu L, Monelli D, Wossner J, Wiemer S, Field EH (2010a) Toward a unified PSHA input data

model and code: a proposal based on the GEM1 experience. In: Proceedings of the 14th Europeanconference of earthquake engineering, Ohrid, Macedonia

Pagani M, Monelli D, Crowley H, Danciu L, Field EH, Wiemer S, Giardini D (2010b) GEM1 hazard:description of input models, calculation engine and main results. GEM technical report 2010-3. GEMFoundation, Pavia, Italy

Petersen MD, Frankel AD, Harmsen SC, Mueller CS, Haller KM,Wheeler RL, Wesson RL, Zeng Y, BoydOS, Perkins DM, Luco N, Field EH, Wills CJ, Rukstales KS (2008) Documentation for the 2008 updateof the United States national seismic hazard maps: U.S. geological survey open-file report 2008–1128,p 61

Pinho R (2012) GEM: a participatory framework for open, state-of-the-art models and tools for earthquakerisk assessment worldwide. In: Proceedings of the 15th world conference on earthquake engineering,Lisbon, Portugal

Thomas P, Wong I, Abrahamson N (2010) Verification of probabilistic seismic hazard analysis computerprograms. PEER report 2010/106, Pacific Earthquake Engineering Research Center, University ofCalifornia, Berkeley, 176 p

Web references

OpenQuake website—http://www.globalquakemodel.org/openquake/Global earthquake model—http://www.globalquakemodel.org

Nat Hazards

123

Page 19: Development of the OpenQuake engine, the Global Earthquake Model’s open-source software for seismic risk assessment

SELENA—http://www.norsar.no/pc-35-68-SELENA.aspx—developed by the Norwegian seismic array(NORSAR) in Kjeller, Norway

EQRM—http://www.ga.gov.au/hazards/earthquakes.html—developed by the Geoscience Australia (GA) inCanberra, Australia

ELER—http://www.koeri.boun.edu.tr/depremmuh/eski—developed by the Kandilli Observatory andEarthquake Research Institute (KOERI) in Istanbul, Turkey

QLARM—http://www.wapmerr.org/qlarm.asp—developed by the World Agency of Planetary Monitoringand Earthquake Risk Reduction (WAPMERR) in Geneva, Switzerland

CEDIM—http://www.cedim.de—developed by the Center for Disaster Management and Risk ReductionTechnology (CEDIM) in Potsdam, Germany

CAPRA—http://www.ecapra.org/software—Central America Probabilistic Risk Analysis, an initiative fromthe World Bank

RiskScape—http://www.riskscape.org.nz—developed by the Geological and Nuclear Sciences (GNS) inLower Hutt, New Zealand

LNECLoss—http://www-ext.lnec.pt/LNEC/DE/NESDE—developed by the Laboratorio Nacional deEngenharia Civil (LNEC) in Lisbon, Portugal

MAEviz—http://rcp.ncsa.uiuc.edu/maeviz/about.html—developed by the Mid-America Earthquake Center(MAE Center) in Illinois, USA

OpenRisk—http://www.risk-agora.org—developed by the Scawthorn, Porter and Associates (SPA Risk)Celery project—http://celeryproject.orgRabbitMQ project—http://www.rabbitmq.comOpenQuake engine repository—https://github.com/gem/oq-engineNRML repository https://github.com/gem/nrmlGEM Nexus—http://www.nexus.globalquakemodel.org/gem-building-taxonomy/posts

Nat Hazards

123