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

Optimize quality computation #8990

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

Conversation

zhiltsov-max
Copy link
Contributor

@zhiltsov-max zhiltsov-max commented Jan 24, 2025

Motivation and context

Most noticeable in tasks with large images (e.g. 2k x 4k pixels) and with ellipse annotations. The result is that for a sample task with 157 GT frames and with lots of small ellipse annotations, peak memory consumption falls from 20GB to under 2GB.

  • Added lazy ellipse mask / RLE computation (OpenCV's ellipse() is quite slow with big masks)
  • Removed simultaneous mask materialization for all masks on the image in segmentation matching
  • Added batch size restriction in bulk saving of quality reports

How has this been tested?

Checklist

  • I submit my changes into the develop branch
  • I have created a changelog fragment
  • I have updated the documentation accordingly
  • I have added tests to cover my changes
  • I have linked related issues (see GitHub docs)

License

  • I submit my code changes under the same MIT License that covers the project.
    Feel free to contact the maintainers if that's a concern.

@zhiltsov-max zhiltsov-max force-pushed the zm/optimize-quality-computation branch from 1c73934 to 657fb32 Compare January 24, 2025 15:49
@zhiltsov-max zhiltsov-max force-pushed the zm/optimize-quality-computation branch from 657fb32 to 67a6df3 Compare January 24, 2025 15:55
@zhiltsov-max zhiltsov-max requested review from SpecLad and removed request for nmanovic January 24, 2025 16:02
Copy link

@codecov-commenter
Copy link

Codecov Report

Attention: Patch coverage is 47.61905% with 11 lines in your changes missing coverage. Please review.

Project coverage is 73.40%. Comparing base (68ffe4a) to head (6a35a0f).
Report is 8 commits behind head on develop.

Additional details and impacted files
@@             Coverage Diff             @@
##           develop    #8990      +/-   ##
===========================================
- Coverage    73.83%   73.40%   -0.44%     
===========================================
  Files          417      415       -2     
  Lines        44602    44193     -409     
  Branches      4031     3859     -172     
===========================================
- Hits         32934    32439     -495     
- Misses       11668    11754      +86     
Components Coverage Δ
cvat-ui 77.40% <ø> (-0.87%) ⬇️
cvat-server 70.07% <47.61%> (-0.01%) ⬇️

@zhiltsov-max zhiltsov-max requested review from Eldies and removed request for SpecLad January 27, 2025 18:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants