WARPXM v1.10.0
Loading...
Searching...
No Matches
Running WARPXM

After WARPXM is installed, a WARPXM simulation can either be executed directly by supplying an input file as an argument, or through the warpy python interface. The following describes the command line arguments for each method.

Running WARPXM directly

WARPXM command-line options

The WARPXM help (-h) option provides a list of the available command line options. The use of common options are explained in the following sections.

% warpxm -h
-----------------------------------------------
WARPXM options
-input-file, -i: input file name.
-run-name, -n: Simulation run name sets the base file name for output and log files. Defaults to input file name without extension.
-restart-from-frame, -f: Restart simulation from given frame number
-restart-auto, -r: Restart simulation and search for last output frame.
-debug, -d: Start WARPXM in debug mode. Waits for a user to attach a debugger before running the simulation as normal.
-version, -v: Check WARPXM version number.
-----------------------------------------------

BUG: If the command-line option -help is passed, the help text for PETSC is printed to screen along with the WARPXM help text.

Running WARPXM without MPI (single process)

Given a warpxm input file WARPXM can be run as a single process via the command line:

warpxm -i input_file.inp

Running WARPXM with MPI (parallel)

For a parallel run with MPI (e.g. with 4 processes), use:

mpirun warpxm -np 4 -i input_file.inp

Restarting a simulation

WARPXM has the capability to start from any output frame. To use the last frame:

warpxm -r -i input_file.inp

To start from a specific frame number (e.g. frame 222):

warpxm -f 222 -i input_file.inp

Considerations

Some things to consider when running a WARPXM simulation:

  • The simulation data and log files will be written to the current working directory.
  • More processes isn't always better. For example, a 2D 3rd order DG simulation stops seeing benefites from additional process at about 80 elements per process.
  • To automate input file creation, direct simulation output to a desired location, and track Git revision inforamtion for a run, it is recommended to run WARPXM through the warpy Python interface.

Running WARPXM using the warpy Python interface

The warpy Python interface for WARPXM automates the creation of the WARPXM input file, as well as a many other useful tasks.

A number of configurations (run directory location, number of MPI process, etc.) can be made using the warpy_user_config.py. See the warpy documentation for more information.

With a warpy input file, a WARPXM simulation can be simply run with Python from the command line

python input_file.py

It is recommended to use Python 3, and warpy must be in the PYTHONPATH.