Cyrile commited on
Commit
71efac8
1 Parent(s): d42850a

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +0 -4
README.md CHANGED
@@ -70,10 +70,6 @@ tokenizer = AutoTokenizer.from_pretrained('cmarkea/bloomz-3b-retriever-v2')
70
  model = AutoModel.from_pretrained('cmarkea/bloomz-3b-retriever-v2')
71
 
72
  def infer(txt: Union[str, List[str]]):
73
- if isinstance(txt, str):
74
- length = 0
75
- else:
76
- length = len(txt)
77
  tok = tokenizer(txt, padding=True, return_tensors='pt')
78
  with torch.no_grad():
79
  embedding = model(**tok)
 
70
  model = AutoModel.from_pretrained('cmarkea/bloomz-3b-retriever-v2')
71
 
72
  def infer(txt: Union[str, List[str]]):
 
 
 
 
73
  tok = tokenizer(txt, padding=True, return_tensors='pt')
74
  with torch.no_grad():
75
  embedding = model(**tok)