Spaces:
Running
on
Zero
Running
on
Zero
Update utils/model.py
Browse files- utils/model.py +1 -1
utils/model.py
CHANGED
@@ -420,7 +420,7 @@ class OwlViTForClassification(nn.Module):
|
|
420 |
#DEUBUG:
|
421 |
print(f"text_inputs_parts - input_ids: {text_inputs_parts['input_ids'].shape}. attention_mask : {text_inputs_parts['attention_mask'].shape}")
|
422 |
print(f"position_embedding: {self.owlvit.position_embedding()}")
|
423 |
-
text_embeds_parts = self.owlvit.get_text_features(**text_inputs_parts)
|
424 |
|
425 |
# # Embed images and text queries
|
426 |
query_mask, text_embeds_parts = self._get_text_query_mask(text_inputs_parts, text_embeds_parts, batch_size)
|
|
|
420 |
#DEUBUG:
|
421 |
print(f"text_inputs_parts - input_ids: {text_inputs_parts['input_ids'].shape}. attention_mask : {text_inputs_parts['attention_mask'].shape}")
|
422 |
print(f"position_embedding: {self.owlvit.position_embedding()}")
|
423 |
+
text_embeds_parts = self.owlvit.text_model.text_model.get_text_features(**text_inputs_parts)
|
424 |
|
425 |
# # Embed images and text queries
|
426 |
query_mask, text_embeds_parts = self._get_text_query_mask(text_inputs_parts, text_embeds_parts, batch_size)
|