Source code for openquake.mbi.cat.MFDs_sample_mag_sigma

# ------------------- The OpenQuake Model Building Toolkit --------------------
# Copyright (C) 2022 GEM Foundation
#           _______  _______        __   __  _______  _______  ___   _
#          |       ||       |      |  |_|  ||  _    ||       ||   | | |
#          |   _   ||   _   | ____ |       || |_|   ||_     _||   |_| |
#          |  | |  ||  | |  ||____||       ||       |  |   |  |      _|
#          |  |_|  ||  |_|  |      |       ||  _   |   |   |  |     |_
#          |       ||      |       | ||_|| || |_|   |  |   |  |    _  |
#          |_______||____||_|      |_|   |_||_______|  |___|  |___| |_|
#
# 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/>.
# -----------------------------------------------------------------------------
# vim: tabstop=4 shiftwidth=4 softtabstop=4
# coding: utf-8

import toml
import numpy as np
from openquake.baselib import sap

from openquake.mbt.tools.mfd_sample.make_mfds import make_many_mfds


[docs] def main(fname_config): """ Runs the workflow that samples the magnitude sigma for each event, creating many catalogues, then declusters them all based on their TRT, then runs completeness analysis that jointly solves for the MFD, and finally returns three mfds based on the center and 1-sigma of the a-b covariance """ make_many_mfds(fname_config)
msg = 'Name of the .toml file with configuration parameters' main.fname_config = msg if __name__ == '__main__': sap.run(main)