Skip to content

Commit abc8619

Browse files
committed
qwen pp
1 parent e9d0f37 commit abc8619

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

verl/workers/sharding_manager/megatron_vllm.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -426,8 +426,8 @@ def default_tp_concat_fn(self, name, param, infer_params, model_config, convert_
426426
num_attention_heads = model_config.num_attention_heads
427427
num_key_value_heads = model_config.num_key_value_heads
428428
if "vision_model" in name:
429-
num_attention_heads = unwrap_model(self.actor_module[0]).vision_model.config.num_attention_heads
430-
num_key_value_heads = unwrap_model(self.actor_module[0]).vision_model.config.num_query_groups
429+
num_attention_heads = self.weight_converter.hf_config.vision_config['num_heads']
430+
num_key_value_heads = self.weight_converter.hf_config.vision_config['num_heads']
431431
assert num_attention_heads % num_key_value_heads == 0
432432
num_q_per_kv = num_attention_heads // num_key_value_heads
433433
assert infer_params[0].shape[0] % (num_q_per_kv + 2) == 0, (

0 commit comments

Comments
 (0)