ultralytics / ultralytics

Ultralytics YOLO11 πŸš€
https://docs.ultralytics.com
GNU Affero General Public License v3.0
31.81k stars 6.1k forks source link

Suggestion: Mosaic3 as augmentation #4251

Closed Leo-Moooon closed 1 year ago

Leo-Moooon commented 1 year ago

Search before asking

Description

PR on https://github.com/ultralytics/ultralytics/pull/4250

I suggest a customized mosaic method _mosaic3, based on _mosaic9 in augment.py, class Mosaic.

I usually prefer to use Mosaic to make my model robust to real world's data, but I found a critical flawness in my project. The project uses a dataset with a ground view and all the objects in dataset places on the floor.

But when training with a mosaic4 or mosaic9, mAP goes a bit higher but it also produce FP(False Positive) predictions. So I customized the existing mosaic methods not to make undesirable height position noises.

It not only takes no additional calculation compared to existing methods, but also written very similar with them. I don't think that undesirable noise problem is just minor one in certain case.

For these reasons, it would be a good option to add this method.

Use case

image

image

Additional

No response

Are you willing to submit a PR?

github-actions[bot] commented 1 year ago

πŸ‘‹ Hello @Leo-Moooon, thank you for your interest in YOLOv8 πŸš€! We recommend a visit to the YOLOv8 Docs for new users where you can find many Python and CLI usage examples and where many of the most common questions may already be answered.

If this is a πŸ› Bug Report, please provide a minimum reproducible example to help us debug it.

If this is a custom training ❓ Question, please provide as much information as possible, including dataset image examples and training logs, and verify you are following our Tips for Best Training Results.

Join the vibrant Ultralytics Discord 🎧 community for real-time conversations and collaborations. This platform offers a perfect space to inquire, showcase your work, and connect with fellow Ultralytics users.

Install

Pip install the ultralytics package including all requirements in a Python>=3.7 environment with PyTorch>=1.7.

pip install ultralytics

Environments

YOLOv8 may be run in any of the following up-to-date verified environments (with all dependencies including CUDA/CUDNN, Python and PyTorch preinstalled):

Status

Ultralytics CI

If this badge is green, all Ultralytics CI tests are currently passing. CI tests verify correct operation of all YOLOv8 Modes and Tasks on macOS, Windows, and Ubuntu every 24 hours and on every commit.

github-actions[bot] commented 1 year ago

πŸ‘‹ Hello there! We wanted to give you a friendly reminder that this issue has not had any recent activity and may be closed soon, but don't worry - you can always reopen it if needed. If you still have any questions or concerns, please feel free to let us know how we can help.

For additional resources and information, please see the links below:

Feel free to inform us of any other issues you discover or feature requests that come to mind in the future. Pull Requests (PRs) are also always welcomed!

Thank you for your contributions to YOLO πŸš€ and Vision AI ⭐

pderrenger commented 11 months ago

@Leo-Moooon hey there! πŸ‘‹

Thank you for the suggestion! The team appreciates your detailed explanation and use case examples. I think your proposed customized mosaic method, _mosaic3, to address the undesirable height position noise issue sounds promising. It's great to hear that it doesn't involve additional computations and aligns well with the existing methods.

We're glad to see your willingness to contribute by submitting a PR. Your input would certainly benefit the community and help improve the robustness of YOLOv8 for real-world scenarios.

If you have any questions or need assistance with the process, feel free to ask. Looking forward to your PR submission! πŸš€

Leo-Moooon commented 11 months ago

Hi @pderrenger!

Thank you for your interest in my proposal. I'm not familiar with GitHub, so I'm afraid I didn't follow the precautions. I'll refer back to the PR notes, fix a few line of code, and submit it again soon πŸ˜€

Leo-Moooon commented 10 months ago

Hi @pderrenger!

I just updated my suggestion in PR #6898. Feel free to check out my PR and if there are any feedbacks, just let me know. Thanks πŸ˜€

glenn-jocher commented 9 months ago

Hi @Leo-Moooon,

Thanks for the update on your PR! We'll review it and provide feedback as soon as possible. Your contributions are valuable to us. Stay tuned! πŸ˜ŠπŸ‘