Zum Inhalt springen

How to Export to PaddlePaddle Format from YOLO11 Models

Bridging the gap between developing and deploying computer vision models in real-world scenarios with varying conditions can be difficult. PaddlePaddle makes this process easier with its focus on flexibility, performance, and its capability for parallel processing in distributed environments. This means you can use your YOLO11 computer vision models on a wide variety of devices and platforms, from smartphones to cloud-based servers.



Pass auf: How to Export Ultralytics YOLO11 Models to PaddlePaddle Format | Key Features of PaddlePaddle Format

The ability to export to PaddlePaddle model format allows you to optimize your Ultralytics YOLO11 models for use within the PaddlePaddle framework. PaddlePaddle is known for facilitating industrial deployments and is a good choice for deploying computer vision applications in real-world settings across various domains.

Warum solltest du auf PaddlePaddle exportieren?

PaddlePaddle Logo

Developed by Baidu, PaddlePaddle (PArallel Distributed Deep LEarning) is China's first open-source deep learning platform. Unlike some frameworks built mainly for research, PaddlePaddle prioritizes ease of use and smooth integration across industries.

It offers tools and resources similar to popular frameworks like TensorFlow and PyTorch, making it accessible for developers of all experience levels. From farming and factories to service businesses, PaddlePaddle's large developer community of over 4.77 million is helping create and deploy AI applications.

By exporting your Ultralytics YOLO11 models to PaddlePaddle format, you can tap into PaddlePaddle's strengths in performance optimization. PaddlePaddle prioritizes efficient model execution and reduced memory usage. As a result, your YOLO11 models can potentially achieve even better performance, delivering top-notch results in practical scenarios.

Die wichtigsten Merkmale der PaddlePaddle Modelle

PaddlePaddle Modelle bieten eine Reihe von Schlüsselfunktionen, die zu ihrer Flexibilität, Leistung und Skalierbarkeit in verschiedenen Einsatzszenarien beitragen:

  • Dynamischer-zu-statischer Graph: PaddlePaddle unterstützt die dynamische-zu-statische Kompilierung, bei der Modelle in einen statischen Berechnungsgraphen übersetzt werden können. Dies ermöglicht Optimierungen, die den Laufzeit-Overhead reduzieren und die Inferenzleistung erhöhen.

  • Operator Fusion: PaddlePaddle Wie TensorRT nutzt auch das Framework Operator Fusion, um Berechnungen zu rationalisieren und den Overhead zu reduzieren. Durch die Zusammenlegung kompatibler Operationen werden Speicherübertragungen und Rechenschritte minimiert, was zu schnelleren Schlussfolgerungen führt.

  • Quantisierung: PaddlePaddle unterstützt Quantisierungstechniken, einschließlich Quantisierung nach dem Training und quantisierungsorientiertes Training. Diese Techniken ermöglichen die Verwendung von Datenrepräsentationen mit geringerer Genauigkeit, wodurch die Leistung effektiv gesteigert und die Modellgröße verringert wird.

Einsatzoptionen in PaddlePaddle

Before diving into the code for exporting YOLO11 models to PaddlePaddle, let's take a look at the different deployment scenarios in which PaddlePaddle models excel.

PaddlePaddle bietet eine Reihe von Optionen, von denen jede ein ausgewogenes Verhältnis von Benutzerfreundlichkeit, Flexibilität und Leistung bietet:

  • Paddle Serving: Dieses Framework vereinfacht die Bereitstellung von PaddlePaddle Modellen als leistungsstarke RESTful APIs. Paddle Serving ist ideal für Produktionsumgebungen und bietet Funktionen wie Modellversionierung, Online-A/B-Tests und Skalierbarkeit für die Verarbeitung großer Mengen von Anfragen.

  • Paddle Inference API: Mit der Paddle Inference API kannst du die Ausführung des Modells auf niedriger Ebene steuern. Diese Option eignet sich gut für Szenarien, in denen du das Modell eng in eine benutzerdefinierte Anwendung integrieren oder die Leistung für bestimmte Hardware optimieren musst.

  • Paddle Lite: Paddle Lite wurde für den Einsatz auf mobilen und eingebetteten Geräten entwickelt, wo die Ressourcen begrenzt sind. Es optimiert die Modelle für kleinere Größen und schnellere Inferenzen auf ARM-CPUs, GPUs und anderer Spezialhardware.

  • Paddle.js: Paddle.js ermöglicht es dir, PaddlePaddle Modelle direkt im Webbrowser einzusetzen. Paddle.js kann entweder ein vortrainiertes Modell laden oder ein Modell von paddle-hub mit den von Paddle.js bereitgestellten Modellumwandlungswerkzeugen umwandeln. Es kann in Browsern ausgeführt werden, die WebGL/WebGPU/WebAssembly unterstützen.

Export to PaddlePaddle: Converting Your YOLO11 Model

Converting YOLO11 models to the PaddlePaddle format can improve execution flexibility and optimize performance for various deployment scenarios.

Installation

Um das benötigte Paket zu installieren, führe es aus:

Installation

# Install the required package for YOLO11
pip install ultralytics

For detailed instructions and best practices related to the installation process, check our Ultralytics Installation guide. While installing the required packages for YOLO11, if you encounter any difficulties, consult our Common Issues guide for solutions and tips.

Verwendung

Before diving into the usage instructions, it's important to note that while all Ultralytics YOLO11 models are available for exporting, you can ensure that the model you select supports export functionality here.

Verwendung

from ultralytics import YOLO

# Load the YOLO11 model
model = YOLO("yolo11n.pt")

# Export the model to PaddlePaddle format
model.export(format="paddle")  # creates '/yolo11n_paddle_model'

# Load the exported PaddlePaddle model
paddle_model = YOLO("./yolo11n_paddle_model")

# Run inference
results = paddle_model("https://ultralytics.com/images/bus.jpg")
# Export a YOLO11n PyTorch model to PaddlePaddle format
yolo export model=yolo11n.pt format=paddle  # creates '/yolo11n_paddle_model'

# Run inference with the exported model
yolo predict model='./yolo11n_paddle_model' source='https://ultralytics.com/images/bus.jpg'

Weitere Details zu den unterstützten Exportoptionen findest du auf der Ultralytics Dokumentationsseite zu den Bereitstellungsoptionen.

Deploying Exported YOLO11 PaddlePaddle Models

After successfully exporting your Ultralytics YOLO11 models to PaddlePaddle format, you can now deploy them. The primary and recommended first step for running a PaddlePaddle model is to use the YOLO("./model_paddle_model") method, as outlined in the previous usage code snippet.

Ausführliche Anleitungen für den Einsatz deiner PaddlePaddle Modelle in verschiedenen anderen Umgebungen findest du in den folgenden Ressourcen:

  • Paddeln Servieren: Lerne, wie du deine PaddlePaddle Modelle mit Paddle Serving als performante Dienste bereitstellst.

  • Paddel Lite: Erfahre, wie du mit Paddle Lite Modelle auf mobilen und eingebetteten Geräten optimieren und einsetzen kannst.

  • Paddel.js: Entdecke, wie du mit Paddle.js PaddlePaddle Modelle in Webbrowsern für client-seitige KI ausführen kannst.

Zusammenfassung

In this guide, we explored the process of exporting Ultralytics YOLO11 models to the PaddlePaddle format. By following these steps, you can leverage PaddlePaddle's strengths in diverse deployment scenarios, optimizing your models for different hardware and software environments.

Weitere Einzelheiten zur Verwendung findest du in der offiziellen DokumentationPaddlePaddle

Want to explore more ways to integrate your Ultralytics YOLO11 models? Our integration guide page explores various options, equipping you with valuable resources and insights.

FAQ

How do I export Ultralytics YOLO11 models to PaddlePaddle format?

Exporting Ultralytics YOLO11 models to PaddlePaddle format is straightforward. You can use the export Methode der Klasse YOLO , um diesen Export durchzuführen. Hier ist ein Beispiel mit Python:

Verwendung

from ultralytics import YOLO

# Load the YOLO11 model
model = YOLO("yolo11n.pt")

# Export the model to PaddlePaddle format
model.export(format="paddle")  # creates '/yolo11n_paddle_model'

# Load the exported PaddlePaddle model
paddle_model = YOLO("./yolo11n_paddle_model")

# Run inference
results = paddle_model("https://ultralytics.com/images/bus.jpg")
# Export a YOLO11n PyTorch model to PaddlePaddle format
yolo export model=yolo11n.pt format=paddle  # creates '/yolo11n_paddle_model'

# Run inference with the exported model
yolo predict model='./yolo11n_paddle_model' source='https://ultralytics.com/images/bus.jpg'

Ausführlichere Informationen zur Einrichtung und Fehlerbehebung findest du in der Ultralytics Installationsanleitung und im Leitfaden für häufige Probleme.

What are the advantages of using PaddlePaddle for model deployment?

PaddlePaddle bietet mehrere entscheidende Vorteile für den Einsatz von Modellen:

  • Leistungsoptimierung: PaddlePaddle zeichnet sich durch eine effiziente Modellausführung und einen geringeren Speicherbedarf aus.
  • Dynamisch-statische Graph-Kompilierung: Sie unterstützt die Kompilierung von dynamisch zu statisch und ermöglicht so Laufzeitoptimierungen.
  • Operator Fusion: Durch das Zusammenführen kompatibler Operationen wird der Rechenaufwand reduziert.
  • Quantization Techniques: Supports both post-training and quantization-aware training, enabling lower-precision data representations for improved performance.

You can achieve enhanced results by exporting your Ultralytics YOLO11 models to PaddlePaddle, ensuring flexibility and high performance across various applications and hardware platforms. Learn more about PaddlePaddle's features here.

Why should I choose PaddlePaddle for deploying my YOLO11 models?

PaddlePaddle, developed by Baidu, is optimized for industrial and commercial AI deployments. Its large developer community and robust framework provide extensive tools similar to TensorFlow and PyTorch. By exporting your YOLO11 models to PaddlePaddle, you leverage:

  • Verbesserte Leistung: Optimale Ausführungsgeschwindigkeit und geringerer Speicherbedarf.
  • Flexibilität: Breite Kompatibilität mit verschiedenen Geräten von Smartphones bis zu Cloud-Servern.
  • Skalierbarkeit: Effiziente Parallelverarbeitungsfunktionen für verteilte Umgebungen.

These features make PaddlePaddle a compelling choice for deploying YOLO11 models in production settings.

Wie verbessert PaddlePaddle die Modellleistung gegenüber anderen Frameworks?

PaddlePaddle setzt mehrere fortschrittliche Techniken ein, um die Leistung des Modells zu optimieren:

  • Dynamisch-statischer Graph: Konvertiert Modelle in einen statischen Berechnungsgraphen für Laufzeitoptimierungen.
  • Operator Fusion: Kombiniert kompatible Operationen, um die Speicherübertragung zu minimieren und die Schlussfolgerungsgeschwindigkeit zu erhöhen.
  • Quantization: Reduces model size and increases efficiency using lower-precision data while maintaining accuracy.

These techniques prioritize efficient model execution, making PaddlePaddle an excellent option for deploying high-performance YOLO11 models. For more on optimization, see the PaddlePaddle official documentation.

What deployment options does PaddlePaddle offer for YOLO11 models?

PaddlePaddle bietet flexible Einsatzmöglichkeiten:

  • Paddle Serving: Stellt Modelle als RESTful APIs bereit, ideal für die Produktion mit Funktionen wie Modellversionierung und Online-A/B-Tests.
  • Paddle Inference API: Ermöglicht die Steuerung der Modellausführung auf niedriger Ebene für benutzerdefinierte Anwendungen.
  • Paddle Lite: Optimiert die Modelle für die begrenzten Ressourcen von mobilen und eingebetteten Geräten.
  • Paddle.js: Ermöglicht den Einsatz von Modellen direkt im Webbrowser.

Diese Optionen decken ein breites Spektrum an Einsatzszenarien ab, von der Inferenz auf dem Gerät bis hin zu skalierbaren Cloud-Diensten. Weitere Einsatzstrategien findest du auf der SeiteUltralytics Einsatzoptionen für das Modell.

📅 Created 7 months ago ✏️ Updated 22 days ago

Kommentare