[Python] Configure object detection benchmark timeout - #39949
Draft
bvolpato wants to merge 1 commit into
Draft
Conversation
This file contains hidden or 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
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.
Addresses #38782.
Status: draft pending #39953 and an end-to-end Dataflow run. #39953 fixes the ignored fixed-batch configuration, which may change benchmark runtime. This timeout increase should not merge until the corrected benchmark confirms that 30 minutes remains insufficient.
Why
The Faster R-CNN benchmark added in #37186 has not completed successfully in the daily workflow. Recent runs consistently reach the object-detection batch CPU step, start the Dataflow job, and then cancel it after about 1,803 seconds.
This is not the GitHub Actions timeout. Each benchmark step allows 180 minutes, but
pytorch_image_object_detection.run()has its own hard-coded 30-minutewait_until_finish()call. Itsfinallyblock cancels the still-running Dataflow job before the outer workflow timeout can help.What changed
--timeout_msoption to the object-detection example, preserving the existing 30-minute default for other callers.Keeping the override in benchmark options makes future runtime tuning possible without changing example behavior globally.
Validation
python -m py_compile sdks/python/apache_beam/examples/inference/pytorch_image_object_detection.pyyapf==0.43.0 --diffon the changed Python fileruff==0.15.22 check --ignore I001,UP006on the changed Python filegit diff --checkEnd-to-end validation requires Dataflow benchmark infrastructure.