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

Add multiprocessing to DatumaroBinaryBase #897

Conversation

vinnamkim
Copy link
Contributor

@vinnamkim vinnamkim commented Mar 27, 2023

Summary

  • Ticket no. 106632
  • Add --num-workers option to DatumaroBinaryBase for better performance.

How to test

I updated the tests to cover this change.

Checklist

  • I have added unit tests to cover my changes.​
  • I have added integration tests to cover my changes.​
  • I have added the description of my changes into CHANGELOG.​
  • I have updated the documentation accordingly

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.
  • I have updated the license header for each file (see an example below).
# Copyright (C) 2023 Intel Corporation
#
# SPDX-License-Identifier: MIT

@vinnamkim vinnamkim marked this pull request as ready for review March 28, 2023 05:07
@vinnamkim vinnamkim added this to the 1.2.0 milestone Mar 28, 2023
@vinnamkim vinnamkim added the ENHANCE Enhancement of existing features label Mar 28, 2023
@codecov-commenter
Copy link

codecov-commenter commented Mar 28, 2023

Codecov Report

Patch coverage: 97.05% and no project coverage change.

Comparison is base (3f918c4) 78.86% compared to head (ca504ea) 78.86%.

Additional details and impacted files
@@           Coverage Diff            @@
##           develop     #897   +/-   ##
========================================
  Coverage    78.86%   78.86%           
========================================
  Files          204      204           
  Lines        25002    25020   +18     
  Branches      5026     5031    +5     
========================================
+ Hits         19718    19733   +15     
- Misses        4151     4153    +2     
- Partials      1133     1134    +1     
Flag Coverage Δ
macos-11_Python-3.8 ?
ubuntu-20.04_Python-3.8 78.86% <97.05%> (+0.01%) ⬆️
windows-2019_Python-3.8 ?

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

Impacted Files Coverage Δ
datumaro/components/importer.py 89.76% <ø> (-0.24%) ⬇️
datumaro/plugins/data_formats/datumaro/importer.py 100.00% <ø> (ø)
...o/plugins/data_formats/datumaro_binary/exporter.py 95.74% <ø> (ø)
...o/plugins/data_formats/datumaro_binary/importer.py 80.95% <0.00%> (-4.05%) ⬇️
...umaro/plugins/data_formats/datumaro_binary/base.py 95.09% <100.00%> (+1.12%) ⬆️
...aro/plugins/data_formats/datumaro_binary/format.py 90.00% <100.00%> (+0.52%) ⬆️

... and 1 file with indirect coverage changes

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

☔ View full report in Codecov by Sentry.
📢 Do you have feedback about the report comment? Let us know in this issue.

Signed-off-by: Kim, Vinnam <vinnam.kim@intel.com>
Signed-off-by: Kim, Vinnam <vinnam.kim@intel.com>
Signed-off-by: Kim, Vinnam <vinnam.kim@intel.com>
Signed-off-by: Kim, Vinnam <vinnam.kim@intel.com>
Signed-off-by: Kim, Vinnam <vinnam.kim@intel.com>
@vinnamkim vinnamkim force-pushed the feature/add-multiprocessing-to-datumaro-binary-import branch from a0fe19c to ca504ea Compare March 28, 2023 05:55
@vinnamkim vinnamkim marked this pull request as ready for review March 28, 2023 05:56
sooahleex
sooahleex previously approved these changes Mar 28, 2023
Copy link
Contributor

@sooahleex sooahleex left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me

@@ -23,6 +23,7 @@ class DatumaroBinaryPath:
SECRET_KEY_FILE = "secret_key.txt"

MAX_BLOB_SIZE = 2**20 # 1 Mega bytes
MP_TIMEOUT = 30.0 # 30 secs
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is there any reason to consider MP_TIMEOUT as 30 secs?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No reason, I just put in a value that I feel moderately long.

Signed-off-by: Kim, Vinnam <vinnam.kim@intel.com>
Copy link
Contributor

@JihwanEom JihwanEom left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, thank you for awesome work!

@vinnamkim vinnamkim merged commit 508c573 into openvinotoolkit:develop Mar 28, 2023
@vinnamkim vinnamkim deleted the feature/add-multiprocessing-to-datumaro-binary-import branch March 28, 2023 08:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ENHANCE Enhancement of existing features
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants