Run SDK in a Container#
The VideoFX SDK can run in an isolated container. It is easier to try the sample apps without worrying about dependencies. And the docker image can be shared easily. Two more software packages are required: Docker Engine and NVIDIA Container Toolkit.
Install the Prerequisite Software#
Two software packages are required: Docker Engine and NVIDIA Container Toolkit.
Docker Engine#
Docker Engine is an open source containerization technology for building and containerizing your applications.
To install Docker Engine on your Linux distribution, go to docs.docker.com/engine/install.
Test Docker Engine on officially supported Linux distributions, such as Ubuntu 20.04.
NVIDIA Container Toolkit#
The NVIDIA Container Toolkit enables users to build and run GPU-accelerated containers. The toolkit includes a container runtime library and utilities to automatically configure containers to leverage NVIDIA GPUs.
To install and configure the NVIDIA Container Toolkit, go to https://docs.nvidia.com/datacenter/cloud-native/container-toolkit/latest/install-guide.html.
Fetch Sample Apps Repository#
Fetch the open source repository from NVIDIA-Maxine/VFX-SDK-Samples to a local directory vfx-sdk-samples, which will be mounted
when launching the container.
Build Docker Image#
Download and install the SDK and all models as described in Install the VFX SDK.
Then proceed to vfx-sdk-samples/docker and execute the build_docker_image.sh script.
The building script pulls the base image (Ubuntu 20.04) from Docker Hub and
installs required third-party libraries for running sample applications.
Once finished, you will see a Docker image maxine_videofx created
on your system using the sudo docker image ls command.
The repository name and the TAG can be customized by modifying the
vfx-sdk-samples/docker/docker_config.sh and rebuilding the Docker image.
Launch Container#
Launch the container by executing the script
vfx-sdk-samples/docker/docker_config.sh. You can choose a
directory on the host machine mapped to /host in the container
by specifying -m <host_dir> for file sharing purposes.
After the container is launched, you are ready to try the VideoFX SDK sample
applications in /host/vfxsdk-samples. Only offline mode is supported inside
the container. You can dump the output to /host directory so
that you can evaluate it in the host system for playback.
See Linux specific sample app instructions in the sample app repo’s README.md