AIDSC commited on
Commit
9beb876
1 Parent(s): 05e04bc

Update handler.py

Browse files
Files changed (1) hide show
  1. handler.py +0 -1
handler.py CHANGED
@@ -34,7 +34,6 @@ class EndpointHandler():
34
  inputs = self.tokenizer(prompt, return_tensors="pt").to(self.device)
35
  input_size = inputs['input_ids'].size(1)
36
  input_ids = inputs["input_ids"].to(self.device)
37
- inputs.pop("token_type_ids")
38
  outputs = self.model(**inputs)
39
  last_token_logits = outputs.logits[:, -1, :]
40
  options_tokens_logits = last_token_logits[:, self.options_tokens].detach().cpu().numpy()
 
34
  inputs = self.tokenizer(prompt, return_tensors="pt").to(self.device)
35
  input_size = inputs['input_ids'].size(1)
36
  input_ids = inputs["input_ids"].to(self.device)
 
37
  outputs = self.model(**inputs)
38
  last_token_logits = outputs.logits[:, -1, :]
39
  options_tokens_logits = last_token_logits[:, self.options_tokens].detach().cpu().numpy()