Commit cf3f7f98 authored by Florian Wittkamp's avatar Florian Wittkamp
Browse files

Edit some README files

parent 39fbd7af
......@@ -15,6 +15,7 @@ To ensure that the code will stay easy to maintain and extend, all developers ar
For consistent source code formatting a clang-format style file is provided.
Please config your integrated development environment (IDE) to format source code according to the style file given by the `.clang-format` file located within the `src/` folder.
All major IDEs (e.g. Kdevelop, XCode, emacs, vim) support this file type.
Alternatively, a manual source code formatting is possible by the shell script, which is located in `src/Scripts/formatSourceCode.sh`.
You may be required to install the clang-format tool on your machine.
Since clang-format is part of llvm project, more information are given on [llvm.org](llvm.org) or [https://clang.llvm.org/docs/ClangFormat.html](https://clang.llvm.org/docs/ClangFormat.html).
......@@ -35,4 +36,6 @@ Two kinds of tests are provided:
1. Unit tests (based on the [Google Test framework](https://github.com/google/googletest))
2. Full integration tests
You can run the tests by the script `par/start_tests.sh`. However, in order to use the Google Test framework, you have to set the environment variable `GTEST_DIR` to the location of the compiled Google Test library (`libgtest.*` and `libgtest_main.*`). The integration test has no special requirements apart LAMA and MPI.
The unit tests will verify the functionality of individual functions and classes, while the integration tests will run the whole forward code and verify that the obtained result is identical to a reference solution.
......@@ -4,7 +4,7 @@ Master: [![build status](https://git.scc.kit.edu/WAVE/FDSimulation_LAMA/badges/m
Master: [![coverage report](https://git.scc.kit.edu/WAVE/FDSimulation_LAMA/badges/master/coverage.svg)](https://git.scc.kit.edu/WAVE/FDSimulation_LAMA/commits/master) Develop: [![coverage report](https://git.scc.kit.edu/WAVE/FDSimulation_LAMA/badges/develop/coverage.svg)](https://git.scc.kit.edu/WAVE/FDSimulation_LAMA/commits/develop)
*Seismic Finite-Difference modelling developed within the [WAVE-Project](http://wave-toolbox.org).*
*Seismic Finite-Difference modelling developed by the [WAVE-Project](http://wave-toolbox.org).*
Get started:
- See `README.md` in `par/`
......
LANGUAGE=DE
all: install
install: install_theory install_doxygen
install_theory:
$(MAKE) -C theory/ install LANG=$(LANGUAGE)
$(MAKE) -C theory/ install
install_doxygen:
$(MAKE) -C doxygen/ install
......@@ -2,12 +2,10 @@
- Complete documentation: `make all`
## Theory
## Documentation for theory
- Make target `make install_theory`
- Select language by `LANGUAGE` to `DE` or `EN`
- eg. `make install_theory LANGUAGE=EN` for english
- Output: `theory/WAVE_theory_${LANGUAGE}.pdf`
- Output: `theory/WAVE_theory_EN.pdf`
- Requirement: *pdflatex* and *bibtex*
## Documentation for source code
......
TARGET=WAVE_guide_EN
endif
.PHONY: install
install: pdf
......
## Preparatory steps
To start the modelling code, you have to set the paths to the LAMA framework:
Since this finite-difference simulation code is based on the [LAMA framework](www.libama.org), you have to install this framework on your machine. A detailed documentation how to install LAMA is given on their website.
We successfully tested LAMA on different operating systems e.g. macOS (Sierra, El Capitan) and Linux (SUSE) as well as on a wide range of architectures e.g. HPC systems and GPUs.
Before the modelling code can be started, you have to set the paths to the installation of the [LAMA framework](www.libama.org):
- `export SCAI_ROOT=[PATH_TO_LAMA_BUILD]`
Moreover, you have to add the LAMA framework to the compiler search paths:
- `export DYLD_LIBRARY_PATH=${SCAI_ROOT}/lib:${DYLD_LIBRARY_PATH}`
- `export LD_LIBRARY_PATH=${SCAI_ROOT}/lib:${LD_LIBRARY_PATH}`
......@@ -12,22 +18,27 @@ The simulation can be started by the example start file:
Different kinds of parallelization are possible:
- Using OpenMP:
- Set `export OMP_NUM_THREADS=1`
- Using OpenMPI/IntelMPI:
- Modify `start_FDSimulation.sh` to e.g. `mpirun -np 4 ./../SOFI3Dacoustic`
- Using OpenMP (shared-memory parallel):
- Set `export OMP_NUM_THREADS=2`
- Using OpenMPI/IntelMPI (distributed-memory parallel):
- Modify `start_FDSimulation.sh` to e.g. `mpirun -np 2 ./../bin/SOFI`
The standard configuration of `start_FDSimulation.sh` is using both kinds of parallelization.
## Run the tests
To test the proper functionality of the installation, you can run the build in unit and integration tests.
Since the [Google Test framework](https://github.com/google/googletest) is used for the unit tests, the environment variable `GTEST_DIR` has to be set to the location of the compiled Google Test library (`libgtest.*` and `libgtest_main.*`). The integration test has no special requirements apart the LAMA framework and MPI.
## Start the tests
To test the proper functionality of the installation, you can run the tests:
``source start_tests.sh``
- `source start_tests.sh`
If one of the test cases fails, the script will give an error message and will abort.
## Data processing
## Data processing for parallel I/O
Since the modelling code supports parallel I/O operations some pre- and post-processing steps maybe required to split or merge data.
Since the modelling code supports parallel I/O operations some pre- and post-processing steps maybe required to split or merge data. In order to use the binaries mentioned below, you have to build [LAMA](www.libama.org) with the option `BUILD_EXAMPLES=ON`.
#### Data pre-processing
- to partition a single vector-file `~/WAVE/scai_lama/build/lama/examples/io/vectorRepartition.exe filename.mtx 1 filename_%r.mtx {NProcessors}`
- to partition a single vector-file `${SCAI_ROOT}/lama/examples/io/vectorRepartition.exe filename.mtx 1 filename_%r.mtx {NProcessors}`
#### Data post-processing
- Merge to a single vector-file `~/WAVE/scai_lama/build/lama/examples/io/vectorRepartition.exe filename_%r.mtx {NProcessors} filename.mtx 1`
- Merge to a single vector-file `${SCAI_ROOT}/lama/examples/io/vectorRepartition.exe filename_%r.mtx {NProcessors} filename.mtx 1`
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment