Getting Started
This page shows how to authenticate with NGC, launch the LipSync NIM container, and configure its runtime.
Prerequisites
To ensure that you have the supported hardware and software stack, check the Support Matrix.
NGC Authentication
An NGC API key is required to pull the container image and download models. Complete the following steps to create the key, export it, and log in to the NVIDIA Container Registry.
Generate an API Key
LipSync NIM is available only through the AI for Media Private Access Program. Joining the Private Access Program gives you an NGC API key with the permissions required for this NIM.
You can generate a key at https://org.ngc.nvidia.com/setup/api-keys after joining the Private Access Program.
When creating an NGC API Personal key, ensure that at least NGC Catalog is selected from the Services Included dropdown. You can include more services if this key is to be reused for other purposes.
Personal keys allow you to configure an expiration date, revoke or delete the key using an action button, and rotate the key as needed. For more information about key types, refer to NGC API Keys in the NGC User Guide.
Export the NGC API Key
Pass the value of the API key to the docker run command in the next section as the NGC_API_KEY environment variable to download the appropriate models and resources when starting the NIM.
If you are not familiar with how to create the NGC_API_KEY environment variable, the simplest way is to export it in your terminal:
Run one of the following commands to make the key available at startup:
Other, more secure options include saving the value in a file, so that you can retrieve with cat $NGC_API_KEY_FILE, or using a password manager.
Docker Login to NGC
To pull the NIM container image from NGC, first authenticate with the NVIDIA Container Registry with the following command:
Use $oauthtoken as the username and NGC_API_KEY as the password. The $oauthtoken username is a special name that indicates that you will authenticate with an API key and not a user name and password.
Before pulling the container image, you must accept the Governing Terms on the LipSync NIM container page in NGC. This page is accessible only after enrollment in the AI for Media Private Access Program.
Launching the NIM Container
The following command launches the LipSync NIM container with the gRPC service. The NIM detects the GPU architecture of the host and downloads the matching model automatically. (For a list of parameters, refer to Runtime Parameters for the Container.)
Port 9002 publishes the Triton Inference Server metrics endpoint, which
Observability uses. It is not required for inference; omit it if you do
not intend to scrape metrics.
Mount a host directory at NIM_CACHE_PATH (for example
-v $HOME/.cache/nim:/opt/nim/.cache) to persist model artifacts across runs and avoid
re-downloading them on every launch.
The flag --gpus all is used to assign all available GPUs to the NIM container.
To assign specific GPUs to the NIM container (if your machine has multiple GPUs), use --gpus '"device=0,1,2..."'.
On bare-metal Linux systems with PCIe topology and multiple GPUs, we recommend setting IOMMU to passthrough. Refer to PCIe Multi-GPU Systems.
If the NIM launch is successful, you get a response similar to the following.
By default, the LipSync NIM gRPC service is hosted on port 8001. You must use this port for inferencing requests. The port is configurable via the NIM_GRPC_API_PORT environment variable.
Selecting a Language-Specific Model
The LipSync NIM includes a generic, language-agnostic model (used by default) and fine-tuned models for specific languages. You select a language-specific model at NIM container launch time by using the NIM_TAGS_SELECTOR environment variable. Each container loads exactly one model.
Only de, es, and fr are supported. Any other value causes the container to fail at startup; omit the variable to use the generic model.
Profile selection stays automatic when you request a language: the NIM selects the profile that matches both your GPU architecture and the requested language.
The following example launches the NIM with the German model:
Environment Variables
The following table describes the environment variables that can be passed into a NIM as a -e argument added to a docker run command. The NV_AI4M_LS_* variables that govern buffering and timeouts for the input streams are grouped and explained in Input Stream Handling.
Runtime Parameters for the Container
The following table describes the docker run flags used to launch the LipSync NIM container.
HTTP API Endpoints
In addition to the gRPC Lipsync service on NIM_GRPC_API_PORT, the NIM serves three
read-only HTTP endpoints on NIM_HTTP_API_PORT (default 8000). Publish that port with
-p 8000:8000 to reach them from the host.
The following example queries the /v1/metadata endpoint from the host:
An abbreviated response:
/v1/metrics on the HTTP port is distinct from the Triton metrics endpoint on port 9002
described in Observability. They are different services on different
ports.
Stopping the Container
The following command can be used to stop the container.