hanxiao commited on
Commit
806a44b
1 Parent(s): e3c40e9

Update modeling_clip.py

Browse files
Files changed (1) hide show
  1. modeling_clip.py +2 -2
modeling_clip.py CHANGED
@@ -485,9 +485,9 @@ class JinaCLIPModel(JinaCLIPPreTrainedModel):
485
  else:
486
  raise ValueError("Unsupported image format")
487
 
488
- processed_inputs.append(self.preprocess(image))
489
 
490
- processed_inputs = torch.stack(processed_inputs).to(device)
491
  embeddings = self.get_image_features(processed_inputs)
492
 
493
  if normalize_embeddings:
 
485
  else:
486
  raise ValueError("Unsupported image format")
487
 
488
+ processed_inputs.append(image)
489
 
490
+ processed_inputs = self.preprocess(processed_inputs).to(device)
491
  embeddings = self.get_image_features(processed_inputs)
492
 
493
  if normalize_embeddings: