NVIDIA IndeX ParaView Plugin User Guide 5.12.0
NVIDIA IndeX ParaView Plugin User Guide 5.12.0
NVIDIA IndeX ParaView Plugin User Guide 5.12.0
29 November 2023
Version 5.12.0
NVIDIA IndeX – ParaView Plugin User’s Guide
Copyright Information
➞ 2023 NVIDIA Corporation. All rights reserved. Document build number rev373738
1 Introduction 1
1.1 Licensing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1
2 Installation 2
2.1 System requirements . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2
2.2 Building ParaView and the NVIDIA IndeX plugin . . . . . . . . . . . . . . . . . . . . . . . . . . 2
2.3 Loading the plugin . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3
3 Getting started 5
3.1 Client-only mode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5
3.2 Simple client/server mode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6
3.3 Client/server mode with MPI . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7
3.4 NVIDIA IndeX settings . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8
3.5 Advanced NVIDIA IndeX configuration . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10
3.5.1 License setup . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10
3.5.2 Networking options . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10
© 2023 NVIDIA Corporation NVIDIA IndeX ± ParaView Plugin User’s Guide iii
5.2 XAC volume sample programs . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 34
5.2.1 Example program outline . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 35
5.3 Sampling a volume and map to a color . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 35
5.4 Using XAC library functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 36
5.5 Adding basic volume shading . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 37
5.6 Using CUDA parameter buffers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 37
7 Resources 41
1.1 Licensing
The NVIDIA IndeX for ParaView Plugin comes with a free evaluation license that enables all
features for a limited time, including full scalability to run on multiple NVIDIA GPUs and on
a cluster of GPU hosts. The software will continue to run after the evaluation period, but with
multi-GPU features disabled.
For licensing requests, please contact nvidia-index@nvidia.com.
1. https://www.paraview.org/download/
The NVIDIA IndeX plugin can also be built from source, together with ParaView. See the
ParaView build documentation 2 for a general overview of the build process. For compiling
the plugin, two additional steps are necessary:
1. Since the NVIDIA IndeX plugin is not enabled in the default build, enable it by setting
PARAVIEW_PLUGIN_ENABLE_pvNVIDIAIndeX=ON when running cmake, for example:
2. Download the latest NVIDIA IndeX libraries package for your platform from the
ParaView dependency repository: https://www.paraview.org/files/dependencies/
Windows
nvidia-index-libs-5.12.0.<YYYYMMDD>-windows-x64.tar.bz2
Linux x86-64
nvidia-index-libs-5.12.0.<YYYYMMDD>-linux.tar.bz2
Linux ARM/aarch64
nvidia-index-libs-5.12.0.<YYYYMMDD>-linux-aarch64.tar.bz2
macOS
NVIDIA IndeX libraries are not available for macOS, but are also not required for
remote rendering.
Extract the contents of the downloaded package to the lib directory inside your
ParaView installation, so that ParaView can find the libraries at runtime.
2. https://gitlab.kitware.com/paraview/paraview/-/blob/master/Documentation/dev/build.md
Select pvNVIDIAIndeX in the list of “Local Plugins” and choose Load Selected. To automatically
load the plugin when ParaView starts, expand the list entry and check Auto Load.
When loading the plugin for the first time, please read and accept the End User License
Agreement (EULA).
Once the plugin is loaded, its name will show up in the list of “Local Plugins” with its status
changed to Loaded. Make sure there are no errors messages shown in the terminal or on
ParaView’s console.
When using the plugin in client/server mode, it must be loaded in both “Local Plugins” and
“Remote Plugins”.
1. https://www.paraview.org/Wiki/Setting_up_a_ParaView_Server
To run ParaView with the NVIDIA IndeX plugin in client/server mode, first start pvserver
on a host equipped with a suitable NVIDIA GPU:
pvserver --displays=:0
When using EGL, you need to specify the EGL device index (0, 1, etc.) instead of the X11
display (:0). Please note that, in either case, this selection will not influence what GPUs will
be used by NVIDIA IndeX, but only what other ParaView renderers will use.
Once the pvserver process is launched, run the ParaView client and connect to the host
where pvserver is running by selecting [ File ▶ Connect ▶ Add Servers ] in the menu.
Typically the server address is printed out in the console where pvserver was executed and,
once the client has connected, “Client connected” will be printed there. Make sure to load the
NVIDIA IndeX plugin on both the client and the server side as described in “Loading the
plugin” (page 3).
Alternatively, the mpiexec program that is part of the ParaView package can be used:
While NVIDIA IndeX will automatically use all available NVIDIA GPUs, other renderers in
ParaView will utilize only those GPUs that are explicitly specified with --displays. Multiple
GPUs can be specified, for example, with --displays=:0.0,:0.1,:0.2,:0.3 (for X11) or
--displays=0,1,2,3 (for EGL). These GPUs will then be assigned to the MPI ranks in a
round-robin fashion. See the ParaView documentation for details. Note that the --displays
parameter will not affect the GPU assignment used by NVIDIA IndeX.
A valid license for the cluster version of the plugin is required for NVIDIA IndeX to be able to
utilize more than a single GPU. The plugin comes with a default evaluation license that
enables all multi-GPU and cluster features for a limited time. With a valid license in place (see
“License setup” (page 10)), NVIDIA IndeX can also distribute the rendering workload to
multiple GPUs on multiple hosts in a cluster environment. For example, this command will
launch 4 pvserver processes each on host1 and host2, which are equipped with 2 GPUs:
When exclusively using NVIDIA IndeX for rendering, it would be sufficient to just specify
--displays=:0, independent of the actual number of GPUs.
Before connecting the ParaView client to pvserver, please ensure that IceT compositing is
disabled. This can be controlled from in the Settings dialog at [ Edit ▶ Settings ▶ Render View ].
Restart ParaView after changing the setting. An error message will be printed if IceT
compositing is still enabled when running the NVIDIA IndeX plugin on multiple MPI ranks.
export NVINDEX_PVPLUGIN_HOME=path-to-directory-with-config-file
export NVINDEX_VENDOR_KEY="vendor-key-here"
export NVINDEX_SECRET_KEY="secret-key-here"
Alternatively, enter those keys into the Settings dialog or copy them into the <license>
section of the configuration file as shown below.
<index_config>
<license>
<vendor_key>vendor-key-here</vendor_key>
<secret_key>secret-key-here</secret_key>
</license>
</index_config>
<index_config>
<network>
<cluster_mode>TCP</cluster_mode>
<cluster_interface_address>
172.161.123.0/24:10001
</cluster_interface_address>
2. https://gitlab.kitware.com/paraview/paraview/-/raw/master/Plugins/pvNVIDIAIndeX/nvindex_
config.xml
3. https://www.paraview.org/Wiki/ParaView_Settings_Files
<multicast_address>224.1.3.2</multicast_address>
<discovery_address>224.1.3.3:5555</discovery_address>
<use_rdma>no</use_rdma>
</network>
</index_config>
<cluster_mode> defines the networking mode of NVIDIA IndeX. The modes OFF, UDP, TCP
and TCP_WITH_DISCOVERY are supported, and TCP is the default mode.
<cluster_interface_address> defines the network interface that is used for
communication between the hosts. This may also be an interface name, but it must be the
same on all hosts. If not set, a network interface will be chosen automatically, which might
not always be the right one. The string may end with a colon character ( : ) and a port number
to select which port to listen on for UDP and TCP unicast traffic. If no port is set then port
10000 will be used.
<multicast_address> defines the multicast address for communication between the hosts.
This will only be used when cluster_mode is set to UDP.
<discovery_address> defines the discovery address used for TCP_WITH_DISCOVERY.
<use_rdma> can be set to yes or no to enable or disable InfiniBand RDMA mode for
networking.
By editing the colormap you can restrict the visualization to regions of the dataset that are
interesting to you. This can be achieved by changing the colortable, by adjusting the
transparency, or by setting custom domain range values to hide specific parts of the dataset.
For unstructured grids, cropping is controlled using the sliders in the NVIDIA IndeX Region of
Interest section of the Properties panel.
There is no single filtering mode that will be optimal for all datasets, but each filtering mode
achieves different levels of quality with different datasets and transfer function combinations,
with nearest neighbor interpolation being the most basic one. Some example images
comparing different filtering modes are shown below.
Fig. 4.17 - Slice rendering options in the Properties panel. Dataset was made available by Dr. Jackqueline Chen
at Sandia Laboratories through US Department of Energy’s SciDAC Institute for Ultrascale Visualization.
Fig. 4.19 - Supernova SASI visualized as a volume. Dataset courtesy of Dr. John Blondin at the North Carolina
State University through US Department of Energy’s SciDAC Institute for Ultrascale Visualization.
Fig. 4.22 - Supernova SASI visualized using the depth enhancement preset
Fig. 4.23 - Supernova SASI visualized using the edge enhancement preset
Fig. 4.24 - CHOLLA galactic outflow simulation visualized as a volume. Dataset courtesy
of Evan E. Schneider (Princeton University) and Brant Robertson (University of California,
Santa Cruz).
Fig. 4.25 - CHOLLA galactic outflow simulation visualized using the gradient preset.
Fig. 4.26 - Custom preset: Floating point and integer parameters binding in an
XAC program.
Fig. 4.27 - BigBrain Project dataset visualized with the custom preset. Dataset courtesy of
Prof. Dr. med. Katrin Amunts and the Structural and Functional Organization of the Brain lab
at the Institute of Neuroscience and Medicine, Research Centre Jülich.
1. https://www.paraview.org/in-situ/
As an example, a simple Wavelet source can be used to illustrate the Catalyst integration with
NVIDIA IndeX rendering. Make sure you have compiled ParaView with Catalyst support
before trying to do the live visualization.
You can start with 50 iterations of a Wavelet data source in a single process by running the
following command. The scripts CatalystWaveletDriver.py and
CatalystWaveletCoprocessing.py are located in the directory
Clients/ParaView/Testing/XML/ in the ParaView source repository.
Next, start the ParaView client and connect to the port where Catalyst is running with
[ Catalyst ▶ Connect ] in the menu
Once ParaView connects to Catalyst, enable Input and click Extract input from the Pipeline
Browser. Once the input is extracted, you can switch the rendering to the NVIDIA IndeX
representation.
Fig. 4.31 - Wavelet data rendered as a surface by ParaView and as a volume by NVIDIA IndeX
Unstructured grids
Datasets containing degenerate faces may result in incorrect renderings or cause ParaView to
fail. The NVIDIA IndeX plugin will try to resolve all invalid faces automatically.
General
The Windows version of the NVIDIA IndeX plugin is restricted to run on a single host only,
i.e., cluster rendering is not supported on Windows platforms.
When loading an older state file with both volumetric and geometry data without the
NVIDIA IndeX representation saved in it, the first frame will show only volumetric data.
After interacting with the scene, the subsequent frames will be correct again with both
geometry and volume data visible.
Listing 5.1
public:
NV_IDX_DEVICE_INLINE_MEMBER
Initialization function
void initialize()
{
// initial setup...
}
NV_IDX_DEVICE_INLINE_MEMBER
Main rendering function (required)
int execute(
const Sample_info_self& input, Sample_output& out)
{
float4 color = make_float4(1.f); Do some color computations here...
The full XAC API is documented in the NVIDIA IndeX Programmer’s Manual.1
To sample a data value from a volume and map it to a color using the transfer function (or
colormap), the following lines have to be added to the execute() function:
Listing 5.2
NV_IDX_DEVICE_INLINE_MEMBER
int execute(const Sample_info_self& input, Sample_output& output)
{
const float3& sample_position =
Get current sample position
input.sample_position_object_space;
Apply the
float4 sample_color = colormap.lookup(sample_value);
colormap
return NV_IDX_PROG_OK;
}
1. https://raytracing-docs.nvidia.com/nvindex/index.html
2. https://docs.nvidia.com/cuda/cuda-math-api/index.html
Listing 5.3
Listing 5.4
float4 sample_color =
Apply the colormap, creating an RGBA color
colormap.lookup(sample_value);
sample_color =
xaclib::headlight_shading(
Apply built-in headlight shading
state.scene, normal, view_dir,
sample_color, specular_color);
The NVIDIA IndeX plugin provides pre-defined parameter buffers that can be edited through
the ParaVier user interface.
Listing 5.5
struct Custom_params
{
float4 floats; // floats array Custom parameters set in the ParaView user
interface
int4 ints; // ints array
};
NV_IDX_DEVICE_INLINE_MEMBER
void initialize()
{
Bind input
m_custom_params parameter buffer
= state.bind_parameter_buffer<Custom_params>(0); from parameter
slot 0
}
NV_IDX_DEVICE_INLINE_MEMBER
int execute(
const Sample_info_self& sample_info,
Sample_output& sample_output)
{
Retrieves input
const float input_value = m_custom_params.floats[0]; parameter
float4 modified_color =
make_float4(red, green, blue, alpha);
Color computation
modified_color =
xaclib::clamp(modified_color, 0.f, 1.f);
Q: When I load the plugin from ParaView’s [ Tools ▶ Manage Plugins ] window,
pvNVIDIAIndeX does not show up as loaded.
A: Make sure you have no errors in ParaView’s console or in the terminal where you started
ParaView from. Any error messages will give you additional information about what the
issue might be.
Q: The plugin is loaded successfully without any errors but NVIDIA IndeX does not show up
in ParaView’s Representation drop-down list.
A: Make sure you have loaded a structured or unstructured volume grid dataset and it is
selected in ParaView’s pipeline browser. ParaView chooses the available representations
based on the input data format.
Q: There is an error saying “Failed loading NVIDIA IndeX library” and the viewport is
empty.
A: This error message is usually printed when the NVIDIA IndeX libraries (.so on Linux
and .dll on Windows) are not found. Make sure that libnvindex.so and libdice.so can
be found by ParaView. Either copy all the libraries to ParaView’s library directories or set the
environment variable LD_LIBRARY_PATH (or PATH on Windows) accordingly. Refer to
“Building ParaView and the NVIDIA IndeX plugin” (page 2) for more information.
Q: Viewport is blank when I choose NVIDIA IndeX as a representation with a Scalar Array
and not with Solid Color
A: This is most likely because of an old NVIDIA display driver. Update your display drivers
to the recommended versions. If this happens in client/server mode, make sure that IceT
compositing is disabled, as described in Client/server mode with MPI (page 7).
Q: Can I use the NVIDIA IndeX library in my own application without ParaView?
A: Yes, an NVIDIA IndeX SDK is available. Please contact NVIDIA for more details:
nvidia-index@nvidia.com
1. https://www.nvidia.com/en-us/data-center/index-paraview-plugin
2. https://developer.nvidia.com/index
3. https://www.paraview.org/download/
4. https://www.paraview.org/resources/
5. https://discourse.paraview.org