andrewqian123 commited on
Commit
6ef8720
·
verified ·
1 Parent(s): 40093ef

Update modeling_minicpmv.py

Browse files
Files changed (1) hide show
  1. modeling_minicpmv.py +1 -1
modeling_minicpmv.py CHANGED
@@ -272,7 +272,7 @@ class MiniCPMV(MiniCPMVPreTrainedModel):
272
  counter += 1
273
  batch.append(input_embeds)
274
 
275
- batch = torch.stack(batch)
276
  # output_ids = self._decode(input_embeds, tokenizer, **kwargs)
277
  if stream:
278
  kwargs.pop("decode_text")
 
272
  counter += 1
273
  batch.append(input_embeds)
274
 
275
+ batch = torch.cat(batch, dim=0)
276
  # output_ids = self._decode(input_embeds, tokenizer, **kwargs)
277
  if stream:
278
  kwargs.pop("decode_text")