logo
Browse Source

l

Signed-off-by: xujinling <jinling.xu@zilliz.com>
main
xujinling 3 years ago
parent
commit
ddfb0178a8
  1. 2
      bridge_former.py

2
bridge_former.py

@ -84,7 +84,7 @@ class BridgeFormer(NNOperator):
if self.model_name == "clip_initialized_model":
text_data = tokenize(text).to(self.device)
text_features = self.model.encode_text(text_data["input_ids"])
text_features = self.model.encode_text(text_data)
else:
text_data = self.tokenizer(text, return_tensors='pt').to(self.device)
text_features = self.model.compute_text(text_data)

Loading…
Cancel
Save