Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

support RGBA image in model training, validation, prediction and export #10036

Open
wants to merge 5 commits into
base: main
Choose a base branch
from

Conversation

lizongnan
Copy link

@lizongnan lizongnan commented Apr 14, 2024

πŸ› οΈ PR Summary

Made with ❀️ by Ultralytics Actions

🌟 Summary

Ultralytics introduces RGBA image support across its pipeline, enhancing visual data processing capabilities! πŸŽ‰

πŸ“Š Key Changes

  • RGBA Support: New configuration option to handle RGBA (Red, Green, Blue, Alpha) images, allowing transparency in images.
  • Image Channel Configuration: Adjustments to model configuration files to specify the number of image channels (now supporting 4 for RGBA images).
  • Adaptive Image Loading: Modified image loading functions to dynamically support both BGR and BGRA based on configuration.
  • Model Input Adjustments: Changes in model, predictor, and validator components to accommodate 4 channels for RGBA images, ensuring compatibility throughout the pipeline.
  • Plotting Compatibility: Updated plotting functions to handle images with 4 channels, including adjustments for saving images in a format compatible with RGBA.

🎯 Purpose & Impact

  • Enhanced Visual Data Representation: The ability to handle images with transparency opens up new avenues for richer visual data representation and processing.
  • Increased Flexibility: This update provides users with more options for image formats, enhancing the toolkit’s flexibility for different use cases.
  • Compatibility and Performance: Ensures seamless integration of RGBA images within the existing framework, maintaining performance and compatibility.

These changes facilitate more diverse and complex image processing tasks, catering to a broader range of applications and user needs. πŸš€

Copy link

CLA Assistant Lite bot:
Thank you for your submission, we really appreciate it. Like many open-source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution. You can sign the CLA by just posting a Pull Request Comment same as the below format.


I have read the CLA Document and I sign the CLA


You can retrigger this bot by commenting recheck in this Pull Request

Copy link

codecov bot commented Apr 14, 2024

Codecov Report

Attention: Patch coverage is 70.96774% with 9 lines in your changes are missing coverage. Please review.

Project coverage is 75.97%. Comparing base (d608565) to head (33c9174).
Report is 7 commits behind head on main.

❗ Current head 33c9174 differs from pull request most recent head b212c6d. Consider uploading reports for the commit b212c6d to get more accurate results

Files Patch % Lines
ultralytics/data/base.py 42.85% 4 Missing ⚠️
ultralytics/data/loaders.py 77.77% 2 Missing ⚠️
ultralytics/engine/model.py 50.00% 1 Missing ⚠️
ultralytics/engine/predictor.py 80.00% 1 Missing ⚠️
ultralytics/utils/plotting.py 75.00% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main   #10036      +/-   ##
==========================================
- Coverage   75.99%   75.97%   -0.02%     
==========================================
  Files         121      121              
  Lines       15332    15349      +17     
==========================================
+ Hits        11652    11662      +10     
- Misses       3680     3687       +7     
Flag Coverage Ξ”
Benchmarks 36.02% <45.16%> (-0.01%) ⬇️
GPU 37.93% <41.93%> (-0.01%) ⬇️
Tests 71.28% <64.51%> (-0.03%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

β˜” View full report in Codecov by Sentry.
πŸ“’ Have feedback on the report? Share it here.

@Burhan-Q Burhan-Q added the enhancement New feature or request label Apr 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants