farrosalferro24 commited on
Commit
1a97e74
β€’
1 Parent(s): c1f540b

Update model/modelling_gecko.py

Browse files
Files changed (1) hide show
  1. model/modelling_gecko.py +2 -2
model/modelling_gecko.py CHANGED
@@ -184,9 +184,9 @@ class GeckoForConditionalGeneration(GeckoPreTrainedModel):
184
  self.eos_token_id = [self.tokenizer.eos_token_id, self.tokenizer.convert_tokens_to_ids("<|eot_id|>")]
185
  self.encoder_type = self.config.vision_config.model_type
186
  if 'clip' in self.encoder_type:
187
- self.encoder = AutoModel.from_pretrained('openai/clip-vit-large-patch14-336', torch_dtype=self.dtype, device_map=self.device)
188
  elif 'siglip' in self.encoder_type:
189
- self.encoder = AutoModel.from_pretrained("google/siglip-so400m-patch14-384", torch_dtype=self.dtype, device_map=self.device)
190
  else:
191
  raise ValueError(f"Vision model {self.config.vision_config.model_type} is not supported.")
192
 
 
184
  self.eos_token_id = [self.tokenizer.eos_token_id, self.tokenizer.convert_tokens_to_ids("<|eot_id|>")]
185
  self.encoder_type = self.config.vision_config.model_type
186
  if 'clip' in self.encoder_type:
187
+ self.encoder = AutoModel.from_pretrained('openai/clip-vit-large-patch14-336')
188
  elif 'siglip' in self.encoder_type:
189
+ self.encoder = AutoModel.from_pretrained("google/siglip-so400m-patch14-384")
190
  else:
191
  raise ValueError(f"Vision model {self.config.vision_config.model_type} is not supported.")
192