From 08e302257d47b7b86afd0bd97fbdacce35796632 Mon Sep 17 00:00:00 2001 From: Yingge He <157551214+yinggeh@users.noreply.github.com> Date: Thu, 12 Feb 2026 11:50:02 -0800 Subject: [PATCH] docs: Fix broken links in "Perf benchmarking and tuning" section (#8649) --- deploy/mlflow-triton-plugin/README.md | 42 +- docs/client_guide/python.rst | 5 +- docs/client_guide/python_readme.rst | 300 -------- docs/contents.rst | 6 +- ...nt_by_backend.rst => quick_deployment.rst} | 5 +- docs/getting_started/quick_start.rst | 175 ----- docs/llm_features/speculative_decoding.rst | 36 +- .../speculative_decoding_by_backend_type.rst | 39 - docs/perf_benchmark/genai-perf-README.rst | 686 ------------------ docs/perf_benchmark/genai_perf.rst | 5 +- docs/perf_benchmark/model-analyzer-README.rst | 203 ------ docs/perf_benchmark/model_analyzer.rst | 28 +- docs/perf_benchmark/perf-analyzer-README.rst | 175 ----- docs/perf_benchmark/perf_analyzer.rst | 18 +- 14 files changed, 67 insertions(+), 1656 deletions(-) delete mode 100644 docs/client_guide/python_readme.rst rename docs/getting_started/{quick_deployment_by_backend.rst => quick_deployment.rst} (95%) delete mode 100644 docs/getting_started/quick_start.rst delete mode 100644 docs/llm_features/speculative_decoding_by_backend_type.rst delete mode 100644 docs/perf_benchmark/genai-perf-README.rst delete mode 100644 docs/perf_benchmark/model-analyzer-README.rst delete mode 100644 docs/perf_benchmark/perf-analyzer-README.rst diff --git a/deploy/mlflow-triton-plugin/README.md b/deploy/mlflow-triton-plugin/README.md index c011194299..2fcfc035d5 100644 --- a/deploy/mlflow-triton-plugin/README.md +++ b/deploy/mlflow-triton-plugin/README.md @@ -1,5 +1,5 @@ - -Installation ------------- - -The easiest way to install GenAI-Perf is through `Triton Server SDK -container `__. -Install the latest release using the following command: - -.. code:: bash - - export RELEASE="yy.mm" # e.g. export RELEASE="24.06" - - docker run -it --net=host --gpus=all nvcr.io/nvidia/tritonserver:${RELEASE}-py3-sdk - - # Check out genai_perf command inside the container: - genai-perf --help - -.. raw:: html - -
- -Alternatively, to install from source: - -Since GenAI-Perf depends on Perf Analyzer, you’ll need to install the -Perf Analyzer binary: - -Install Perf Analyzer (Ubuntu, Python 3.8+) -~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - -**NOTE**: you must already have CUDA 12 installed (checkout the `CUDA -installation -guide `__). - -.. code:: bash - - pip install tritonclient - - apt update && apt install -y --no-install-recommends libb64-0d libcurl4 - -You can also build Perf Analyzer `from -source <../docs/install.md#build-from-source>`__ as well. - -Install GenAI-Perf from source -~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - -.. code:: bash - - git clone https://github.com/triton-inference-server/perf_analyzer.git && cd perf_analyzer - - pip install -e genai-perf - -.. raw:: html - -
- -.. raw:: html - - - -Quick Start ------------ - -In this quick start, we will use GenAI-Perf to run performance -benchmarking on the GPT-2 model running on Triton Inference Server with -a TensorRT-LLM engine. - -Serve GPT-2 TensorRT-LLM model using Triton CLI -~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - -You can follow the `quickstart -guide `__ -on Triton CLI github repo to run GPT-2 model locally. The full -instructions are copied below for convenience: - -.. code:: bash - - # This container comes with all of the dependencies for building TRT-LLM engines - # and serving the engine with Triton Inference Server. - docker run -ti \ - --gpus all \ - --network=host \ - --shm-size=1g --ulimit memlock=-1 \ - -v /tmp:/tmp \ - -v ${HOME}/models:/root/models \ - -v ${HOME}/.cache/huggingface:/root/.cache/huggingface \ - nvcr.io/nvidia/tritonserver:24.05-trtllm-python-py3 - - # Install the Triton CLI - pip install git+https://github.com/triton-inference-server/triton_cli.git@0.0.8 - - # Build TRT LLM engine and generate a Triton model repository pointing at it - triton remove -m all - triton import -m gpt2 --backend tensorrtllm - - # Start Triton pointing at the default model repository - triton start - -Running GenAI-Perf -~~~~~~~~~~~~~~~~~~ - -Now we can run GenAI-Perf from Triton Inference Server SDK container: - -.. code:: bash - - export RELEASE="yy.mm" # e.g. export RELEASE="24.06" - - docker run -it --net=host --rm --gpus=all nvcr.io/nvidia/tritonserver:${RELEASE}-py3-sdk - - # Run GenAI-Perf in the container: - genai-perf profile \ - -m gpt2 \ - --service-kind triton \ - --backend tensorrtllm \ - --num-prompts 100 \ - --random-seed 123 \ - --synthetic-input-tokens-mean 200 \ - --synthetic-input-tokens-stddev 0 \ - --streaming \ - --output-tokens-mean 100 \ - --output-tokens-stddev 0 \ - --output-tokens-mean-deterministic \ - --tokenizer hf-internal-testing/llama-tokenizer \ - --concurrency 1 \ - --measurement-interval 4000 \ - --profile-export-file my_profile_export.json \ - --url localhost:8001 - -Example output: - -:: - - LLM Metrics - ┏━━━━━━━━━━━━━━━━━━━━━━━━━━┳━━━━━━━━┳━━━━━━━━┳━━━━━━━━┳━━━━━━━━┳━━━━━━━━┳━━━━━━━━┓ - ┃ Statistic ┃ avg ┃ min ┃ max ┃ p99 ┃ p90 ┃ p75 ┃ - ┡━━━━━━━━━━━━━━━━━━━━━━━━━━╇━━━━━━━━╇━━━━━━━━╇━━━━━━━━╇━━━━━━━━╇━━━━━━━━╇━━━━━━━━┩ - │ Time to first token (ms) │ 11.70 │ 9.88 │ 17.21 │ 14.35 │ 12.01 │ 11.87 │ - │ Inter token latency (ms) │ 1.46 │ 1.08 │ 1.89 │ 1.87 │ 1.62 │ 1.52 │ - │ Request latency (ms) │ 161.24 │ 153.45 │ 200.74 │ 200.66 │ 179.43 │ 162.23 │ - │ Output sequence length │ 103.39 │ 95.00 │ 134.00 │ 120.08 │ 107.30 │ 105.00 │ - │ Input sequence length │ 200.01 │ 200.00 │ 201.00 │ 200.13 │ 200.00 │ 200.00 │ - └──────────────────────────┴────────┴────────┴────────┴────────┴────────┴────────┘ - Output token throughput (per sec): 635.61 - Request throughput (per sec): 6.15 - -See `Tutorial `__ for additional examples. - -.. raw:: html - - - -Visualization -------------- - -GenAI-Perf can also generate various plots that visualize the -performance of the current profile run. This is disabled by default but -users can easily enable it by passing the ``--generate-plots`` option -when running the benchmark: - -.. code:: bash - - genai-perf profile \ - -m gpt2 \ - --service-kind triton \ - --backend tensorrtllm \ - --streaming \ - --concurrency 1 \ - --generate-plots - -This will generate a `set of default -plots `__ such as: - Time to first token -(TTFT) analysis - Request latency analysis - TTFT vs Input sequence -lengths - Inter token latencies vs Token positions - Input sequence -lengths vs Output sequence lengths - -Using ``compare`` Subcommand to Visualize Multiple Runs -~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - -The ``compare`` subcommand in GenAI-Perf facilitates users in comparing -multiple profile runs and visualizing the differences through plots. - -Usage -^^^^^ - -Assuming the user possesses two profile export JSON files, namely -``profile1.json`` and ``profile2.json``, they can execute the -``compare`` subcommand using the ``--files`` option: - -.. code:: bash - - genai-perf compare --files profile1.json profile2.json - -Executing the above command will perform the following actions under the -``compare`` directory: 1. Generate a YAML configuration file -(e.g. ``config.yaml``) containing the metadata for each plot generated -during the comparison process. 2. Automatically generate the `default -set of plots `__ (e.g. TTFT vs. Input -Sequence Lengths) that compare the two profile runs. - -:: - - compare - ├── config.yaml - ├── distribution_of_input_sequence_lengths_to_output_sequence_lengths.jpeg - ├── request_latency.jpeg - ├── time_to_first_token.jpeg - ├── time_to_first_token_vs_input_sequence_lengths.jpeg - ├── token-to-token_latency_vs_output_token_position.jpeg - └── ... - -Customization -^^^^^^^^^^^^^ - -Users have the flexibility to iteratively modify the generated YAML -configuration file to suit their specific requirements. They can make -alterations to the plots according to their preferences and execute the -command with the ``--config`` option followed by the path to the -modified configuration file: - -.. code:: bash - - genai-perf compare --config compare/config.yaml - -This command will regenerate the plots based on the updated -configuration settings, enabling users to refine the visual -representation of the comparison results as per their needs. - -See `Compare documentation `__ for more details. - -.. raw:: html - - - -Model Inputs ------------- - -GenAI-Perf supports model input prompts from either synthetically -generated inputs, or from the HuggingFace -`OpenOrca `__ or -`CNN_DailyMail `__ -datasets. This is specified using the ``--input-dataset`` CLI option. - -When the dataset is synthetic, you can specify the following options: \* -``--num-prompts ``: The number of unique prompts to generate as -stimulus, >= 1. \* ``--synthetic-input-tokens-mean ``: The mean of -number of tokens in the generated prompts when using synthetic data, >= -1. \* ``--synthetic-input-tokens-stddev ``: The standard deviation -of number of tokens in the generated prompts when using synthetic data, ->= 0. \* ``--random-seed ``: The seed used to generate random -values, >= 0. - -When the dataset is coming from HuggingFace, you can specify the -following options: \* ``--input-dataset {openorca,cnn_dailymail}``: -HuggingFace dataset to use for benchmarking. \* ``--num-prompts ``: -The number of unique prompts to generate as stimulus, >= 1. - -When the dataset is coming from a file, you can specify the following -options: \* ``--input-file ``: The input file containing the -prompts to use for benchmarking as JSON objects. - -For any dataset, you can specify the following options: \* -``--output-tokens-mean ``: The mean number of tokens in each -output. Ensure the ``--tokenizer`` value is set correctly, >= 1. \* -``--output-tokens-stddev ``: The standard deviation of the number -of tokens in each output. This is only used when output-tokens-mean is -provided, >= 1. \* ``--output-tokens-mean-deterministic``: When using -``--output-tokens-mean``, this flag can be set to improve precision by -setting the minimum number of tokens equal to the requested number of -tokens. This is currently supported with the Triton service-kind. Note -that there is still some variability in the requested number of output -tokens, but GenAi-Perf attempts its best effort with your model to get -the right number of output tokens. - -You can optionally set additional model inputs with the following -option: \* ``--extra-inputs :``: An additional input -for use with the model with a singular value, such as ``stream:true`` or -``max_tokens:5``. This flag can be repeated to supply multiple extra -inputs. - -For `Large Language Models `__, there is no batch size -(i.e. batch size is always ``1``). Each request includes the inputs for -one individual inference. Other modes such as the -`embeddings `__ and `rankings `__ -endpoints support client-side batching, where ``--batch-size N`` means -that each request sent will include the inputs for ``N`` separate -inferences, allowing them to be processed together. - -.. raw:: html - - - -Metrics -------- - -GenAI-Perf collects a diverse set of metrics that captures the -performance of the inference server. - -+-----------------------+-----------------------+-----------------------+ -| Metric | Description | Aggregations | -+=======================+=======================+=======================+ -| Time to First Token | Time between when a | Avg, min, max, p99, | -| | request is sent and | p90, p75 | -| | when its first | | -| | response is received, | | -| | one value per request | | -| | in benchmark | | -+-----------------------+-----------------------+-----------------------+ -| Inter Token Latency | Time between | Avg, min, max, p99, | -| | intermediate | p90, p75 | -| | responses for a | | -| | single request | | -| | divided by the number | | -| | of generated tokens | | -| | of the latter | | -| | response, one value | | -| | per response per | | -| | request in benchmark | | -+-----------------------+-----------------------+-----------------------+ -| Request Latency | Time between when a | Avg, min, max, p99, | -| | request is sent and | p90, p75 | -| | when its final | | -| | response is received, | | -| | one value per request | | -| | in benchmark | | -+-----------------------+-----------------------+-----------------------+ -| Output Sequence | Total number of | Avg, min, max, p99, | -| Length | output tokens of a | p90, p75 | -| | request, one value | | -| | per request in | | -| | benchmark | | -+-----------------------+-----------------------+-----------------------+ -| Input Sequence Length | Total number of input | Avg, min, max, p99, | -| | tokens of a request, | p90, p75 | -| | one value per request | | -| | in benchmark | | -+-----------------------+-----------------------+-----------------------+ -| Output Token | Total number of | None–one value per | -| Throughput | output tokens from | benchmark | -| | benchmark divided by | | -| | benchmark duration | | -+-----------------------+-----------------------+-----------------------+ -| Request Throughput | Number of final | None–one value per | -| | responses from | benchmark | -| | benchmark divided by | | -| | benchmark duration | | -+-----------------------+-----------------------+-----------------------+ - -.. raw:: html - - - -Command Line Options --------------------- - -``-h`` -'''''' - -``--help`` -'''''''''' - -Show the help message and exit. - -Endpoint Options: -~~~~~~~~~~~~~~~~~ - -``-m `` -''''''''''''' - -``--model `` -'''''''''''''''''' - -The names of the models to benchmark. A single model is recommended, -unless you are `profiling multiple LoRA adapters `__. -(default: ``None``) - -``--model-selection-strategy {round_robin, random}`` -'''''''''''''''''''''''''''''''''''''''''''''''''''' - -When multiple models are specified, this is how a specific model is -assigned to a prompt. Round robin means that each model receives a -request in order. Random means that assignment is uniformly random -(default: ``round_robin``) - -``--backend {tensorrtllm,vllm}`` -'''''''''''''''''''''''''''''''' - -When using the “triton” service-kind, this is the backend of the model. -For the TRT-LLM backend, you currently must set -``exclude_input_in_output`` to true in the model config to not echo the -input tokens in the output. (default: tensorrtllm) - -``--endpoint `` -'''''''''''''''''''' - -Set a custom endpoint that differs from the OpenAI defaults. (default: -``None``) - -``--endpoint-type {chat,completions,embeddings,rankings}`` -'''''''''''''''''''''''''''''''''''''''''''''''''''''''''' - -The endpoint-type to send requests to on the server. This is only used -with the ``openai`` service-kind. (default: ``None``) - -``--service-kind {triton,openai}`` -'''''''''''''''''''''''''''''''''' - -The kind of service perf_analyzer will generate load for. In order to -use ``openai``, you must specify an api via ``--endpoint-type``. -(default: ``triton``) - -``--streaming`` -''''''''''''''' - -An option to enable the use of the streaming API. (default: ``False``) - -``-u `` -'''''''''''' - -``--url `` -''''''''''''''' - -URL of the endpoint to target for benchmarking. (default: ``None``) - -Input Options -~~~~~~~~~~~~~ - -``-b `` -'''''''''''' - -``--batch-size `` -'''''''''''''''''''''' - -The batch size of the requests GenAI-Perf should send. This is currently -only supported with the `embeddings `__, -image_retrieval, and `rankings `__ endpoint types. -(default: ``1``) - -``--extra-inputs `` -'''''''''''''''''''''''' - -Provide additional inputs to include with every request. You can repeat -this flag for multiple inputs. Inputs should be in an input_name:value -format. Alternatively, a string representing a json formatted dict can -be provided. (default: ``None``) - -``--input-dataset {openorca,cnn_dailymail}`` -'''''''''''''''''''''''''''''''''''''''''''' - -The HuggingFace dataset to use for prompts. (default: ``openorca``) - -``--input-file `` -''''''''''''''''''''''' - -The input file containing the prompts to use for profiling. Each line -should be a JSON object with a ‘text_input’ field in JSONL format. -Example: {"text_input": "Your prompt here"}" - -``--num-prompts `` -''''''''''''''''''''''' - -The number of unique prompts to generate as stimulus. (default: ``100``) - -``--output-tokens-mean `` -'''''''''''''''''''''''''''''' - -The mean number of tokens in each output. Ensure the ``--tokenizer`` -value is set correctly. (default: ``-1``) - -``--output-tokens-mean-deterministic`` -'''''''''''''''''''''''''''''''''''''' - -When using ``--output-tokens-mean``, this flag can be set to improve -precision by setting the minimum number of tokens equal to the requested -number of tokens. This is currently supported with the Triton -service-kind. Note that there is still some variability in the requested -number of output tokens, but GenAi-Perf attempts its best effort with -your model to get the right number of output tokens. (default: -``False``) - -``--output-tokens-stddev `` -'''''''''''''''''''''''''''''''' - -The standard deviation of the number of tokens in each output. This is -only used when ``--output-tokens-mean`` is provided. (default: ``0``) - -``--random-seed `` -''''''''''''''''''''''' - -The seed used to generate random values. (default: ``0``) - -``--synthetic-input-tokens-mean `` -''''''''''''''''''''''''''''''''''''''' - -The mean of number of tokens in the generated prompts when using -synthetic data. (default: ``550``) - -``--synthetic-input-tokens-stddev `` -''''''''''''''''''''''''''''''''''''''''' - -The standard deviation of number of tokens in the generated prompts when -using synthetic data. (default: ``0``) - -Profiling Options -~~~~~~~~~~~~~~~~~ - -``--concurrency `` -''''''''''''''''''''''' - -The concurrency value to benchmark. (default: ``None``) - -``--measurement-interval `` -'''''''''''''''''''''''''''''''' - -``-p `` -'''''''''''' - -The time interval used for each measurement in milliseconds. Perf -Analyzer will sample a time interval specified and take measurement over -the requests completed within that time interval. (default: ``10000``) - -``--request-rate `` -'''''''''''''''''''''''''' - -Sets the request rate for the load generated by PA. (default: ``None``) - -``-s `` -'''''''''''''' - -``--stability-percentage `` -'''''''''''''''''''''''''''''''''' - -The allowed variation in latency measurements when determining if a -result is stable. The measurement is considered as stable if the ratio -of max / min from the recent 3 measurements is within (stability -percentage) in terms of both infer per second and latency. (default: -``999``) - -Output Options -~~~~~~~~~~~~~~ - -``--artifact-dir`` -'''''''''''''''''' - -The directory to store all the (output) artifacts generated by -GenAI-Perf and Perf Analyzer. (default: ``artifacts``) - -``--generate-plots`` -'''''''''''''''''''' - -An option to enable the generation of plots. (default: False) - -``--profile-export-file `` -'''''''''''''''''''''''''''''''' - -The path where the perf_analyzer profile export will be generated. By -default, the profile export will be to ``profile_export.json``. The -genai-perf files will be exported to -``_genai_perf.json`` and -``_genai_perf.csv``. For example, if the profile -export file is ``profile_export.json``, the genai-perf file will be -exported to ``profile_export_genai_perf.csv``. (default: -``profile_export.json``) - -Other Options -~~~~~~~~~~~~~ - -``--tokenizer `` -''''''''''''''''''''' - -The HuggingFace tokenizer to use to interpret token metrics from prompts -and responses. (default: ``hf-internal-testing/llama-tokenizer``) - -``-v`` -'''''' - -``--verbose`` -''''''''''''' - -An option to enable verbose mode. (default: ``False``) - -``--version`` -''''''''''''' - -An option to print the version and exit. - -.. raw:: html - - - -Known Issues ------------- - -- GenAI-Perf can be slow to finish if a high request-rate is provided -- Token counts may not be exact diff --git a/docs/perf_benchmark/genai_perf.rst b/docs/perf_benchmark/genai_perf.rst index 175662477f..65de2d8ce1 100644 --- a/docs/perf_benchmark/genai_perf.rst +++ b/docs/perf_benchmark/genai_perf.rst @@ -1,5 +1,5 @@ .. -.. Copyright 2024-2025, NVIDIA CORPORATION & AFFILIATES. All rights reserved. +.. Copyright 2024-2026, NVIDIA CORPORATION & AFFILIATES. All rights reserved. .. .. Redistribution and use in source and binary forms, with or without .. modification, are permitted provided that the following conditions @@ -28,13 +28,12 @@ #### GenAI Performance Analyzer #### -.. include:: genai-perf-README.rst - .. toctree:: :maxdepth: 1 :hidden: + Overview <../perf_analyzer/genai-perf/README.md> Large language models <../perf_analyzer/genai-perf/docs/tutorial.md> Visual language models <../perf_analyzer/genai-perf/docs/multi_modal.md> Embedding models <../perf_analyzer/genai-perf/docs/embeddings.md> diff --git a/docs/perf_benchmark/model-analyzer-README.rst b/docs/perf_benchmark/model-analyzer-README.rst deleted file mode 100644 index f31e7ca633..0000000000 --- a/docs/perf_benchmark/model-analyzer-README.rst +++ /dev/null @@ -1,203 +0,0 @@ -.. -.. Copyright 2024-2025, NVIDIA CORPORATION & AFFILIATES. All rights reserved. -.. -.. Redistribution and use in source and binary forms, with or without -.. modification, are permitted provided that the following conditions -.. are met: -.. * Redistributions of source code must retain the above copyright -.. notice, this list of conditions and the following disclaimer. -.. * Redistributions in binary form must reproduce the above copyright -.. notice, this list of conditions and the following disclaimer in the -.. documentation and/or other materials provided with the distribution. -.. * Neither the name of NVIDIA CORPORATION nor the names of its -.. contributors may be used to endorse or promote products derived -.. from this software without specific prior written permission. -.. -.. THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS ``AS IS'' AND ANY -.. EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE -.. IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR -.. PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR -.. CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, -.. EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, -.. PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR -.. PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY -.. OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -.. (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -.. OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - -.. raw:: html - - -|License| - -Triton Model Analyzer -===================== - - [!Warning] - - .. rubric:: LATEST RELEASE - :name: latest-release - - You are currently on the ``main`` branch which tracks - under-development progress towards the next release. The latest - release of the Triton Model Analyzer is 1.42.0 and is available on - branch - `r24.07 `__. - -Triton Model Analyzer is a CLI tool which can help you find a more -optimal configuration, on a given piece of hardware, for single, -multiple, ensemble, or BLS models running on a `Triton Inference -Server `__. Model -Analyzer will also generate reports to help you better understand the -trade-offs of the different configurations along with their compute and -memory requirements. - -Features -======== - -Search Modes -~~~~~~~~~~~~ - -- `Optuna Search `__ **-ALPHA - RELEASE-** allows you to search for every parameter that can be - specified in the model configuration, using a hyperparameter - optimization framework. Please see the - `Optuna `__ website if you are interested in - specific details on how the algorithm functions. - -- `Quick Search `__ will - **sparsely** search the `Max Batch - Size `__, - `Dynamic - Batching `__, - and `Instance - Group `__ - spaces by utilizing a heuristic hill-climbing algorithm to help you - quickly find a more optimal configuration - -- `Automatic Brute - Search `__ will - **exhaustively** search the `Max Batch - Size `__, - `Dynamic - Batching `__, - and `Instance - Group `__ - parameters of your model configuration - -- `Manual Brute Search `__ - allows you to create manual sweeps for every parameter that can be - specified in the model configuration - -Model Types -~~~~~~~~~~~ - -- `Ensemble `__: Model Analyzer can help - you find the optimal settings when profiling an ensemble model - -- `BLS `__: Model Analyzer can help you find - the optimal settings when profiling a BLS model - -- `Multi-Model `__: Model Analyzer can - help you find the optimal settings when profiling multiple concurrent - models - -- `LLM `__: Model Analyzer can help you find - the optimal settings when profiling Large Language Models - -Other Features -~~~~~~~~~~~~~~ - -- `Detailed and summary reports `__: Model Analyzer is - able to generate summarized and detailed reports that can help you - better understand the trade-offs between different model - configurations that can be used for your model. - -- `QoS Constraints `__: Constraints can help - you filter out the Model Analyzer results based on your QoS - requirements. For example, you can specify a latency budget to filter - out model configurations that do not satisfy the specified latency - threshold. - -Examples and Tutorials -====================== - -**Single Model** -~~~~~~~~~~~~~~~~ - -See the `Single Model Quick Start `__ for a guide -on how to use Model Analyzer to profile, analyze and report on a simple -PyTorch model. - -**Multi Model** -~~~~~~~~~~~~~~~ - -See the `Multi-model Quick Start `__ for a guide -on how to use Model Analyzer to profile, analyze and report on two -models running concurrently on the same GPU. - -**Ensemble Model** -~~~~~~~~~~~~~~~~~~ - -See the `Ensemble Model Quick Start `__ -for a guide on how to use Model Analyzer to profile, analyze and report -on a simple Ensemble model. - -**BLS Model** -~~~~~~~~~~~~~ - -See the `BLS Model Quick Start `__ for a guide -on how to use Model Analyzer to profile, analyze and report on a simple -BLS model. - -Documentation -============= - -- `Installation `__ -- `Model Analyzer CLI `__ -- `Launch Modes `__ -- `Configuring Model Analyzer `__ -- `Model Analyzer Metrics `__ -- `Model Config Search `__ -- `Model Types `__ -- `Checkpointing `__ -- `Model Analyzer Reports `__ -- `Deployment with Kubernetes `__ - -Terminology -=========== - -Below are definitions of some commonly used terms in Model Analyzer: - -- **Model Type** - Category of model being profiled. Examples of this - include single, multi, ensemble, BLS, etc.. -- **Search Mode** - How Model Analyzer explores the possible - configuration space when profiling. This is either exhaustive (brute) - or heuristic (quick/optuna). -- **Model Config Search** - The cross product of model type and search - mode. -- **Launch Mode** - How the Triton Server is deployed and used by Model - Analyzer. - -Reporting problems, asking questions -==================================== - -We appreciate any feedback, questions or bug reporting regarding this -project. When help with code is needed, follow the process outlined in -the Stack Overflow (https://stackoverflow.com/help/mcve) document. -Ensure posted examples are: - -- minimal – use as little code as possible that still produces the same - problem - -- complete – provide all parts needed to reproduce the problem. Check - if you can strip external dependency and still show the problem. The - less time we spend on reproducing problems the more time we have to - fix it - -- verifiable – test the code you’re about to provide to make sure it - reproduces the problem. Remove all other problems that are not - related to your request/question. - -.. |License| image:: https://img.shields.io/badge/License-Apache_2.0-lightgrey.svg - :target: https://opensource.org/licenses/Apache-2.0 diff --git a/docs/perf_benchmark/model_analyzer.rst b/docs/perf_benchmark/model_analyzer.rst index c29a96aa92..a3c734ce30 100644 --- a/docs/perf_benchmark/model_analyzer.rst +++ b/docs/perf_benchmark/model_analyzer.rst @@ -1,5 +1,5 @@ .. -.. Copyright 2024-2025, NVIDIA CORPORATION & AFFILIATES. All rights reserved. +.. Copyright 2024-2026, NVIDIA CORPORATION & AFFILIATES. All rights reserved. .. .. Redistribution and use in source and binary forms, with or without .. modification, are permitted provided that the following conditions @@ -29,17 +29,23 @@ Model Analyzer #### -.. include:: model-analyzer-README.rst - .. toctree:: :maxdepth: 1 :hidden: - ../model_analyzer/docs/cli.md - ../model_analyzer/docs/launch_modes.md - ../model_analyzer/docs/config.md - ../model_analyzer/docs/metrics.md - ../model_analyzer/docs/config_search.md - ../model_analyzer/docs/checkpoints.md - ../model_analyzer/docs/report.md - ../model_analyzer/docs/kubernetes_deploy.md \ No newline at end of file + Overview <../model_analyzer/README.md> + Documentation <../model_analyzer/docs/README.md> + Quick Start <../model_analyzer/docs/quick_start.md> + Installation <../model_analyzer/docs/install.md> + CLI Reference <../model_analyzer/docs/cli.md> + Launch Modes <../model_analyzer/docs/launch_modes.md> + Configuration <../model_analyzer/docs/config.md> + Configuration Search <../model_analyzer/docs/config_search.md> + Metrics <../model_analyzer/docs/metrics.md> + Checkpointing <../model_analyzer/docs/checkpoints.md> + Reports <../model_analyzer/docs/report.md> + Kubernetes <../model_analyzer/docs/kubernetes_deploy.md> + Model Types <../model_analyzer/docs/model_types.md> + Ensemble Model <../model_analyzer/docs/ensemble_quick_start.md> + BLS Model <../model_analyzer/docs/bls_quick_start.md> + Multi-Model <../model_analyzer/docs/mm_quick_start.md> \ No newline at end of file diff --git a/docs/perf_benchmark/perf-analyzer-README.rst b/docs/perf_benchmark/perf-analyzer-README.rst deleted file mode 100644 index df9c246eb3..0000000000 --- a/docs/perf_benchmark/perf-analyzer-README.rst +++ /dev/null @@ -1,175 +0,0 @@ -.. -.. Copyright 2024-2025, NVIDIA CORPORATION & AFFILIATES. All rights reserved. -.. -.. Redistribution and use in source and binary forms, with or without -.. modification, are permitted provided that the following conditions -.. are met: -.. * Redistributions of source code must retain the above copyright -.. notice, this list of conditions and the following disclaimer. -.. * Redistributions in binary form must reproduce the above copyright -.. notice, this list of conditions and the following disclaimer in the -.. documentation and/or other materials provided with the distribution. -.. * Neither the name of NVIDIA CORPORATION nor the names of its -.. contributors may be used to endorse or promote products derived -.. from this software without specific prior written permission. -.. -.. THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS ``AS IS'' AND ANY -.. EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE -.. IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR -.. PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR -.. CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, -.. EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, -.. PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR -.. PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY -.. OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -.. (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -.. OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - -.. raw:: html - - -Triton Performance Analyzer -=========================== - -Triton Performance Analyzer is CLI tool which can help you optimize the -inference performance of models running on Triton Inference Server by -measuring changes in performance as you experiment with different -optimization strategies. - -Features -======== - -Inference Load Modes -~~~~~~~~~~~~~~~~~~~~ - -- `Concurrency Mode `__ - simlulates load by maintaining a specific concurrency of outgoing - requests to the server - -- `Request Rate - Mode `__ simulates - load by sending consecutive requests at a specific rate to the server - -- `Custom Interval - Mode `__ simulates - load by sending consecutive requests at specific intervals to the - server - -Performance Measurement Modes -~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - -- `Time Windows Mode `__ - measures model performance repeatedly over a specific time interval - until performance has stabilized - -- `Count Windows Mode `__ - measures model performance repeatedly over a specific number of - requests until performance has stabilized - -Other Features -~~~~~~~~~~~~~~ - -- `Sequence Models <../user_guide/architecture.md#stateful-models>`__, - `Ensemble Models <../user_guide/architecture.md#ensemble-models>`__, - and `Decoupled Models <../user_guide/decoupled_models.md>`__ can be - profiled in addition to standard/stateless/coupled models - -- `Input Data `__ to model inferences can be - auto-generated or specified as well as verifying output - -Quick Start -=========== - -The steps below will guide you on how to start using Perf Analyzer. - -Step 1: Start Triton Container -~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - -.. code:: bash - - export RELEASE= # e.g. to use the release from the end of February of 2023, do `export RELEASE=23.02` - - docker pull nvcr.io/nvidia/tritonserver:${RELEASE}-py3 - - docker run --gpus all --rm -it --net host nvcr.io/nvidia/tritonserver:${RELEASE}-py3 - -Step 2: Download ``simple`` Model -~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - -.. code:: bash - - # inside triton container - git clone --depth 1 https://github.com/triton-inference-server/server - - mkdir model_repository ; cp -r server/docs/examples/model_repository/simple model_repository - -Step 3: Start Triton Server -~~~~~~~~~~~~~~~~~~~~~~~~~~~ - -.. code:: bash - - # inside triton container - tritonserver --model-repository $(pwd)/model_repository &> server.log & - - # confirm server is ready, look for 'HTTP/1.1 200 OK' - curl -v localhost:8000/v2/health/ready - - # detach (CTRL-p CTRL-q) - -Step 4: Start Triton SDK Container -~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - -.. code:: bash - - docker pull nvcr.io/nvidia/tritonserver:${RELEASE}-py3-sdk - - docker run --gpus all --rm -it --net host nvcr.io/nvidia/tritonserver:${RELEASE}-py3-sdk - -Step 5: Run Perf Analyzer -~~~~~~~~~~~~~~~~~~~~~~~~~ - -.. code:: bash - - # inside sdk container - perf_analyzer -m simple - -See the full `quick start guide `__ for additional -tips on how to analyze output. - -Documentation -============= - -- `Installation `__ -- `Perf Analyzer CLI `__ -- `Inference Load Modes `__ -- `Input Data `__ -- `Measurements & Metrics `__ -- `Benchmarking `__ - -Contributing -============ - -Contributions to Triton Perf Analyzer are more than welcome. To -contribute please review the `contribution -guidelines `__, -then fork and create a pull request. - -Reporting problems, asking questions -==================================== - -We appreciate any feedback, questions or bug reporting regarding this -project. When help with code is needed, follow the process outlined in -the Stack Overflow (https://stackoverflow.com/help/mcve) document. -Ensure posted examples are: - -- minimal - use as little code as possible that still produces the same - problem - -- complete - provide all parts needed to reproduce the problem. Check - if you can strip external dependency and still show the problem. The - less time we spend on reproducing problems the more time we have to - fix it - -- verifiable - test the code you’re about to provide to make sure it - reproduces the problem. Remove all other problems that are not - related to your request/question. diff --git a/docs/perf_benchmark/perf_analyzer.rst b/docs/perf_benchmark/perf_analyzer.rst index d6c6156a62..fcb25e0ca8 100644 --- a/docs/perf_benchmark/perf_analyzer.rst +++ b/docs/perf_benchmark/perf_analyzer.rst @@ -1,5 +1,5 @@ .. -.. Copyright 2024-2025, NVIDIA CORPORATION & AFFILIATES. All rights reserved. +.. Copyright 2024-2026, NVIDIA CORPORATION & AFFILIATES. All rights reserved. .. .. Redistribution and use in source and binary forms, with or without .. modification, are permitted provided that the following conditions @@ -29,14 +29,16 @@ Performance Analyzer #### -.. include:: perf-analyzer-README.rst - .. toctree:: :maxdepth: 1 :hidden: - ../perf_analyzer/docs/install.md - ../perf_analyzer/docs/CLI.md - ../perf_analyzer/docs/inference_load_modes.md - ../perf_analyzer/docs/input_data.md - ../perf_analyzer/docs/measurements_metrics.md \ No newline at end of file + Overview <../perf_analyzer/README.md> + Documentation <../perf_analyzer/docs/README.md> + Quick Start <../perf_analyzer/docs/quick_start.md> + Installation <../perf_analyzer/docs/install.md> + CLI Reference <../perf_analyzer/docs/cli.md> + Inference Load Modes <../perf_analyzer/docs/inference_load_modes.md> + Input Data <../perf_analyzer/docs/input_data.md> + Measurement Modes <../perf_analyzer/docs/measurements_metrics.md> + Benchmarking <../perf_analyzer/docs/benchmarking.md> \ No newline at end of file