TIGER is a Python module for directly accessing Exodus and Nemesis file data as numpy arrays. Examples demonstrate how to generate high quality figures using matplotlib and the TIGER interface.
When reading multiple Exodus files, ExodusReader combines available variable
names from each file. The resulting lists are exposed on the multi-file reader
via nodal_var_names and elem_var_names. These attributes show all nodal
and elemental variables that may be requested with APIs such as
get_data_at_time. These APIs also accept an optional block_id to
restrict queries to a specific element block. For example::
x, y, z, c = reader.get_data_at_time('c_Cr', time, block_id=1)
This returns coordinates and values only for block 1.
Clone the repository and run the setup script:
git clone https://github.com/chaitanyaBhave26/TIGER.git
cd TIGER
bash setup.shActivate the environment (required each time you use TIGER):
source tiger_env/bin/activateThat's it! TIGER is now ready to use.
The setup.sh script:
- Creates a Python virtual environment (
tiger_env/) - Installs all required dependencies
- Installs TIGER in development mode
Manual installation (if you prefer):
python3 -m venv tiger_env
source tiger_env/bin/activate
pip install -r requirements.txt
pip install -e .Optional dependencies (for video generation):
pip install -r requirements-optional.txtFor proper resource management, use ExodusReader as a context manager:
with ExodusReader(filenames) as reader:
times = reader.global_times
x, y, z, c = reader.get_data_at_time('temperature', times[-1])
# Process data...
# Reader is automatically closedThis ensures the underlying netCDF dataset is properly closed even if errors occur.
For meshes with multiple element blocks (e.g., multi-material simulations):
with ExodusReader('mesh.e') as reader:
# See available blocks
print(f"Blocks: {list(reader.block_connect.keys())}")
# Extract data from specific block
x, y, z, c = reader.get_data_at_time('stress', time, block_id=1)
# Compare across blocks
for block_id in reader.block_connect.keys():
x, y, z, c = reader.get_data_at_time('temperature', time, block_id=block_id)
# Analyze block-specific data...The block_id parameter restricts queries to a specific element block. If omitted, data from all blocks is returned.
Example scripts are located in the examples/ directory. Before running:
- Activate the virtual environment:
source tiger_env/bin/activate - Create subdirectories for output:
mkdir -p examples/{1D,2D,3D} - Place your Exodus data files in the appropriate directories
- Run examples:
python examples/1d_plot.py
See examples/README.md for detailed information about each example.
When done working with TIGER:
deactivateIf you prefer Conda over venv:
- Install Conda from the Conda website
- Create the TIGER environment:
conda create --name tiger_env "h5py=*=mpi*" "netcdf4=1.6.*=mpi*" matplotlib scipy numpy pytest cmcrameri mpi4py -c conda-forge
- Activate and install TIGER:
conda activate tiger_env cd TIGER pip install -e .
For HPC systems with environment modules:
- Load required modules:
module load python module load mpi
- Follow the manual installation steps above