@@ -274,12 +274,6 @@ async def benchmark(
274274 input_requests [0 ].expected_output_len , \
275275 input_requests [0 ].multi_modal_data
276276
277- if (test_mm_content is not None and backend not in \
278- ["openai-chat" , "openai-audio" ]):
279- # multi-modal benchmark is only available on OpenAI Chat backend.
280- raise ValueError (
281- "Multi-modal content is only supported on 'openai-chat' and " \
282- "'openai-audio' backend." )
283277 assert test_mm_content is None or isinstance (test_mm_content , dict )
284278 test_input = RequestFuncInput (
285279 model = model_id ,
@@ -620,6 +614,13 @@ def main(args: argparse.Namespace):
620614 f" from one of following: { supported_datasets } . "
621615 "Please consider contributing if you would "
622616 "like to add support for additional dataset formats." )
617+
618+ if (dataset_class .IS_MULTIMODAL and backend not in \
619+ ["openai-chat" , "openai-audio" ]):
620+ # multi-modal benchmark is only available on OpenAI Chat backend.
621+ raise ValueError (
622+ "Multi-modal content is only supported on 'openai-chat' and " \
623+ "'openai-audio' backend." )
623624 input_requests = dataset_class (
624625 dataset_path = args .dataset_path ,
625626 dataset_subset = args .hf_subset ,
0 commit comments