(self, input)
| 304 | |
| 305 | |
| 306 | def forward(self, input): |
| 307 | inputs = self.tokenizer(input, return_tensors='pt', truncation=True, padding=True).to(self.textmodel.device) |
| 308 | |
| 309 | with torch.no_grad(): |
| 310 | outputs = self.textmodel(**inputs) |
| 311 | |
| 312 | text_embedding = outputs[0][:,0,:].squeeze() |
| 313 | return text_embedding |
nothing calls this directly
no outgoing calls
no test coverage detected