Attention mechanisms in yolov8, yolov9 #18764
Replies: 3 comments 9 replies
-
👋 Hello @AnirudhSanthana, thank you for your interest in Ultralytics 🚀! We recommend checking out our Documentation, which provides extensive resources and examples for using and customizing YOLO models. Attention mechanisms are an exciting area of customization, and your project sounds intriguing! 🔍 If this is a 🐛 Bug Report, please ensure you provide a minimum reproducible example (MRE) so we can better understand and help resolve any issues you're encountering. If this is a custom ❓ Question about integrating attention mechanisms, we'd love for you to provide as much detail as possible to assist our engineers and the community in supporting your inquiry. This could include your YAML configurations, any modifications you've started, or errors you're encountering. Additionally, you might find inspiration in our Tips for Best Training Results guide. Join the Ultralytics community where it suits you best! For real-time tips, jump into our Discord 🎧. For longer discussions with other enthusiasts and experts, visit Discourse. Or engage on our Subreddit to share progress and ideas. UpgradeMake sure you're using the latest pip install -U ultralytics EnvironmentsTo experiment with customizations like attention mechanisms, be sure to use a verified, up-to-date environment. Options include:
StatusIf this badge is green, all Ultralytics CI tests are currently passing. These tests validate the operation of all YOLO Modes and Tasks across multiple platforms (macOS, Windows, Ubuntu) every 24 hours and after every commit. This is an automated response to ensure you get the most relevant information quickly 😊. An Ultralytics engineer will be available soon to assist further! |
Beta Was this translation helpful? Give feedback.
-
@AnirudhSanthana hello Anirudh, To incorporate an attention mechanism into YOLOv8 or YOLOv9, you need to define the custom block in a relevant module file, such as For detailed guidance, refer to the block module documentation and ensure consistency across the YAML and Python files. If you encounter specific issues, feel free to share them for support. |
Beta Was this translation helpful? Give feedback.
-
Sure!! I will look into this further and revert back after debugging....it’s possible that there something we are missing. Meanwhile, can you please confirm whether the results shown in this image are from the validation set or the training set? As in the YAML file, we typically provide paths for all three datasets: training, validation, and testing. However, I couldn’t find the results for the test dataset, even in the output folder. Could you clarify where those results are stored or how to access them? Would appreciate your guidance on this! @glenn-jocher |
Beta Was this translation helpful? Give feedback.
-
Hello Ultralytics Team,
I’m trying to add attention mechanism to yolov8 and yolov9. I’ve already defined it in the YAML file but I’m unsure of the next steps. Additionally I noticed there’s no ' common.py' file to add the attention block. Could you please outline the exact steps and specify which files need to be modified after incorporating the block in the YAML file? @glenn-jocher
Thank you
Best regards,
Anirudh
Beta Was this translation helpful? Give feedback.
All reactions