kazuma313 commited on
Commit
556d27c
1 Parent(s): bce5fbb

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -0
app.py CHANGED
@@ -10,6 +10,7 @@ device_map = "auto"
10
 
11
  base_model = AutoModelForCausalLM.from_pretrained(
12
  model_name,
 
13
  low_cpu_mem_usage=True,
14
  return_dict=True,
15
  torch_dtype=torch.float16,
@@ -20,6 +21,7 @@ model = model.merge_and_unload()
20
 
21
  # Reload tokenizer to save it
22
  tokenizer = AutoTokenizer.from_pretrained(model_name,
 
23
  trust_remote_code=True)
24
  tokenizer.pad_token = tokenizer.eos_token
25
  tokenizer.padding_side = "right"
 
10
 
11
  base_model = AutoModelForCausalLM.from_pretrained(
12
  model_name,
13
+ token=hf_token,
14
  low_cpu_mem_usage=True,
15
  return_dict=True,
16
  torch_dtype=torch.float16,
 
21
 
22
  # Reload tokenizer to save it
23
  tokenizer = AutoTokenizer.from_pretrained(model_name,
24
+ token=hf_token,
25
  trust_remote_code=True)
26
  tokenizer.pad_token = tokenizer.eos_token
27
  tokenizer.padding_side = "right"