Ultralytics YOLO11 Launch đ
Ultralytics YOLO11
We are thrilled to announce the official launch of YOLO11, the latest iteration of the Ultralytics YOLO series, bringing unparalleled advancements in real-time object detection, segmentation, pose estimation, and classification. Building upon the success of YOLOv8, YOLO11 delivers state-of-the-art performance across the board with significant improvements in both speed and accuracy.
đ Key Performance Improvements:
- Accuracy Boost: YOLO11 achieves up to a 2% higher mAP (mean Average Precision) on COCO for object detection compared to YOLOv8.
- Efficiency & Speed: It boasts up to 22% fewer parameters than YOLOv8 models while improving real-time inference speeds by up to 2% faster, making it perfect for edge applications and resource-constrained environments.
đ Quantitative Performance Comparison with YOLOv8:
| Model | YOLOv8 mAPval (%) | YOLO11 mAPval (%) | YOLOv8 Params (M) | YOLO11 Params (M) | Improvement |
|---|---|---|---|---|---|
| YOLOn | 37.3 | 39.5 | 3.2 | 2.6 | +2.2% mAP |
| YOLOs | 44.9 | 47.0 | 11.2 | 9.4 | +2.1% mAP |
| YOLOm | 50.2 | 51.5 | 25.9 | 20.1 | +1.3% mAP |
| YOLOl | 52.9 | 53.4 | 43.7 | 25.3 | +0.5% mAP |
| YOLOx | 53.9 | 54.7 | 68.2 | 56.9 | +0.8% mAP |
Each variant of YOLO11 (n, s, m, l, x) is designed to offer the optimal balance of speed and accuracy, catering to diverse application needs.
đ Versatile Task Support
YOLO11 builds on the versatility of the YOLO series, handling diverse computer vision tasks seamlessly:
- Detection: Rapidly detect and localize objects within images or video frames.
- Instance Segmentation: Identify and segment objects at a pixel level for more granular insights.
- Pose Estimation: Detect key points for human pose estimation, suitable for fitness, sports analytics, and more.
- Oriented Object Detection (OBB): Detect objects with an orientation angle, perfect for aerial imagery and robotics.
- Classification: Classify whole images into categories, useful for tasks like product categorization.
đŚ Quick Start Example
To get started with YOLO11, install the latest version of the Ultralytics package:
pip install ultralytics>=8.3.0
Then, load the pre-trained YOLO11 model and run inference on an image:
from ultralytics import YOLO
# Load the YOLO11 model
model = YOLO("yolo11n.pt")
# Run inference on an image
results = model("path/to/image.jpg")
# Display results
results[0].show()
With just a few lines of code, you can harness the power of YOLO11 for real-time object detection and other computer vision tasks.
đ Seamless Integration & Deployment
YOLO11 is designed for easy integration into existing workflows and is optimized for deployment across a variety of environments, from edge devices to cloud platforms, offering unmatched flexibility for diverse applications.
You can get started with YOLO11 today through the Ultralytics HUB and the Ultralytics Python package. Dive into the future of computer vision and experience how YOLO11 can power your AI projects! đ
đ Hello @glenn-jocher, thank you for sharing the exciting news about Ultralytics YOLO11 đ! We are delighted to hear about the advancements and improvements this latest iteration offers.
For those new to Ultralytics, we recommend checking out our Docs for comprehensive guidance and examples for both Python and CLI usage. This can help answer many common queries and get you started quickly.
If you encounter any đ bugs while exploring YOLO11, please provide a minimum reproducible example to aid in debugging.
Interested in custom training or have specific questions â? Please provide detailed information, including dataset samples and training logs, and ensure you are following our Tips for Best Training Results.
Connect with the Ultralytics community in the spot that suits you best. Jump into real-time chat on Discord đ§. Prefer longer discussions? Visit Discourse. And for engaging threads, our Subreddit awaits!
Upgrade
Make sure to upgrade to the latest version of ultralytics along with all necessary requirements in a Python>=3.8 environment and PyTorch>=1.8:
pip install -U ultralytics
Environments
YOLO models can be run in these verified environments with dependencies like CUDA, Python, and PyTorch preinstalled:
- Notebooks with free GPU:
- Google Cloud Deep Learning VM: GCP Quickstart Guide
- Amazon Deep Learning AMI: AWS Quickstart Guide
- Docker Image: Docker Quickstart Guide
Status
If this badge is green, all Ultralytics CI tests are passing, verifying functionality across different systems daily and with every commit.
Thank you for your contribution and enthusiasm! Please note this is an automated response, and an Ultralytics engineer will assist you soon. đ
Here are some cool visualizations with Ultralytics YOLO11 đ
https://github.com/user-attachments/assets/b45293e9-6d4c-4b40-85ab-3da09eea3cac
https://github.com/user-attachments/assets/b51d162e-9ccf-455a-a484-ac644128fa38
https://github.com/user-attachments/assets/cfad9b4a-4903-489b-b3ba-696fb8715c7c
https://github.com/user-attachments/assets/789e514c-ae25-4864-999d-58e7ef3c2481
https://github.com/user-attachments/assets/81b0a516-8837-44ee-aa76-35887e16b366
https://github.com/user-attachments/assets/ba19dd28-cfc6-4048-a7ee-c10d32770827
https://github.com/user-attachments/assets/9b8fa658-8af7-4d33-a6ae-6875df013304
I would like to apply to False mode :' providing a visual output of tracked objects' .
Could you tell me the command ?
To display visual output of tracked objects, use the show=True argument in your command.
Error when running YOLOv8-Action-Recognition ImportError: cannot import name 'MViT_V1_B_Weights' from 'torchvision.models.video' (D:\miniconda3\envs\yolov8\lib\site-packages\torchvision\models\video_init_.py)
my environment Conda version: conda 24.7.1 CUDA is available. Version: 10.2 PyTorch version: 1.10.1+cu102 Using GPU version of PyTorch.
The error indicates an issue with the compatibility of your PyTorch version (1.10.1) and the required torchvision models. YOLOv8-Action-Recognition requires a more recent version of PyTorch and torchvision. Please update both to the latest versions compatible with your CUDA version (e.g., PyTorch 1.12+). For installation guidance, refer to the official PyTorch installation page.
Hello ! I recently considered loading a tri-modal data set based on the yolov8 algorithm framework, including visible and infrared data sets, and a text data set. I don 't know how to load data, can you give me some advice
Thank you for your question! YOLOv8 supports multi-modal data processing, but integrating tri-modal data like visible, infrared, and text will require custom preprocessing and dataset preparation. You can preprocess and align your data into a compatible format (e.g., YOLO-style annotations for images and structured embeddings for text) and modify the dataloader accordingly. For further customization, refer to the YOLOv8 training guide for dataset preparation details.
@glenn-jocher i am trying to train yolov11n for segmentation. but while loading the weights, i am facing an issue 'no such file or directory found'. I asked the Ask AI feature in documentation it responded with: For training, it's recommended to use the pretrained model approach. Models download automatically from the latest Ultralytics release on first use.
Is there a way to download weights?
from ultralytics import YOLO model = YOLO('yolo11n-seg.pt')
The YOLOv11n-seg weights download automatically when using YOLO('yolov11n-seg.pt') with ultralytics>=8.3.0. Ensure you:
- Use the exact model name
yolov11n-seg.pt(note the 'v' after yolo) - Have internet connectivity on first run
- Upgrade via
pip install -U ultralytics
If issues persist, manually download weights from https://docs.ultralytics.com/models/yolo11/#download.
I'm trying to train on 4 channel (rgba) image data, where do I specify that in config?
@GPlays09 yOLO models process 3-channel RGB images by default. For 4-channel RGBA inputs, you'll need to modify the model architecture in your YAML configuration file to change input channels from 3 to 4 in the first convolutional layer. This modification requires training from scratch rather than using pretrained weights. For implementation details, see the YOLO model configuration documentation.
How to improve the YOLOv11s's map.5, map.5-.90, precision, recall as i'm training it on only one class Apple disease detection with a dataset of 9381 annotated images , i'm getting map.5 in 79%, map50-90 in 42%, precision is 63%, recall is 80%, confusion matrix shows 1.00 background, 0.87 of the disease and 0.13 as false negatives...i have trained it for 150 epochs , batch size 32 etc..? please provide a solution to improve the accuracy for only one class..
How to add attention mechanism in YOLOv11 for improving the accuracy?
@glenn-jocher What is possible solution for above mentioned questions?
@Syed-bisma2 Thanks for the detailsâtwo quick paths that typically help on single-class datasets, and a note on attention:
- To lift mAP/precision: try a slightly larger model or higher resolution and run automated tuning; also calibrate augmentations and your inference thresholds.
# train with a larger model and higher imgsz, with mild aug and cosine LR
yolo detect train model=yolo11m.pt data=apple.yaml imgsz=832 epochs=200 batch=32 cos_lr=True mosaic=0.5 mixup=0.1 close_mosaic=20
# at inference, raise the threshold to trade recall for precision
yolo detect predict model=best.pt source=val/images conf=0.35 iou=0.6
For systematic optimization, use model.tune():
from ultralytics import YOLO
model = YOLO("yolo11s.pt")
model.tune(data="apple.yaml", epochs=30, iterations=150) # finds better lr/aug/etc.
See the Hyperparameter Tuning Guide and Augmentation Guide for what to try next. (docs.ultralytics.com)
- About âadding attentionâ to YOLO11: not supported out of the box and generally hurts speed; if you still want to experiment, youâll need a custom model YAML and module/backbone swap, then train from scratch. The Model YAML Configuration Guide shows how to plug in custom or TorchVision backbones. (docs.ultralytics.com)
If you can share a short training log (PR/ROC curves) we can suggest tighter changes.
@glenn-jocher Thank you so much
@glenn-jocher
@glenn-jocher
@Syed-bisma2 thanks for the plotsânext, please validate your best.pt with TTA and a low conf to inspect the full PR/F1 curves, then pick the operating conf that maximizes F1; for a quick check run:
yolo detect val model=best.pt data=apple.yaml imgsz=832 conf=0.001 iou=0.7 augment=True plots=True
At inference, test the calibrated thresholds (and TTA) like:
yolo detect predict model=best.pt source=val/images conf=0.45 iou=0.6 augment=True
If small-object FNs dominate, retrain with multi-scale enabled and slightly lighter aug; also share text logs so we can be precise: the last 20 lines of runs/detect/train*/results.csv, your runs/detect/train*/args.yaml, and yolo checks output; references: Val mode and the Prediction guide.
@Syed-bisma2 thanks for sharing the filesâcould you paste the last 20 lines of results.csv and the text of your args.yaml inline, plus the output of yolo checks? For single-class cases, try a quick rerun with single-class and multi-scale training and a lighter class loss, then compare PR/F1:
yolo detect train model=yolo11m.pt data=apple.yaml imgsz=896 epochs=200 batch=32 single_cls=True multi_scale=True cos_lr=True mosaic=0.3 mixup=0.0 close_mosaic=10 cls=0.2 patience=50
If you recently upgraded packages and are in a notebook, please restart the kernel before rerunning.
@glenn-jocher ask: detect mode: train model: yolo11s.pt data: E:\Datasets\root_directory\data.yaml epochs: 150 time: null patience: 50 batch: 32 imgsz: 640 save: true save_period: -1 cache: false device: '0' workers: 8 project: null name: train10 exist_ok: false pretrained: true optimizer: auto verbose: true seed: 0 deterministic: true single_cls: false rect: false cos_lr: false close_mosaic: 10 resume: false amp: true fraction: 1.0 profile: false freeze: null multi_scale: false overlap_mask: true mask_ratio: 4 dropout: 0.0 val: true split: val save_json: false conf: null iou: 0.7 max_det: 300 half: false dnn: false plots: true source: null vid_stride: 1 stream_buffer: false visualize: false augment: false agnostic_nms: false classes: null retina_masks: false embed: null show: false save_frames: false save_txt: false save_conf: false save_crop: false show_labels: true show_conf: true show_boxes: true line_width: null format: torchscript keras: false optimize: false int8: false dynamic: false simplify: true opset: null workspace: null nms: false lr0: 0.01 lrf: 0.01 momentum: 0.95 weight_decay: 0.0005 warmup_epochs: 3.0 warmup_momentum: 0.8 warmup_bias_lr: 0.1 box: 7.5 cls: 0.5 dfl: 1.5 pose: 12.0 kobj: 1.0 nbs: 64 hsv_h: 0.015 hsv_s: 0.7 hsv_v: 0.4 degrees: 0.0 translate: 0.1 scale: 0.5 shear: 0.0 perspective: 0.0 flipud: 0.0 fliplr: 0.5 bgr: 0.0 mosaic: 1.0 mixup: 0.0 cutmix: 0.0 copy_paste: 0.0 copy_paste_mode: flip auto_augment: randaugment erasing: 0.4 cfg: null tracker: botsort.yaml save_dir: runs\detect\train10
| 92 | 178014 | 1.4057 | 0.87724 | 0.94893 | 0.70094 | 0.73261 | 0.77153 | 0.41986 | 1.53203 | 1.01515 | 0.97827 | 0.003994 | 0.003994 | 0.003994 | Â |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 93 | 179897 | 1.39996 | 0.87194 | 0.94762 | 0.70344 | 0.72151 | 0.7681 | 0.41809 | 1.53191 | 1.02068 | 0.97707 | 0.003928 | 0.003928 | 0.003928 | Â |
| 94 | 181807 | 1.39619 | 0.86108 | 0.94415 | 0.69306 | 0.73166 | 0.76928 | 0.4198 | 1.53027 | 1.01319 | 0.97492 | 0.003862 | 0.003862 | 0.003862 | Â |
| 95 | 183681 | 1.4017 | 0.86392 | 0.94817 | 0.71145 | 0.71338 | 0.76691 | 0.41695 | 1.53104 | 1.0211 | 0.97633 | 0.003796 | 0.003796 | 0.003796 | Â |
| 96 | 185621 | 1.3968 | 0.85309 | 0.94863 | 0.71533 | 0.71316 | 0.7683 | 0.41984 | 1.53408 | 1.02857 | 0.97791 | 0.00373 | 0.00373 | 0.00373 | Â |
| 97 | 187511 | 1.38872 | 0.8514 | 0.94446 | 0.71739 | 0.71948 | 0.77101 | 0.4222 | 1.53227 | 1.01935 | 0.9772 | 0.003664 | 0.003664 | 0.003664 | Â |
| 98 | 189385 | 1.38644 | 0.84307 | 0.94238 | 0.70879 | 0.72179 | 0.76724 | 0.41943 | 1.5346 | 1.02559 | 0.97855 | 0.003598 | 0.003598 | 0.003598 | Â |
| 99 | 191274 | 1.38215 | 0.84172 | 0.94082 | 0.71057 | 0.72015 | 0.76683 | 0.41846 | 1.53403 | 1.02606 | 0.97811 | 0.003532 | 0.003532 | 0.003532 | Â |
| 100 | 193148 | 1.38447 | 0.83495 | 0.9418 | 0.70833 | 0.71925 | 0.76749 | 0.4195 | 1.53171 | 1.02598 | 0.97814 | 0.003466 | 0.003466 | 0.003466 | Â |
| 101 | 195021 | 1.37559 | 0.83241 | 0.94162 | 0.70218 | 0.72241 | 0.76489 | 0.41716 | 1.53532 | 1.03078 | 0.98011 | 0.0034 | 0.0034 | 0.0034 | Â |
| 102 | 196891 | 1.38767 | 0.83845 | 0.94237 | 0.70304 | 0.72183 | 0.76296 | 0.41624 | 1.5372 | 1.02674 | 0.98326 | 0.003334 | 0.003334 | 0.003334 | Â |
| 103 | 198759 | 1.37194 | 0.8258 | 0.94183 | 0.69737 | 0.72083 | 0.76322 | 0.41475 | 1.54533 | 1.02872 | 0.9856 | 0.003268 | 0.003268 | 0.003268 | Â |
| 104 | 200684 | 1.37599 | 0.81817 | 0.93796 | 0.70872 | 0.70725 | 0.76038 | 0.4141 | 1.55046 | 1.036 | 0.98794 | 0.003202 | 0.003202 | 0.003202 | Â |
| 105 | 202609 | 1.3674 | 0.8136 | 0.93998 | 0.70234 | 0.71609 | 0.76048 | 0.4147 | 1.5494 | 1.03723 | 0.98778 | 0.003136 | 0.003136 | 0.003136 | Â |
| 106 | 204572 | 1.37223 | 0.80871 | 0.94144 | 0.70656 | 0.70436 | 0.7574 | 0.4115 | 1.55249 | 1.04301 | 0.98911 | 0.00307 | 0.00307 | 0.00307 | Â |
| 107 | 206437 | 1.36755 | 0.80884 | 0.93906 | 0.70128 | 0.71203 | 0.76023 | 0.41303 | 1.55413 | 1.04284 | 0.98824 | 0.003004 | 0.003004 | 0.003004 | Â |
| 108 | 208332 | 1.37034 | 0.80711 | 0.93927 | 0.67976 | 0.74024 | 0.76083 | 0.41321 | 1.55734 | 1.04064 | 0.99043 | 0.002938 | 0.002938 | 0.002938 | Â |
| 109 | 210264 | 1.35613 | 0.80313 | 0.93583 | 0.6783 | 0.73803 | 0.75838 | 0.41148 | 1.55769 | 1.04764 | 0.99073 | 0.002872 | 0.002872 | 0.002872 | Â |
| 110 | 212165 | 1.3605 | 0.79342 | 0.93539 | 0.69168 | 0.72444 | 0.75863 | 0.4118 | 1.55876 | 1.04598 | 0.99179 | 0.002806 | 0.002806 | 0.002806 | Â |
| 111 | 214030 | 1.36332 | 0.79088 | 0.9373 | 0.6908 | 0.72218 | 0.75716 | 0.41112 | 1.55979 | 1.04476 | 0.99196 | 0.00274 | 0.00274 | 0.00274 | Â |
| 112 | 215916 | 1.34647 | 0.7839 | 0.93407 | 0.68604 | 0.73008 | 0.75536 | 0.41037 | 1.56007 | 1.04602 | 0.9921 | 0.002674 | 0.002674 | 0.002674 | Â |
@Syed-bisma2 thanksâyour args show single_cls=False, imgsz=640, mosaic=1.0, and auto_augment=randaugment/erasing=0.4, which often depress precision on singleâclass box tasks; try this targeted rerun and then share yolo checks (or !yolo checks in notebooks) plus the plainâtext tail of results.csv for review:
yolo detect train model=yolo11m.pt data=E:\Datasets\root_directory\data.yaml imgsz=832 epochs=200 batch=32 \
single_cls=True multi_scale=True rect=True cos_lr=True mosaic=0.4 auto_augment=None erasing=0.0 cls=0.2 close_mosaic=15
Also confirm your data.yaml has nc: 1 and, if you recently edited labels, delete any *.cache files under the labels directories; for automated hyperparameter search, see the Tune mode guide.
@glenn-jocher Sir, with imgsz=832 and batch_size=32, it shows a CUDA error...CUDA out of memory, as I'm having only two GPUs. What is the solution?
@Syed-bisma2 the CUDA out-of-memory just means that yolo11m at imgsz=832 and batch=32 is too heavy for your available VRAM; on two GPUs, either reduce the batch (try 16 â 8 â 4) at 832, or keep batch=32 and lower imgsz (e.g., 704 or 640), and optionally set device=0,1 to use both GPUsâif it still fails after dialing those down, please paste the full CUDA error text and your yolo checks output so we can see your exact setup.
Hey there, I'm New to DL and my project is to add CBAM to layer 3 and 6 of backbone of model Yolov11m and I don't know how to do that can someone help please.
my project is to modify Yolo v11m for detection, classification and counting blood cells and I taught adding CBAM might be a good improvement but I'm not sure where should I add it to get the best result , would layer 3 and 6 be good?
@ghzlnasirijozani-glitch nice project idea. CBAM isnât built into YOLO11, so thereâs no config flag like attention=cbam; youâd need to fork the repo, create a custom YOLO11m YAML, implement a CBAM PyTorch module, wire it into the backbone, and then train from scratch using that YAML (no pretrained weights).
A typical workflow is: copy the existing YOLO11m model YAML to something like yolo11m_cbam.yaml, add CBAM blocks after the backbone entries you want (e.g., after the 3rd and 6th backbone layers in that file), and then train with:
yolo detect train model=yolo11m_cbam.yaml data=your_data.yaml epochs=... imgsz=...
There isnât a guaranteed âbestâ place for CBAM; you usually experiment with a small number of midâdepth backbone locations where feature maps are smaller but still contain useful detail, and then compare validation mAP and speed to the vanilla YOLO11m baseline. Also be aware that attention blocks increase latency and memory, and in our experience attentionâheavy variants (like the community YOLO12 models described in the YOLO12 overview) can be less stable and slower, so for production we generally recommend sticking with plain YOLO11 and focusing first on data quality, augmentation, and hyperparameter tuning. For background on the supported architectures and how theyâre structured, the Ultralytics model docs are a good reference.
Yes I understand that attention blocks increase latency but i gotta come up with some kind of change for my project and also in this field that I'm working time is not as important as accuracy. I also have another question. I want to add some kinda algorithm for rechecking the confidence scores and then sending the ones with low scores to feature map from layer 6 for double checking. Where should I add this ? When i want to go for the test for my model should I add this there?