Skip to content

Commit

Permalink
Remove dummy seq group data creation from loop (#301)
Browse files Browse the repository at this point in the history
Remove dummy seq metadata from loop for Flat PA fix
  • Loading branch information
iboiko-habana authored Sep 20, 2024
1 parent b62fba8 commit cd7b1c1
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions vllm/worker/habana_model_runner.py
Original file line number Diff line number Diff line change
Expand Up @@ -1087,9 +1087,11 @@ def prepare_input_tensors(
batch_size_padded = find_bucket(real_batch_size, bucket_cfg)
batch_size_padding = batch_size_padded - real_batch_size
seq_group_metadata_list = seq_group_metadata_list.copy()
seq_group_metadata_list.extend(
self.create_dummy_seq_group_metadata(0, 0, is_prompt)
for _ in range(batch_size_padding))
if batch_size_padding > 0:
dummy_seq_group_metadata = self.create_dummy_seq_group_metadata(
0, 0, is_prompt)
seq_group_metadata_list.extend(dummy_seq_group_metadata
for _ in range(batch_size_padding))

prefill_reqs = []
decode_reqs = []
Expand Down

0 comments on commit cd7b1c1

Please sign in to comment.