Yolo 비전 선전
선전
지금 참여하기
용어집

TensorRT

NVIDIA GPU에서 더 빠르고 효율적인 추론을 위해 TensorRT 딥 러닝 모델을 최적화하세요. YOLO 및 AI 애플리케이션으로 실시간 성능을 달성하세요.

TensorRT is a high-performance deep learning inference software development kit (SDK) developed by NVIDIA. It is designed to optimize neural network models for deployment, delivering low inference latency and high throughput for deep learning applications. By acting as an optimization compiler, TensorRT takes trained networks from popular frameworks like PyTorch and TensorFlow and restructures them to execute efficiently on NVIDIA GPUs. This capability is crucial for running complex AI models in production environments where speed and efficiency are paramount.

How TensorRT Optimizes Models

The core function of TensorRT is to convert a trained neural network into an optimized "engine" specifically tuned for the target hardware. It achieves this through several advanced techniques:

  • Layer Fusion: The optimizer combines multiple layers of a neural network into a single kernel, reducing memory access overhead and improving execution speed.
  • Precision Calibration: TensorRT supports reduced precision modes, such as mixed precision (FP16) and integer quantization (INT8). By reducing the number of bits used to represent numbers—often with minimal accuracy loss—developers can significantly accelerate math operations and reduce memory usage. This is a form of model quantization.
  • Kernel Auto-Tuning: The software automatically selects the best data layers and algorithms for the specific GPU architecture being used, ensuring maximum utilization of the hardware's parallel processing capabilities via CUDA.

실제 애플리케이션

TensorRT 최소한의 지연으로 방대한 양의 데이터를 처리할 수 있는 능력 덕분에 컴퓨터 비전과 복잡한 AI 작업에 의존하는 산업 분야에서 시간이 매우 중요한 상황에서 널리 채택되고 TensorRT .

  1. 자율 시스템: 자동차 AI 분야에서 자율주행차는 detect , 표지판, 장애물을 즉시 detect 위해 여러 카메라의 영상 데이터를 처리해야 합니다. TensorRT 사용하면 객체 탐지 네트워크 같은 인지 모델이 프레임을 밀리초 단위로 분석할 수 있어 차량 제어 시스템이 지연 없이 안전에 중요한 결정을 내릴 수 있습니다.
  2. 산업 자동화: 현대식 공장은 제조 과정에서 인공지능을 활용해 자동화된 광학 검사를 수행합니다. 고속 카메라가 조립 라인 위 제품의 이미지를 포착하면, TensorRT 모델이 결함이나 이상을 실시간으로 식별합니다. 이를 통해 품질 관리가 고속 생산 환경에 발맞출 수 있으며, NVIDIA 플랫폼과 같은 에지 AI 장치를 공장 현장에 직접 배치하는 경우가 많습니다.

Ultralytics TensorRT YOLO TensorRT 사용하기

최신 AI 도구를 사용하면 워크플로에 TensorRT 간편하게 통합할 수 있습니다. 그리고 ultralytics package provides a seamless method to convert standard PyTorch models into TensorRT engines. This allows users to leverage the state-of-the-art architecture of Ultralytics YOLO26 with the hardware acceleration of NVIDIA GPUs. For teams looking to manage their datasets and training pipelines before export, the Ultralytics 플랫폼 offers a comprehensive environment to prepare models for such high-performance deployment.

다음 예제는 YOLO26 모델을 TensorRT 파일로 내보내는 방법을 보여줍니다..engine) 그리고 사용하기 위해 실시간 추론:

from ultralytics import YOLO

# Load the latest stable YOLO26 model (nano size)
model = YOLO("yolo26n.pt")

# Export the model to TensorRT format (creates 'yolo26n.engine')
# This step optimizes the computational graph for your specific GPU
model.export(format="engine")

# Load the optimized TensorRT engine for high-speed inference
trt_model = YOLO("yolo26n.engine")

# Run inference on an image source
results = trt_model("https://ultralytics.com/images/bus.jpg")

TensorRT vs. ONNX vs. Training Frameworks

It is important to distinguish TensorRT from other terms often heard in the model deployment landscape:

  • Vs. PyTorch/TensorFlow: Frameworks like PyTorch are primarily designed for model training and research, offering flexibility and ease of debugging. TensorRT is an inference engine designed solely for executing trained models as fast as possible. It is not used for training.
  • Vs. ONNX: The ONNX (Open Neural Network Exchange) format acts as an intermediary bridge between frameworks. While ONNX provides interoperability (e.g., moving a model from PyTorch to another platform), TensorRT focuses on hardware-specific optimization. Often, a model is converted to ONNX first, and then parsed by TensorRT to generate the final engine.

For developers aiming to maximize the performance of their AI agents or vision systems, understanding the transition from a training framework to an optimized runtime like TensorRT is a key step in professional MLOps.

Ultralytics 커뮤니티 가입

AI의 미래에 동참하세요. 글로벌 혁신가들과 연결하고, 협력하고, 성장하세요.

지금 참여하기