Audio2Face-3D scripts to orchestrate creation and configuration of resources on Cloud Service Providers (CSPs) and deploy Audio2Face-3D NIM
Audio2Face-3D NV One Click Deploy User Doc
Supported Platforms
- AWS CNS
- Azure CNS
Table of Contents
Context
The NV One Click framework is a collection of tools and scripts that allow developers to prototype and share a simplified means of running their application on various on-premise and cloud platforms.
This guide will discuss how the framework will be used by Application users:
- Application users: Users of the application who wish to deploy the application on their own on-premise or cloud infrastructure.
For Application Users
Artifact Pre-Reqs
IMPORTANT: Ensure using framework in compatible env and install required dependencies.
- Machine used to deploy the application on the target platform:
- Should have a compatible OS. Currently, the framework has been tested on the following OS:
- Ubuntu 22.04/24.04
- The user may encounter isolated issues when using other flavors of Ubuntu/Linux.
- The following tools along with versions the framework has been tested on (other/newer versions should be acceptable):
- yq (version v4.34.1) (source https://github.com/mikefarah/yq/)
- jq (version 1.6)
- python3 (version 3.9.0+)
- venv (python3-venv) (version 3.9.0+)
- pip (python3-pip) (version 22.0.0+)
- terraform (1.5.7)
- Running
./envbuild.shor./install-pre-requisites.shwill prompt installation of above tools in case any are found missing/outdated.
- Should have a compatible OS. Currently, the framework has been tested on the following OS:
- Access credentials:
- In order to deploy on the cloud (based on shape chosen)
- AWS (Access key and secret of preferably admin user. Fine-grained access subject to example being used)
- Azure (Client id and secret of preferably admin service account. Fine-grained access subject to example being used)
- In order to deploy on bare metal
- SSH details such as username, pem-key in order to connect to the target machines
- In order to deploy on the cloud (based on shape chosen)
- Resources for IaC state:
- Terraform state to be saved in an accessible storage option. Ref: terraform/configuration/available-backends
- Refer to
README.mdin artifact for detailed instructions based on the shape.
Artifact Folder Structure
The generated NV One Click deployable artifacts for Audio2Face-3D can be found in the current working directory.
Folder Structure of the tarball
| Item | Description |
|---|---|
| ansible-requirements.yml | These contain definitions of ansible roles and collections required by the playbooks. |
| app-tasks.yml | These contain tasks to be executed during the app stage. |
| config-template.yml | App Deployer overrides with required configs and creds. |
| config-files | These are config files which will be used in tasks. |
| envbuild.sh | App Deployer runs script to setup infra/app/both. |
| iac-ref | Contains infra resource definitions (terraform) |
| infra-tasks.yml | These contain tasks to be executed during the infra stage. |
| install-pre-requisites.sh | App Deployer runs script to setup pre-requisites to run envbuild.sh. |
| MANIFEST | Provides information about the source of the artifact. |
| modules | These are Terraform modules. |
| platform-tasks.yml | These contain tasks to be executed during the platform stage. |
| playbooks | These are Ansible Plays. |
| README.md | Contains install instructions for app deployer. |
| setup-cns-access.sh | App Deployer runs script to setup local machine with access to the created CNS cluster(s). |
Artifact Usage - Sample App Deployment
Application Deployer uses the developed artifact to deploy the app to their infrastructure env. Next steps outline how to override/configure the values and execute.
Extract the artifact in the deployment host (controller)
Below here examples for AWS package are provided. Please follow the same for Azure as well.
Install pre-requisites
Dry run script
Create config.yml
Copy from config-template.yml and override values.
Refer to dist/README.md for detailed explanation on how to configure.
config.yml
-
Provide name of VM instance. The default vm name is as below. To start a fresh deployment on a new VM, provide a different name
name: ‘audio2face3d-aws-cns’ -
Make sure to provide your machine's public IP address in access_cidrs section. or a list ip addresses to access the VM
If you have multiple IP addresses to access the VM, you can provide them as a list of IP addresses:
Additionally, add/update your CSP instance details here. For example:
You can update other sections in the config like 'backend' ..etc.
Then, export the environment variables:
Run script
Execute script to deploy and setup all components. This will setup the infra (aws ec2 instance with cns configured), and then platform level and app level helm charts to the k8s node.
dist $ ./envbuild.sh install -c all
After entire setup logs, you can expect an output like below with IPs and URLs shared at the end.
AWS:
AZURE:
Access Deployment
SSH into the master node which has kubectl configured using the commands shared in the output.
AWS Deployment
ssh -i /home/arg/.ssh/id_rsa -o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null -o ProxyCommand="ssh -i /home/arg/.ssh/id_rsa -o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null -W %h:%p ubuntu@44.246.238.111" ubuntu@10.0.1.14
Azure Deployment
ssh -i /home/arg/.ssh/id_rsa -o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null ubuntu@52.37.215.148
Once within the instance, verify the helm charts have been deployed to their respective namespaces.
Verify app setup by ensuring audio2face3d-release pods are spun up and the node-port service exposed.
Refer to the Audio2Face-3D public documentation regarding how to expose the pod IP publicly: https://docs.nvidia.com/ace/latest/modules/a2f-docs/text/deployment/kubernetes.html#optional-expose-the-pod-ip-publicly
Uninstall/Delete a Deployment
Once finished, You can uninstall the Deployment using the below command:
dist $ ./envbuild.sh uninstall -c all
NOTE:
If you see any error like below, it means a VM is already instantiated with the CIDR 216.228.112.22/32
If you already know the VM instance details, you can ssh directly from your machine.
Else if you want to create a fresh VM instance - for the same config.yml, You can just delete the instance and re-run
Usage Restrictions
You may not use the Software or any of its components for the purpose of emotion recognition. Any technology included in the Software may only be used as fully integrated in the Software and consistent with all applicable documentation.
License/Terms of Use:
GOVERNING TERMS: This software is governed by the NVIDIA Software License Agreement and Product-Specific Terms for NVIDIA AI Products. Use of the Audio2Face models is governed by the NVIDIA Open Model License. Use of the Audio2Emotion model is governed by the License Agreement for NVIDIA Audio2Emotion Model for Use with Audio2Face Project.
AUDIO2EMOTION MODEL NOTICE: This model and any technology included with this model may only be used in connection with the NVIDIA Audio2Face project consistent with all applicable documentation. You may not use this model and any technology included with it outside of the Audio2Face project. You may not use this model or any of its components for the purpose of emotion recognition.
NVIDIA believes Trustworthy AI is a shared responsibility and we have established policies and practices to enable development for a wide array of AI applications. When downloaded or used in accordance with our terms of service, developers should work with their supporting model team to ensure this model meets requirements for the relevant industry and use case and addresses unforeseen product misuse.
For more detailed information on ethical considerations for this model, please see the Model Card++ Explainability, Bias, Safety & Security, and Privacy Subcards. Please report security vulnerabilities or NVIDIA AI Concerns here.
You are responsible for ensuring that your use of NVIDIA AI Foundation Models complies with all applicable laws.