Skip to content
An OpenQuake implementation of the probabilistic seismic hazard analysis of Nath & Thingbaijam (2012)
Jupyter Notebook TeX Python
Branch: master
Clone or download

Latest commit

Fetching latest commit…
Cannot retrieve the latest commit at this time.

Files

Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
Catalogue
Data
GMPEs
Jobs
Logic Trees
Maps
Report
Results
Sites
Smoothed
Source Models
utilities
.gitignore
LICENSE.md
README.md
VersionNotes.txt
oq.yml
oq36.yml
recreate_symlinks.py
simple_calculations.py

README.md

Indian Subcontinent PSHA

This is an implementation in OpenQuake of the probabilistic seismic hazard analysis (PSHA) model of Nath & Thingbaijam (2012).

Versions

Files specific to the first version of the model are subscripted _v0. This model is described in the report by Ackerley (2016).

A revised version, subscripted _v1 and incorporating clarifications from the authors of Nath & Thingbaijam (2012), was included in the initial release of the Global Seismic Seismic Hazard Map, v. 2018.1.

Work is in progress to develop a _v2 model to address outstanding issues.

Zipped job files can be downloaded for various releases.

Installation

Smoothed-gridded model files in Natural hazards’ Risk Markup Language (NRML) format are too big to fit in a github repository but they can be regenerated from smaller input data files and scripts, all included in the repository.

The OpenQuake NRML .xml model files are generated from .csv (source model) and .tsv (logic tree) files using scripts that depend on the OpenQuake Hazard Modeler's Toolikt (HMTK). This is done using python .py and Jupyter Notebook scripts in .ipynb format.

Prerequisites

Ensure that the prerequisites are installed:

  • OpenQuake (2.6 or newer): oq-engine
  • Jupyter Notebook and python environment management: Anaconda
  • lualatex (optional, for conversion of NRML logic trees to PDF): TexLive

Repository

Clone the repository:

cd ~/src
git clone https://github.com/nackerley/indian-subcontinent-psha.git

Create environment

Create an environment with the necessary python packages:

cd ~/src/indian-subcontinent-psha
conda env create --file oq.yml
source activate oq

Make the (oq) kernel accessible to jupyter in the root environment by running the following:

source activate oq
python -m ipykernel install --user --name oq

To open jupyter notebooks which use this environment, run the following in your root environment:

jupyter notebook

and select the appropriate files from the browser window which opens.

Add utilities to Python path

Add ~/src/indian-subcontinent-psha/utilities to your Python path. One way is to append the following to your ~/.bashrc:

export PYTHONPATH=$PYTHONPATH:~/src/indian-subcontinent-psha/utilities

Verify installation

Verify your installation by trying:

import source_model_tools as smt

Usage

Regenerate logic trees

To regenerate the logic tree XML, open and run the following jupyter notebook:

  • "Logic Trees/logic_trees_nt2012.ipynb"

Note that the logic tree model XML files are small, and already included in the repository, so this is only necessary if changes are made to logic tree TSV description files.

Regenerate source models

To regenerate the source model XML, in your (oq) environment run:

cd ~/src/indian-subcontinent-psha/Source\ Models/
python write_source_models_nt2012.py --version VERSION --full

The smooothed-gridded models in particualr are large, so only "thinned" versions are included in the repository for quality control purposes. The version number only refers to the major version. Without the --full argument only a "thinned" version of the smoothed-gridded model is generated; this is quicker and useful for testing.

Investigate source models

The following jupyter notebooks are useful for investigating and visualizing the source models:

  • "Source Models/areal_source_models_nt2012.ipynb"
  • "Source Models/smoothed_source_models_nt2012.ipynb"
  • "Source Models/collapsed_source_models_nt2012.ipynb"

Jobs

Job configuration job.ini files are created manually rather than automatically generated. Symbolic links to data files are include in each folder, to avoid duplication of files.

The key job variants supported are:

  • Jobs/cities_collapsed_v0/
  • Jobs/cities_collapsed_v1/
  • Jobs/cities_full_disaggregation_v1/
  • Jobs/map_collapsed_v1/

Note:

  • collapsed vs. full refers to whether or not frequency-magnitude distributions were collapsed prior to hazard calculation. collapsed source models will give correct results for mean hazard but not for hazard quantiles or deaggregation.
  • cities jobs are site-specific analyses, for the 18 cities listed in Table 3 of Nath & Thingbaijam (2012).
  • map refers to the 0.2° grid of 8102 points used to generate the data in the Figure 7 and the electronic supplement of Nath & Thingbaijam (2012).

The script tar_all.py in Jobs zipped versions of all jobs found in subdirectories.

Mapping

Files for generating maps using QGIS are stored at Maps/. Maps incorporate data which can be downloaded separately from:

Data

This project draws heavily on published work. Portions of some of these publications are included in this repository.

Hazard model development

This model incorporates data from the following publications:

Ground motion prediction equation (GMPE) development

A set of jupyter notebooks in ~/src/indian-subcontinent-psha/GMPEs were used to generate validation data for the following modules of openquake.hazardlib.gsim:

Development

Pull requests are welcome (though not expected, given the nature of the repository).

Useful tools for development:

License

The Indian Subcontinent PSHA model is released under the GNU Affero Public License 3.

Contact

Thanks

You can’t perform that action at this time.