"tests/vscode:/vscode.git/clone" did not exist on "d5c5154fcf4c5d65551c98e458cbb027e5f4b672"
Unverified Commit 49b9ae32 authored by emricksini-h's avatar emricksini-h Committed by GitHub
Browse files

[Fix] Avoid sending image input to other PP ranks (#35405)


Signed-off-by: default avataremricksini-h <emrick.birivoutin@hcompany.ai>
Co-authored-by: default avatarRoger Wang <hey@rogerw.io>
parent 63d7972f
...@@ -104,6 +104,18 @@ try: ...@@ -104,6 +104,18 @@ try:
scheduler_output, intermediate_tensors scheduler_output, intermediate_tensors
) )
if self._is_intermediate_tensors(output): if self._is_intermediate_tensors(output):
if (
self.worker.model_runner.supports_mm_inputs
and get_pp_group().is_first_rank
):
# Strip mm_features before Ray forwards it to the next PP Stage.
# PP Stage>0 only needs the intermediate tensors,
# not preprocessed multimodal data.
# scheduled_new_reqs is a required field of SchedulerOutput,
# so accessing it directly will raise AttributeError if missing.
for req in scheduler_output.scheduled_new_reqs:
req.mm_features = []
return scheduler_output, grammar_output, output return scheduler_output, grammar_output, output
if isinstance(output, AsyncModelRunnerOutput): if isinstance(output, AsyncModelRunnerOutput):
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment