
NVIDIA
Background Noise Removal
DownloadableFree EndpointRemoves unwanted noises from audio improving speech intelligibility.
Getting Started
NVIDIA Background Noise Removal NIM uses gRPC APIs for inferencing requests. Following instructions demonstrate the usage of BNR NIM model using Python client.
Prerequisites
You will need a system with git and Python 3.10+ installed.
Setup NVIDIA BNR Python client
Download the BNR Python client code by cloning the NIM gRPC Client Repository:
git clone https://github.com/NVIDIA-Maxine/nim-clients.git
cd nim-clients/bnr
Install the dependencies for the NVIDIA BNR Python client:
sudo apt-get install python3-pip
pip install -r requirements.txt
Run Python Client
Navigate to the scripts directory.
cd scripts
Send the gRPC requests
python bnr.py --preview-mode \
--ssl-mode TLS \
--target grpc.nvcf.nvidia.com:443 \
--function-id c95bfe76-c553-4975-bc18-8ef9d6e2666b \
--api-key $NVIDIA_API_KEY \
--input <input_file_path> \
--output <output_file_path> \
--streaming False
Note the requirements for input file:
- The supported format is 16-bit mono channel wav file.
- The size limit for input file is 35 MB.
- The duration limit for input file is 6 min.
Command line arguments:
--preview-mode- Flag to send request to preview NVCF server on https://build.nvidia.com/nvidia/bnr/api.--ssl-mode- Set the SSL mode to TLS or MTLS. Defaults to no SSL. When running preview, TLS mode must be used with default root certificate.--target <ip:port>- URI of NIM's gRPC service. Use grpc.nvcf.nvidia.com:443 when hosted on NVCF. (Default:127.0.0.1:8001)--api-key $NVIDIA_API_KEY- NGC API key required for authentication. Utilized when usingTRY APIignored otherwise.--function-id <function_id>- Function ID for the feature.--input <input_file_path>- The path to the input audio file. (Default:../assets/bnr_48k_input.wav)--output <output_file_path>- The path to the output audio file. (Default:./bnr_48k_output.wav)--streaming- Flag to control if streaming or transactional mode should be used. Streaming mode will be used by default, set to False to enable transactional mode.--intensity-ratio- Intensity ratio value between 0 and 1 to control denoising intensity. Default is 1.0 (maximum denoising).
Refer the BNR NIM documentation for more information.