Quickstart Guide
Start NIM
This page assumes you have installed and set up Prerequisite Software (Docker, NGC CLI, NGC registry access).
- Export
NGC_CLI_API_KEYvariable.
- NIM container automatically downloads models. To save time and bandwidth it is recommended to provide local cache directory. This way NIM will be able to reuse already downloaded models. Execute following command to setup cache directory.
- Run the NIM container with the following commands.
This command will start the NIM container and expose port 8000 for the user to interact with the NIM.
- Open a new terminal, leaving the terminal open with the just launched service. In the new terminal, wait until the health check end point returns
{"status":"ready"}before proceeding. This may take a couple of minutes. You can use the following command to query the health check.
Python client example
- Save following Python example to a file named
nim_client.py.
- Execute the example.
- The NIM saves results to the
output.fafile in Multi-FASTA format. You can quickly view the file using the following command.
Shell client example
- Save the following Shell example to a file named
nim_client.sh.
- Execute the example.
- The NIM displays the results to the terminal in JSON format. You can configure the NIM to display the results, scores, and probabilities in the Multi-FASTA output format.