VisIt @ KAUST#
To facilitate the use of VisIt at KAUST, we have developed an example repository (VisIt Vignettes) that explains and demonstrates how to run VisIt on your local machine, Ibex, and Shaheen. Please check out this repository for best practices and examples of how to connect to a remote computing resource to visualizate your data, or to generate scripts to make visualization easier and automatic.
VisIt Vignettes#
What is VisIt#
VisIt is an interactive, parallel analysis and visualization tool for scientific data. VisIt contains a rich set of visualization features so you can view your data in a variety of ways. It can be used to visualize scalar and vector fields defined on two- and three-dimensional (2D and 3D) structured and unstructured meshes.
VisIt was developed to analyze extremely large datasets using distributed memory computing resources. It can be run both in interactive GUI mode and headless batch processing mode, making it ideal for HPC environments. The examples in this repository demonstrate both interactive and batch processing workflows.
Getting Started#
This repository provides both generic setup instructions that work on any HPC system and detailed instructions for specific known HPC installations. Choose the appropriate section based on your needs:
Generic HPC Setup: Instructions for setting up VisIt on any HPC system
KAUST HPC Systems: Specific instructions for KAUST’s Ibex and Shaheen III clusters
Example Details: Information about the included visualization examples
Advanced Topics: Advanced configuration and usage information
Repository Organization#
Each example is self-contained in its own directory with the following structure:
ex*.py: Python script demonstrating VisIt functionalityex*_template_runScript.sbat: Template batch script that can be customized for your HPC systemREADME.md: Detailed explanation of the example and how to run itAdditional helper scripts like
createVisItMovie.shfor post-processing
The MODULES.sh script provides a template for loading required modules on your HPC system. Modify this according to your system’s module environment.
Example Details#
The examples progress from basic operations to more complex visualizations:
ex00_visitQuery: Data loading and introspectionLoad datasets and query mesh information
Access variable metadata
Basic data inspection techniques
ex01_visitScreenshot: Basic visualization and outputSet up a basic visualization pipeline
Configure view and display properties
Save high-quality screenshots
ex02_visitAnimation: Camera animationCreate smooth camera movements
Configure animation settings
Generate image sequences for movies
ex03_visitIsosurfaceAnimation: Advanced visualization techniquesCreate and animate isosurfaces
Work with multiple visualization objects
Time-varying visualization properties
ex04_visitStreamlineAnimation: Flow visualizationGenerate and animate streamlines
Work with vector fields
Configure seed points and integration parameters
ex05_visitMultiTimeStepFile: Time-varying dataLoad and process time-series data
Time-dependent visualization
Batch processing multiple timesteps
ex06_visitLargeData: Production visualizationHandle large-scale datasets
Optimize performance
Complex multi-stage visualization pipelines
Generic HPC Setup#
Basic Setup Steps#
Install Local VisIt Client:
Download from VisIt website
Choose version matching your HPC system’s version
Configure Host Profile:
<?xml version="1.0"?> <Object name="VIEWER"> <Field name="HOST_PROFILES" type="stringVector"> "my_hpc_system", "SLURM_SBATCH", "localhost", "parallel", "SLURM", "", "/path/to/visit/install" </Field> </Object>
Run Example Scripts:
# Load VisIt module (adjust name as needed) module load visit # Run example in batch mode visit -nowin -cli -s ex01_visitScreenshot.py
KAUST HPC Systems#
Ibex Cluster#
Connect and Setup:
ssh <username>@ilogin.ibex.kaust.edu.sa cd /ibex/scratch/<username> git clone https://github.com/jameskress/Visualization_Vignettes.git module load visit
Client Configuration:
Click “Options → Host profiles and configuration setup”
Select KAUST and click “Install”
Save settings and restart VisIt
Run Examples:
cd Visualization_Vignettes/VisIt_Vignettes sbatch ex01/ex01_ibex_runScript.sbat
Shaheen III#
Connect and Setup:
ssh <username>@shaheen.hpc.kaust.edu.sa cd /scratch/<username> git clone https://github.com/jameskress/Visualization_Vignettes.git module load visit
Client Configuration:
Use steps above for Ibex
For VisIt < 3.4.1: Use KAUST Shaheen 3 Profile
Run Examples:
cd Visualization_Vignettes/VisIt_Vignettes # Edit account information vim ex01/ex01_shaheen_runScript.sbat # Replace --account=<##> with your account sbatch ex01/ex01_shaheen_runScript.sbat
WARNING: Version matching between client and server is critical. Always check available versions with module avail visit.
Client/Server Setup#
Install the VisIt client on your local machine
Check available VisIt versions on your HPC system:
module avail visitDownload and install the matching client version
Configure host profiles for your HPC systems (see template batch scripts)
The examples in this repository include batch scripts that can be adapted for your specific HPC environment.
WARNING: Using a different version of VisIt than what is available on IBEX WILL fail.
If this is your first time using VisIt on KAUST resources you will need to have VisIt load the KAUST host profile to be able to connect to KAUST systems. VisIt is distributed with the KAUST profiles, so they can be directly loaded from the VisIt GUI as follows:
Click “Options”
Click “Host profiles and configuration setup”
Select KAUST and click “Install”
Save the settings (Options/Save Settings). Exit and re-launch VisIt.
After successfully completing the above steps, you should now be able to connect to Ibex.
Remote GUI Usage#
Once you have VisIt installed and set up on your local computer:
Open VisIt on your local computer.
Go to: “File→Open file” or click the “Open” button on the GUI.
Click the “Host” dropdown menu on the “File open” window that popped up and choose “Ibex”.
This will prompt you for your Ibex password, unless you have passwordless ssh setup.
Navigate to the appropriate file.
Once you choose a file, you will be prompted for the number of nodes and processors you would like to use.
Once specified, the server side of VisIt will be launched, and you can interact with your data (after the job launches and reaches to top of the Ibex queue).
Using VisIt Interactively on Shaheen III#
It is possible to run a local VisIt client to display and interact with your data while the VisIt server runs in an Shaheen batch job (client/server mode), allowing interactive analysis of very large data sets. You will obtain the best performance by running the VisIt client on your local computer and running the server on Shaheen with the same version of VisIt. It is highly recommended to check the available VisIt versions using module avail visit on the system you plan to connect to with VisIt.
WARNING: Using a different version of VisIt than what is available on Shaheen WILL fail.
If this is your first time using VisIt on KAUST resources you will need to have VisIt load the KAUST host profile to be able to connect to KAUST systems. VisIt is distributed with the KAUST profiles, so they can be directly loaded from the VisIt GUI as follows:
Click “Options”
Click “Host profiles and configuration setup”
Select KAUST and click “Install”
Save the settings (Options/Save Settings). Exit and re-launch VisIt.
After successfully completing the above steps, you should now be able to connect to Shaheen.
Note: The above process will not give you the Shaheen 3 host profile in VisIt versions 3.4.1 or older. For thos instances you will need to manually create the host profile using the information for the VisIt repository, located here: KAUST Shaheen 3 VisIt Host Profile.
Using VisIt in Batch Processing Mode#
See the examples in this repo for how to create a job script to run a VisIt batch jobs.
Creating a Python Trace for Batch Processing#
One of the most convenient tools available in the GUI is the ability to convert (or “trace”) interactive actions in VisIt to Python code. Users that repeat a sequence of actions in VisIt to visualize their data may find the Trace tool useful. The Trace tool creates a Python script that reflects most actions taken in VisIt, which then can be used in batch mode to accomplish the same actions on Ibex or Shaheen.
To start tracing from the GUI, click on Controls/Command. An options window will pop up, at the top there will be a Record button. Hit Record to start the trace, any time you modify properties, create filters, open files, etc., your actions will be translated into Python syntax. Once you are finished tracing the actions you want to script, click Stop. A Python script should then be displayed to you and can be saved.
For more information on VisIt#
How to Run Examples in This Repo#
ex*.py#
Run scripts locally or log on to either Ibex (
@ilogin.ibex.kaust.edu.sa) or Shaheen ( @shaheen.hpc.kaust.edu.sa) Clone this repo
Locally wherever you like
git clone https://github.com/jameskress/Visualization_Vignettes.git
Ibex scratch:
cd /ibex/scratch/<username>git clone https://github.com/jameskress/Visualization_Vignettes.git
Shaheen scratch
cd /scratch/<username>git clone https://github.com/jameskress/Visualization_Vignettes.git
If using a cluster load the VisIt module file
Ibex
module load visit
Shaheen
module load visit
Run the example locally or on one of the clusters
Locally:
We can run the *.py script directly on the command line, not using a batch script
./visit -nowin -cli -s <path to the python script to run>
We can run the script live in the VisIt interface
Open the VisIt “command” window
Paste the following:
import os from os.path import join as pjoin scripts_dir = "<path to>/Visualization_Vignettes/VisIt_Vignettes" Source(pjoin(scripts_dir,"<name of the python script>"))Click “Execute”
Clusters: From the scratch directory run the appropriate batch script for either Ibex or Shaheen:
Ibex:
sbatch ex*_ibex_runScript.sbatShaheen:
Edit each Shaheen batch script by adding your account:
vim ex*_shaheen_runScribt.sbat, and replace--account=<##>with your accountsbatch ex*_shaheen_runScribt.sbat
View the output messages from the tests:
Locally: the output will print live to the terminal while running
Ibex:
cat ex*.ibex.<job_number>.outShaheen:
cat ex*.shaheen_<job_number>.out
View images from tests that write images:
Locally: use your preferred image viewer
Ibex:
display *.pnga. To view videos copy them to your local machineShaheen
display *.pnga. To view videos copy them to your local machine