4n3mone commited on
Commit
b6fd14e
β€’
1 Parent(s): 8665444

Update koalpaca.py

Browse files
Files changed (1) hide show
  1. koalpaca.py +1 -1
koalpaca.py CHANGED
@@ -14,7 +14,7 @@ class KoAlpaca(Model):
14
  bnb_4bit_compute_dtype=torch.bfloat16
15
  )
16
  #self.model = AutoModelForCausalLM.from_pretrained(config.base_model_name_or_path, quantization_config=self.bnb_config, device_map={"":0})
17
- self.model = AutoModelForCausalLM.from_pretrained(config.base_model_name_or_path, quantization_config=self.bnb_config, device_map=auto)
18
  self.model = PeftModel.from_pretrained(self.model, peft_model_id)
19
  self.tokenizer = AutoTokenizer.from_pretrained(config.base_model_name_or_path)
20
  self.gen_config = GenerationConfig.from_pretrained('./models/koalpaca', 'gen_config.json')
 
14
  bnb_4bit_compute_dtype=torch.bfloat16
15
  )
16
  #self.model = AutoModelForCausalLM.from_pretrained(config.base_model_name_or_path, quantization_config=self.bnb_config, device_map={"":0})
17
+ self.model = AutoModelForCausalLM.from_pretrained(config.base_model_name_or_path, quantization_config=self.bnb_config, device_map='auto')
18
  self.model = PeftModel.from_pretrained(self.model, peft_model_id)
19
  self.tokenizer = AutoTokenizer.from_pretrained(config.base_model_name_or_path)
20
  self.gen_config = GenerationConfig.from_pretrained('./models/koalpaca', 'gen_config.json')