amaye15 commited on
Commit
b0a7877
1 Parent(s): a737583
Files changed (1) hide show
  1. handler.py +1 -1
handler.py CHANGED
@@ -152,7 +152,7 @@ class EndpointHandler:
152
  try:
153
  image_embeddings_tensor = torch.tensor(image_embeddings).to(self.device)
154
  text_embeddings_tensor = torch.tensor(text_embeddings).to(self.device)
155
- with torch.no_grad(), torch.amp.autocast():
156
  scores = (
157
  self.processor.score_multi_vector(
158
  text_embeddings_tensor, image_embeddings_tensor
 
152
  try:
153
  image_embeddings_tensor = torch.tensor(image_embeddings).to(self.device)
154
  text_embeddings_tensor = torch.tensor(text_embeddings).to(self.device)
155
+ with torch.no_grad():
156
  scores = (
157
  self.processor.score_multi_vector(
158
  text_embeddings_tensor, image_embeddings_tensor