yuhuili commited on
Commit
75b08df
1 Parent(s): 18a3529

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -1
app.py CHANGED
@@ -75,6 +75,7 @@ def highlight_text(text, text_list,color="black"):
75
 
76
  @spaces.GPU(duration=30)
77
  def warmup(model):
 
78
  conv = get_conversation_template(args.model_type)
79
 
80
  if args.model_type == "llama-2-chat":
@@ -277,7 +278,7 @@ model = LlamaForCausalLM.from_pretrained(
277
  load_in_8bit=args.load_in_8bit,
278
  device_map="auto",
279
  )
280
- model.cuda()
281
  model.eval()
282
  tokenizer=AutoTokenizer.from_pretrained(args.base_model_path)
283
  warmup(model)
 
75
 
76
  @spaces.GPU(duration=30)
77
  def warmup(model):
78
+ model.cuda()
79
  conv = get_conversation_template(args.model_type)
80
 
81
  if args.model_type == "llama-2-chat":
 
278
  load_in_8bit=args.load_in_8bit,
279
  device_map="auto",
280
  )
281
+
282
  model.eval()
283
  tokenizer=AutoTokenizer.from_pretrained(args.base_model_path)
284
  warmup(model)