Ultralytics Explorer
Seit ultralytics>=8.3.12 ist Ultralytics Explorer nicht mehr verfügbar. Um Explorer zu verwenden, installiere pip install ultralytics==8.3.11. Ähnliche und erweiterte Funktionen zur Erkundung von Datensätzen findest du auf der Ultralytics Platform.
Ultralytics Explorer ist ein Werkzeug zum Erkunden von CV-Datensätzen mithilfe von semantischer Suche, SQL-Abfragen, Vektorähnlichkeitssuche und natürlichsprachlichen Eingaben. Außerdem bietet es eine Python-API für den Zugriff auf dieselben Funktionen.
Ansehen: Ultralytics Explorer API | Semantische Suche, SQL-Abfragen und KI-Abfragefunktionen
Installation optionaler Abhängigkeiten#
Explorer benötigt für einige Funktionen externe Bibliotheken. Diese werden automatisch installiert, wenn du Explorer verwendest. Um diese Abhängigkeiten manuell zu installieren, führe den folgenden Befehl aus:
pip install "ultralytics[explorer]==8.3.11"Explorer basiert auf Einbettungs- und semantischer Suche sowie SQL-Abfragen und nutzt die serverlose Vektordatenbank LanceDB. Anders als herkömmliche In-Memory-Datenbanken werden die Daten auf der Festplatte gespeichert, ohne dass die Leistung darunter leidet. So kannst du lokal auch große Datensätze wie COCO verarbeiten, ohne dass der Arbeitsspeicher ausgeht.
Explorer-API#
Dies ist eine Python-API zum Erkunden deiner Datensätze. Sie bildet auch die Grundlage für die grafische Benutzeroberfläche von Explorer. Du kannst damit eigene explorative Notebooks oder Skripte erstellen, um Erkenntnisse aus deinen Datensätzen zu gewinnen.
Entdecke alle Funktionen und Anwendungsbeispiele in der Explorer-API-Dokumentation.
Verwendung der grafischen Benutzeroberfläche von Explorer#
Die Demo der grafischen Benutzeroberfläche läuft in deinem Browser. Dort kannst du Einbettungen für deinen Datensatz erstellen, nach ähnlichen Bildern suchen, SQL-Abfragen ausführen und semantische Suchen durchführen. Du kannst sie mit dem folgenden Befehl starten:
yolo explorerDie Funktion „Ask AI“ verwendet OpenAI. Daher wirst du beim ersten Start der grafischen Benutzeroberfläche aufgefordert, den API-Schlüssel für OpenAI festzulegen. Du kannst ihn so festlegen – yolo settings openai_api_key="..."
Häufig gestellte Fragen#
Ultralytics Explorer ist ein Werkzeug zum Erkunden von Computer Vision-Datensätzen (CV) mithilfe semantischer Suche, SQL-Abfragen, Vektorähnlichkeitssuche und natürlicher Sprache. Es bietet sowohl eine grafische Benutzeroberfläche als auch eine Python-API. Da Einbettungen mit LanceDB auf der Festplatte gespeichert werden, lassen sich auch große Datensätze ohne übermäßig hohen Speicherbedarf verarbeiten.
Erfahre mehr über die Explorer-API.
Um die optionalen Abhängigkeiten für Ultralytics Explorer manuell zu installieren, kannst du den folgenden Befehl
pipverwenden:pip install "ultralytics[explorer]==8.3.11"Diese Abhängigkeiten sind für semantische Suche und SQL-Abfragen erforderlich. Dazu gehört LanceDB, das Datenbankoperationen auch bei großen Datensätzen wie COCO effizient und skalierbar hält.
Die Verwendung der Version von Ultralytics Explorer mit grafischer Benutzeroberfläche ist einfach. Nachdem du die erforderlichen Abhängigkeiten installiert hast, kannst du die Benutzeroberfläche mit dem folgenden Befehl starten:
yolo explorerDie grafische Benutzeroberfläche bietet eine benutzerfreundliche Oberfläche zum Erstellen von Datensatz-Einbettungen, Suchen nach ähnlichen Bildern, Ausführen von SQL-Abfragen und Durchführen semantischer Suchen. Mit der von OpenAI unterstützten Funktion „Ask AI“ kannst du Datensätze außerdem mit natürlichsprachlichen Fragen abfragen.
Informationen zu Speicherung und Skalierbarkeit findest du in unseren Installationsanweisungen.
Mit der Funktion „Ask AI“ in Ultralytics Explorer können Nutzer ihre Datensätze mit natürlichsprachlichen Fragen abfragen. Die von OpenAI unterstützte Funktion ermöglicht es dir, Fragen zu deinem Datensatz zu stellen, ohne SQL-Abfragen oder ähnliche Befehle zu schreiben. Um diese Funktion zu verwenden, musst du beim ersten Start der grafischen Benutzeroberfläche deinen OpenAI-API-Schlüssel festlegen:
yolo settings openai_api_key="YOUR_API_KEY"Weitere Informationen zu dieser Funktion und ihrer Integration findest du im Abschnitt Verwendung der grafischen Benutzeroberfläche von Explorer.
Ja. Installiere die festgelegte Version mit
pip install ultralytics==8.3.11in einem Colab-Notebook und folge dem Beispiel zur Erkundung von VOC, um Einbettungen zu erstellen und Suchvorgänge auf den Cloud-Ressourcen von Google auszuführen. Weitere Informationen findest du in unserem Google-Colab-Leitfaden.
Kommentare13
Stell eine Frage, teile deine Ergebnisse oder hilf jemand anderem.
pooya-github
Hi,
In colab code after running !pip install ultralytics[explorer] and running: from ultralytics import explorer i got the following error:
ImportError Traceback (most recent call last) in <cell line: 1>() ----> 1 from ultralytics import explorer
ImportError: cannot import name 'explorer' from 'ultralytics' (/usr/local/lib/python3.10/dist-packages/ultralytics/init.py)
how can i fix it?
Glenn JocherUltralytics(bearbeitet)@pooya-github the
Ultralytics Explorerfeature has been removed as ofultralytics>=8.3.12. To access similar or enhanced functionality, we recommend using Ultralytics Platform, our platform for dataset exploration and management. Let me know if you have further questions!-2
mkutu
how can I set this up with a custom dataset? Could you direct me to any resources. Thanks!
Glenn JocherUltralytics(bearbeitet)@mkutu hello!
Setting up YOLO26 with a custom dataset can be straightforward! You'd primarily need a data YAML file to describe your dataset structure and then use it in your training command. Here’s a basic guide to get you started:
-
Prepare your data: Organize your dataset into two folders (images and labels), with corresponding files named identically.
-
Create a YAML file: This file should specify the paths to your training and validation data, the number of classes, and class names. Here's an example:
# custom_data.yaml train: path/to/train/images val: path/to/val/images nc: number_of_classes names: ['class1', 'class2', 'class3'] -
Start Training: Use the following command to train your model:
yolo train data=custom_data.yaml model=yolo26n.yaml
For exploring and managing your datasets efficiently, you might consider using the Ultralytics Explorer (removed in
ultralytics>=8.3.12; useultralytics==8.3.11or Ultralytics Platform). This tool offers features like semantic search, SQL queries, and even AI-based querying to derive insights from your data.Hope this helps! If you have any more questions, feel free to ask.
-2-
BABAFAREEDDUDEKULA
how can i run above mentioned AI using yolo v8 previously i have tried yolo v9,v8,v7,rt-detr
AloshkaD
Can you be more specific?
Glenn JocherUltralytics(bearbeitet)Hey there! 🌟
It sounds like you've got a pretty wide range of experience with various YOLO versions and even RT-DETR! For running AI using YOLO26 specifically, the process is smoothly integrated into the Ultralytics framework, much like the versions you've mentioned.
To get started, make sure you have Ultralytics YOLO26 installed. If not, you can do so via pip:
pip install ultralyticsAnd then, to run your AI model with YOLO26, you can simply use:
from ultralytics import YOLO # Load the model model = YOLO('yolo26n.pt') # Here 'yolo26n.pt' is an example model. Replace it with your model path. # Run inference results = model('path_to_your_image_or_video')Or, if you prefer using the command line:
yolo detect predict model=yolo26n.pt source=path_to_your_image_or_videoRemember to replace 'yolo26n.pt' and 'path_to_your_image_or_video' with the actual paths to your YOLO26 model and the image or video you want to run inference on. 🚀
Since you've used various versions before, the process should feel quite familiar. If there's more specific functionality from the Ultralytics Explorer that you're interested in integrating with YOLO26, such as semantic search or SQL queries, the installation command provided in the documentation will be your first step:
pip install ultralytics[explorer]After that, you can launch the Ultralytics Explorer with:
yolo explorerAnd dive into explore mode (Explorer requires
ultralytics==8.3.11, as it was removed inultralytics>=8.3.12)! For any further details or if you've got a unique use case in mind, feel free to share more specifics. Happy to help further. Happy coding! 🎉1BABAFAREEDDUDEKULA
Thanks a lot my brother
2
Glenn JocherUltralytics(bearbeitet)Note: Ultralytics Explorer was removed in
ultralytics>=8.3.12; to use it, installultralytics==8.3.11. Similar dataset exploration features are available in Ultralytics Platform.@BABAFAREEDDUDEKULA hey there! 😄
Thanks for reaching out. If you're interested in diving into the Ultralytics Explorer to explore CV datasets with semantic search, SQL queries, vector similarity search, and more, it sounds like you're on the right track!
To get started, ensure you've got the Explorer installed via:
pip install ultralytics[explorer]Once installed, you can jump straight into using the GUI by typing:
yolo explorerThis launches the GUI in your browser, where you can experiment with creating embeddings, conducting image searches, and even using SQL or natural language queries!
If you encounter any issues or have specific questions as you use the Ultralytics Explorer, feel free to drop them here. Happy exploring! 🌟
AloshkaD
The yolo explorer command will open the explorer on the local machine. How would I set it up to work on AWS while I'm connected with my local machine using ssh?
Paula DerrengerUltralytics(bearbeitet)Note: Ultralytics Explorer was removed in
ultralytics>=8.3.12; to use it, installultralytics==8.3.11. Similar dataset exploration features are available in Ultralytics Platform.To set up the Ultralytics Explorer to work on an AWS instance while you're connected via SSH from your local machine, you can use port forwarding to access the Explorer's web interface. Here's a concise step-by-step guide:
-
SSH into AWS with Port Forwarding: Use the
-Loption to forward a local port to a port on the AWS instance. Replacelocal_portwith a port on your local machine (e.g.,8080), andaws_portwith the port the Explorer runs on (usually5000).ssh -i /path/to/your/key.pem -L local_port:localhost:aws_port user @AloshkaD -
Run Explorer on AWS: Once connected, start the Explorer on the AWS instance:
yolo explorer -
Access Explorer Locally: Open a web browser on your local machine and navigate to
localhost:local_portto access the Explorer interface.
Remember to replace
/path/to/your/key.pemwith the path to your AWS key,userwith your AWS username, andaws_instance_ipwith your AWS instance's IP address. Also, ensure that the AWS security group allows inbound traffic on theaws_port.1-
AloshkaD
Worked with a minor tweak to reference my config file. Thank you!
Paula DerrengerUltralytics@AloshkaD you're welcome! I'm glad to hear that you were able to get it working with your config file. If you have any more questions or need further assistance in the future, don't hesitate to reach out. Happy exploring with Ultralytics Explorer! 🚀😊
1