pvduy commited on
Commit
aa3b7c5
1 Parent(s): af83917

fetch model

Browse files
Files changed (1) hide show
  1. app.py +1 -0
app.py CHANGED
@@ -59,6 +59,7 @@ if __name__ == "__main__":
59
  tokenizer = AutoTokenizer.from_pretrained("stabilityai/stable-code-instruct-3b")
60
  model = AutoModelForCausalLM.from_pretrained("stabilityai/stable-code-instruct-3b")
61
  device = torch.device('cuda' if torch.cuda.is_available() else 'cpu')
 
62
  model = model.to(device)
63
  gr.ChatInterface(
64
  predict,
 
59
  tokenizer = AutoTokenizer.from_pretrained("stabilityai/stable-code-instruct-3b")
60
  model = AutoModelForCausalLM.from_pretrained("stabilityai/stable-code-instruct-3b")
61
  device = torch.device('cuda' if torch.cuda.is_available() else 'cpu')
62
+ model = model.half()
63
  model = model.to(device)
64
  gr.ChatInterface(
65
  predict,