AxiSEMLib is a python library that provides several extensions for the AxiSEM:
And there are several modifications in AxiSEM
Part of the code are adapted from Instaseis, so LGPL license is applied.
Compilers: C++/Fortran compilers which support c++14 (tested on GCC >=7.5
, ICC >=18.4.0
), cmake >= 3.12
, and MPI libraries.
conda create -n axisem_lib python=3.8
conda activate axisem_lib
conda install numpy scipy numba pyproj tqdm
pip install pybind11-global
MPICC=mpicc pip install mpi4py --no-binary mpi4py
parallel-hdf5
libraries:
CC="mpicc" HDF5_MPI="ON" HDF5_DIR=/path/to/parallel-hdf5 pip install --no-binary=h5py h5py
AxiSEMLib
by using:
mkdir -p build; cd build;
cmake .. -DCXX=g++ -DFC=gfortran -DPYTHON_EXECUTABLE=`which python`
make -j4; make install
Go to directory axisem
and change compiler options in make_axisem.macros
. Remember to set USE_NETCDF = true
, set NETCDF_PATH
.
MESHER/
, set parameters including DOMINANT_PERIOD
and number of slices in inparam_mesh
. If you want to use a smoothed version of ak135 model, you can run scripts under smooth_model/main.py
, and set the parameters like:
BACKGROUND_MODEL external
EXT_MODEL ak135.smooth.bm
./submit.csh
and ./movemesh.csh mesh_name
. Then the mesh files will be moved to SOLVER/MESHES
as the mesh_name
you set.There are two files you should edit: inparam_basic
and inparam_advanced
.
In param_basic
you should set SEISMOGRAM_LENGTH
as you required, and you should set ATTENUATION
to false
because the current version only support isotropic elastic model. And you can set some other parameters like SIMULATION_TYPE
. If SIMULATION_TYPE
is not moment
, you should also edit inparam_source
.
In inparam_advanced
, you should set the part of several parameters as below:
# GLL points to save, starting and ending GLL point index
# (overwritten with 0 and npol for dumptype displ_only)
KERNEL_IBEG 0
KERNEL_IEND 4
KERNEL_JBEG 0
KERNEL_JEND 4
KERNEL_WAVEFIELDS true
KERNEL_DUMPTYPE displ_only
KERNEL_SPP 8/16/32 (depend on your dominant frequency)
# you should add this one
# KERNEL dump after DUMP_T0
DUMP_T0 200.
# epicenter distance
KERNEL_COLAT_MIN 25.
KERNEL_COLAT_MAX 100.
# minimal and maximal radius in km for kernel wavefields
# (only for dumptype displ_only)
KERNEL_RMIN 5000.
KERNEL_RMAX 6372.
Then you can prepare your CMTSOLUTION
and STATIONS
Run it on your cluster.
Set the variables in submit_transpose.sh
, then:
bash submit_transpose.sh
test/
!