Coseis is an open-source toolkit for earthquake simulation featuring:
The primary interface is through a Python module which (for high-performance components) wraps Fortran parallelized with hybrid OpenMP and MPI.
Coseis is written by Geoffrey Ely with contributions from Steven Day, Bernard Minster, Feng Wang, Zheqiang Shi, and Jun Zhou. It is licensed under BSD terms.
WARNING: Coseis is a research code under active development. Changes are frequent and it has known bugs!
If on Mac OS X, first install Xcode from the App Store. From the Xcode preferences pane, install the Command Line Tools. Then install Homebrew, followed by Git and Fortran with:
brew install git gfortran
OpenMP is broken in GCC 4.3 on Lion, so if you need multiprocessing speed-up, install either MPICH or a newer GCC version. Optionally, install and EPD for visualization and analysis.
Clone the source code from the Coseis GitHub repository:
git clone git://github.com/gely/coseis.git
Set path variables for the Python module and executables. For bash shell, with the code located in your home directory (for example) add these lines to .bash_profile:
export PYTHONPATH="$HOME/coseis" export PATH="$PATH:$HOME/coseis/bin"
Run the setup.py script to test your configuration. This will display all of the configuration parameters:
python setup.py
These parameters may be customized by creating a file cst/conf/site.py. For example, the account for billing of service units, and email address for notifications may be specified in site.py module with:
account = 'your_project_name_here' email = 'your.email@address.here'
To run the test suite interactively:
cd cst/tests python test_runner.py -i
Or, submit a job for batch processing:
python test_runner.py -q
After completion, a report is printed to the screen (or saved in run/test_suite/test_suite.output):
PASSED: doctest.testmod(cst.util) PASSED: doctest.testmod(cst.coord) PASSED: doctest.testmod(cst.sord) PASSED: cst.tests.syntax.test() PASSED: cst.tests.configure.test() PASSED: cst.tests.hello_mpi.test() PASSED: cst.tests.point_source.test() PASSED: cst.tests.pml_boundary.test() PASSED: cst.tests.kostrov.test()