Table of Contents
- Overview
- Introduction
- Part I: Setting up SPECFEM3D_GLOBE
- Part II: Continental-scale Simulations
- Part III: Visualization
- Part IV: Adjoint Simulations (Bonus)
- Further Work
- Resources
Part III: Visualization
In this third part of the tutorial, we will look at methods for visualizing the output simulation data. We will look at the following categories:
- Visualize Seismograms
- Visualize Model Mesh
- Visualize Surface Movie
Visualize Surface Movie
In order to create a surface movie for the simulation, we need to go through a couple of steps that are similar to what we did for visualizing the model mesh.
First, we need to modify the Par_file such that the movie data are being
saved. Therefore, open up DATA/Par_file and set the following parameter to
.true.:
...
# save AVS or OpenDX movies
# MOVIE_COARSE saves movie only at corners of elements (SURFACE OR VOLUME)
# MOVIE_COARSE does not work with create_movie_AVS_DX
MOVIE_SURFACE = .true.
...
Once this is done, we need to go through the following three steps in order to visualize the surface movie:
- Rerun the solver routine
- Generate the movie data
- Visualize using Paraview
-
Step 1: Rerun the solver routine
This step is the same as what we did in Part II. We run the
xspecfem3Dexecutable on the cluster by submitting thesubmit_solverscript:
sbatch submit_solver
And use squeue to monitor the job. Once the job finishes, we can check the
OUTPUT_FILES/output_solver.txt file to make sure that the solver ran
successfully, and then we can move on to the next step.
-
Step 2: Generate the movie data
The surface movie data files are stored in the
OUTPUT_FILES/folder asmoviedata*. In order to visualize the surface movie inParaview, we need to convert these datafiles to a format thatParaviewcan work with.In order to do this, we run the
xcreate_movie_AVS_DXthat is located in thebin/folder. From the root folder, run the following command:
./bin/xcreate_movie_AVS_DX
This script will then give you several options for how you want to format the movie data:
-
1st prompt: Choose option
2 = create files in AVS UCD format with individual files. -
2nd prompt: Choose the timestep you want the movie to
start(e.g. 1). -
3rd prompt: Choose the timested you want the movie to
end(e.g. -1). -
4th prompt: Choose the
componentyou want to visualize (e.g. 1)
The movie data will now be converted to AVS format and stored in the
OUTPUT_FILES/ folder.
-
Step 3: Visualize using Paraview
Start
Paraviewby typing the following command in the terminalparaviewOnce
Paraviewis running, click theOpenbutton in the top left corner, and navigate to theOUTPUT_FILES/folder. In this folder you should see a file-bundle calledAVS_movie_*.inp, which is the formatted movie data that we generated in the previous step.In order to visualize the surface movie, select the
AVS_movie_*.inpbundle (not the individual files contained in the bundle) and clickOK.An
Open Data With...menu should now appear. Select theAVS UCD Binary/ASCII Filesoption and clickOK.The movie data is now loaded, and you can click
Applyin thePropertiesmenu on the left-hand side in order to display it. To run the movie, click the leftmost green arrow in the top menu, calledFirst Frame, and then click the center green arrow, calledPlay.You might want to adjust the color scale to your own liking.
In this section, we have looked at how to create a surface movie for our simulation and how to visualize it using Paraview.
In the next section we move on to Part IV of the tutorial, and look at how to run adjoint simulations using SPECFEM3D_GLOBE.