From 52b23464f3c0851d669b026fc1b6369294c73eb3 Mon Sep 17 00:00:00 2001 From: bvolpato Date: Tue, 1 Sep 2026 08:33:56 -0400 Subject: [PATCH] [Python] Honor fixed object detection batch size --- .../examples/inference/pytorch_image_object_detection.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/sdks/python/apache_beam/examples/inference/pytorch_image_object_detection.py b/sdks/python/apache_beam/examples/inference/pytorch_image_object_detection.py index a8eef5a7d5e7..3279aaf4b4e1 100644 --- a/sdks/python/apache_beam/examples/inference/pytorch_image_object_detection.py +++ b/sdks/python/apache_beam/examples/inference/pytorch_image_object_detection.py @@ -431,7 +431,8 @@ def run( model_params={}, state_dict_path=known_args.model_state_dict_path, device=device, - inference_batch_size=batch_size, + min_batch_size=batch_size, + max_batch_size=batch_size, inference_fn=_torchvision_detection_inference_fn, )