Skip to content

Commit

Permalink
Update web_demo.py
Browse files Browse the repository at this point in the history
  • Loading branch information
GradientGuru authored Jul 11, 2023
1 parent 035f701 commit d12a878
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions web_demo.py
Original file line number Diff line number Diff line change
@@ -1,7 1,7 @@
import json
import torch
import streamlit as st
from transformers import AutoModel, AutoTokenizer
from transformers import AutoModelForCausalLM, AutoTokenizer
from transformers.generation.utils import GenerationConfig


Expand All @@ -11,7 11,7 @@

@st.cache_resource
def init_model():
model = AutoModel.from_pretrained(
model = AutoModelForCausalLM.from_pretrained(
"baichuan-inc/Baichuan-13B-Chat",
torch_dtype=torch.float16,
device_map="auto",
Expand Down

0 comments on commit d12a878

Please sign in to comment.