Modulus Extension

Overview

NVIDIA Modulus is a neural network framework that blends the power of physics in the form of governing partial differential equations (PDEs) with data to build high-fidelity, parameterized surrogate models with near-real-time latency. The Modulus Extension combines Modulus with Omniverse, and allows you to explore Modulus-based simulations interactively.

Notes on Installation and Execution

To use this extension, you’ll need to be on a supported operating system, and using Omniverse Create. For now, only Linux versions supported by Omniverse Create are supported. We suggest Ubuntu 20.04. Omniverse Create can be installed via the Omniverse Launcher. Instructions for installing the Omniverse Launcher can be found here: https://docs.omniverse.nvidia.com/prod_install-guide/prod_install-guide/workstation.html

Some methods of CUDA installation do not include libnvToolsExt.so.1, which is required for one of the Modulus dependencies to function properly. If your system does not have libnvToolsExt.so.1, you should install the libnvtoolsext1 as follows:

sudo apt install libnvtoolsext1

Currently, Modulus integration into Omniverse is preliminary. Debugging Modulus scenarios during development or testing is particularly troublesome. To easily view the logging information generated by Modulus, we recommend starting Omniverse Create within a terminal window by using the following command, making sure to change the Omniverse Create version to match your installed version:

#Change the version (here 2022.1.2) to match your OV Create version:
~/.local/share/ov/pkg/create-2022.1.2/omni.create.sh

GPU Memory requirements for running both Omniverse Create and Modulus can be quite high. For existing scenarios, we have observed minimum GPU requirements of an RTX 3090 or higher.

Enabling the Extension

  1. From the menu bar, navigate to Window > Extensions

  2. Using the search field of the Extension Manager, search for “Modulus” Extension

  3. Install and enable the modulus_ext.core Extension

  4. Using the search field of the Extension Manager, search for “vtkm” Extension

  5. Install and enable the hpcvis.vtkm_bridge.core Extension

modulus core extension installing
modulus core extension enabled

The first time you do this, it will take up to several minutes to download the Modulus extension; during this time, Create may not react to your input. After the extension is successfully installed and loaded, you should see an otherwise empty tab entitled Modulus.

modulus core extension showing empty modulus tab (no scenarios loaded yet)

Choosing a Scenario

Simulation scenarios for the Modulus Extension are themselves extensions. For now, the following preconfigured scenarios are available to experiment with:

  • modulus_scenario_fpga

Load a scenario extension by searching for its name in the Extension manager (in the following, we will use modulus_scenario_fpga). Install and enable the extension. If you do this for the first time, this process can take a few minutes for the pretrained model to be downloaded and installed on your machine.

FPGA scenario enabled

The Modulus window should now be populated with a list of parameters.

Run and visualize a scenario

A number of visualization modes are available. Each mode will populate whichever stage is currently open in Create with visualization geometry, which will be updated as you change parameters.

  • Isosurface: Create an isosurface of the velocity magnitude

  • Streamlines: Create a set of Streamlines

  • Slices: Add three axis-aligned slices of the velocity magnitude

FPGA scenario isosurface
FPGA scenario streamlines
FPGA scenario slices

The first time you click one of these, the model is initialized, which may take a few seconds. The scenario is then evaluated, and visualization geometry produced for the result.

Adjust parameters

Scenario extensions can expose a number of parameters, both for the AI model itself and for the visualization. The FPGA scenario has two model paramaters:

  • HS_height: Height of the heatsink fins

  • HS_length: Length of the heatsink fins

FPGA scenario model parameters

Change the parameter values for either of these parameters using the provided sliders, and observe the visualization change as new results are generated.

Parameters for the visualization are:

  • isovalue: The isovalue for which the velocity magnitude isosurface is generated

  • streamline_count: Number of streamlines for streamline visualization

  • streamline_step_size: Numerical integration step size for streamline visualization

  • streamline_step_count: Number of numerical integration steps for streamline visualization

  • streamline_radius: Radius of the tube diameter for the streamlines visualization

  • streamline_height: Height at which streamlines are seeded

  • slice_x_offset: Position of the X-orthogonal slice along the X axis

  • slice_y_offset: Position of the Y-orthogonal slice along the Y axis

  • slice_z_offset: Position of the Z-orthogonal slice along the Z axis

FPGA scenario visualization parameters

Make adjustments to each parameter and observe the visualization change. The model is not reevaluated when visualization parameters are modified.