ByMuR implementation overview

Figure 1: ByMuR software architecture overview

ByMuR software aims to manage and visualize multi-risk results and its input data through an easy-to-use GUI. To facilitate the development of a complete graphical tool, without sacrificing any requested feature and maintaining a reasonable complexity, Python has been chosen as main programming language. Main Python's modules used in ByMuR are:

wxPtyhon6
a cross-platform GUI toolkit that allows to create applications that can run unmodified on different platform like MS Widows, OS X, GNU/Linux and most Unix-like systems;
MySQLdb7
a Python DB API-2.0-compliant interface to MySQL databases;
Numpy8
a scientific library for high level mathematical operations with large arrays, linear algebra and random numbers;
Matplotlib9
a Python 2D plotting library which can be integrated in wxPython toolkit to build accurate and interactive plots;
lxml
10 a XML toolkit providing a Pythonic binding for the C libraries libxml2 and libxslt. Its interface is compatible with the ElementTree API but it is faster, especially in serialisation.
Figure 2: ByMuR-DB SQL schema

ByMuR data is managed through MySQL11, one of the most used relational databases management systems (RDBMS). ByMuR-DB is a database model specifically designed to store and properly organize all the data required to perform a multi-risk analysis in tables which are connected each other with well defined relations (See Figure 2). ByMuR-DB has been realized to be also compatible with existing databases developed to store volcanological data as DIVO Selva et al. (2009) and WOVOdat Ratdomopurbo et al., (2013).

ByMuR-DB contains all the data relating to inventory assets, areas definition, reference grids and point’s coordinates, which, in turn, will be referenced by the models data entries to avoid unfavourable replications.

Four kind of data models are stored in the database: hazard, fragility, loss and risk. All the data and the corresponding uncertainties are also stored in dedicated tables and their referential integrity is ensured by the use of primary and foreign keys constraints provided by MySQL. The file format specifications used to exchange data are thoroughly explained in the following section. This XML-based format is used to feed models and data to the ByMuR procedures without the need of any SQL syntax knowledge to import data in ByMuR-DB.

References

Ratdomopurbo et al., (2013)
Ratdomopurbo A., Widiwijayanti C., Newhall C., Win N.T.Z. (2013), WOVOdat Database: Progress Report 2013, IAVCEI 2013 Scientific Assembly - July 20 - 24, Kagoshima, Japan.
Selva et al. (2009)
Selva J., Doumaz F., Reitano D., Troiano A., Vinci S., and the DIVO Consortium (2009), DIVO Database for Italian VOlcanoes, AGU Fall Meeting, 14-18/12/2009 San Francisco (USA) WOVOdat database, www.wovodat.org

6
http://www.wxpython.org
7
http://mysql-python.sourceforge.net
8
http://www.numpy.org
9
http://www.matplotlib.org
10
http://lxml.de/
11
http://www.mysql.com
12
https://wiki.python.org/moin/Generators
13
http://www.globalquakemodel.org