-
Notifications
You must be signed in to change notification settings - Fork 8
Projection code
The projection code in project.py takes the max, min, and average across the z-direction of the slab burner data region. These instructions are specifically for running on LLNL's Quartz.
Put this in your home directory. Get there by typing cd in your terminal first. Run the following commands in terminal:
git clone https://github.com/UBCHREST/post-processing.gitIn-depth instructions for all things related to using python on Quartz can be found at https://hpc.llnl.gov/software/development-environment-software/python
To create a virtual environment using python3, navigate to the post-processing repository, then use the following command.
/usr/tce/packages/python/python3.8/bin/virtualenv --system-site-packages ./venvThe virtual environment's version of python can be found in venv/bin/python3.8.
Make sure to load these modules for every new session, or the code will not work
module load hdf5-parallel/1.12.0
module load mvapich2/2.3This only needs to be done once. While in post-processing, run the following:
/venv/bin/python3.8 -m pip install argparse
/venv/bin/python3.8 -m pip install pathlib
/venv/bin/python3.8 -m pip install numpy
/venv/bin/python3.8 -m pip install mpi4py
/venv/bin/python3.8 -m pip install h5pySome of these modules will already be in place. This list is just for the sake of completeness.
Vary the number of nodes asked for by modifying the number after the -N flag.
salloc -N 1 -p pdebug --time=60:00The projection code is able to take both a single file or a directory; however, as these files are quite large, it is advised to only do one at a time. There are a number of argument flags that can be used, listed below.
The actual srun command is as follows:
srun -n number_of_processes venv/bin/python3 ablate/project.py /path/to/hdf5/file arg1 arg 2 arg 3| Argument | Description | Required(True/False) | Default value(if applicable) |
|---|---|---|---|
| --file | The input hdf5 file | True | N/A |
| -- nx | The number of x coordinates | False | 336 |
| --ny | The number of y coordinates | False | 48 |
| --field | The field to draw from | False | monitor_temperature |
| --component | The component to draw from | False | sum |
| --new_dir | A boolean option to control whether an output directory is created. Only works for directory inputs. | False | False |