-
Notifications
You must be signed in to change notification settings - Fork 3
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
feat: Reduce time between status checks for images. #94
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
radmiratbrighterai
approved these changes
Oct 2, 2023
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@georgkoester tested it, it works:
## usual main
(venv) () redact-client 2023-10-02 10:46:06 😎> redact_folder v4 --input-dir="downloads/images" --input-type=images --output-type=images --service=blur --api-key=<api_key> --redact-url=http://newdelhi.bai:1231 --output-dir=/home/ra/git/brighter/redact-client/results/
2023-10-02 10:46:32,415 | INFO | Anonymize files from /home/ra/git/brighter/redact-client/downloads/images ...
2023-10-02 10:46:32,415 | INFO | Found 10 images to process
2023-10-02 10:46:32,415 | INFO | Starting 1 parallel jobs to anonymize files ...
100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 10/10 [01:52<00:00, 11.23s/it]
2023-10-02 10:48:24,682 | INFO | Summary: 10 successful, 0 warnings, 0 failed in 112.3s (00:01:52)
(venv) () redact-client 2023-10-02 10:48:24 😎>
## parallel main
(venv) () redact-client 2023-10-02 10:50:42 😎> rredact_folder v4 --input-dir="downloads/images" --input-type=images --output-type=images --service=blur --api-key=<api_key> --redact-url=http://newdelhi.bai:1231 --output-dir=/home/ra/git/brighter/redact-client/results/ --n-parallel-jobs=10
2023-10-02 10:51:12,235 | INFO | Anonymize files from /home/ra/git/brighter/redact-client/downloads/images ...
2023-10-02 10:51:12,235 | INFO | Found 10 images to process
2023-10-02 10:51:12,235 | INFO | Starting 10 parallel jobs to anonymize files ...
100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 10/10 [00:20<00:00, 2.07s/it]
2023-10-02 10:51:32,905 | INFO | Summary: 10 successful, 0 warnings, 0 failed in 20.7s (00:00:20)
## waiting time reduced
(venv) () redact-client 2023-10-02 10:54:01 😎> rredact_folder v4 --input-dir="downloads/images" --input-type=images --output-type=images --service=blur --api-key=<api_key> --redact-url=http://newdelhi.bai:1231 --output-dir=/home/ra/git/brighter/redact-client/results/
2023-10-02 10:54:18,362 | INFO | Anonymize files from /home/ra/git/brighter/redact-client/downloads/images ...
2023-10-02 10:54:18,362 | INFO | Found 10 images to process
2023-10-02 10:54:18,362 | INFO | Starting 1 parallel jobs to anonymize files ...
100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 10/10 [01:01<00:00, 6.11s/it]
2023-10-02 10:55:19,490 | INFO | Summary: 10 successful, 0 warnings, 0 failed in 61.1s (00:01:01)
(venv) () redact-client 2023-10-02 10:55:19 😎>
## waiting time reduced parallel
(venv) () redact-client 2023-10-02 10:55:19 😎> rredact_folder v4 --input-dir="downloads/images" --input-type=images --output-type=images --service=blur --api-key=<api_key> --redact-url=http://newdelhi.bai:1231 --output-dir=/home/ra/git/brighter/redact-client/results/ --n-parallel-jobs=10
2023-10-02 10:56:45,351 | INFO | Anonymize files from /home/ra/git/brighter/redact-client/downloads/images ...
2023-10-02 10:56:45,352 | INFO | Found 10 images to process
2023-10-02 10:56:45,352 | INFO | Starting 10 parallel jobs to anonymize files ...
100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 10/10 [00:17<00:00, 1.72s/it]
2023-10-02 10:57:02,606 | INFO | Summary: 10 successful, 0 warnings, 0 failed in 17.3s (00:00:17)
(venv) () redact-client 2023-10-02 10:57:02 😎>
just small request, could you please post PRs into the #core_review slack channel in the future?
@georgkoester could you please also check the failing tests? seems like they are legitimate fails |
Thanks for the review @radmiratbrighterai ! |
Specifically in redact_folder, adjust status check time for images, which can be done in 1.5-4s.
georgkoester
force-pushed
the
lower-waiting-time-for-images
branch
from
December 11, 2023 10:07
f9d2061
to
5ab0826
Compare
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Specifically in redact_folder, adjust status check time for images, which can be done in 1.5-4s.