Skip to content

Commit

Permalink
Fix the bug that openxlab platform cannot be deployed. (#187)
Browse files Browse the repository at this point in the history
This PR adds `python download_model.py {model_name_path}` before using streamlit to deploy the model
  • Loading branch information
chg0901 authored Apr 13, 2024
2 parents bad86d2 + 8e4e09e commit 889d86b
Showing 1 changed file with 12 additions and 2 deletions.
14 changes: 12 additions & 2 deletions app.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,13 @@
import os
os.system('streamlit run web_internlm2.py --server.address=0.0.0.0 --server.port 7860')
#os.system('streamlit run web_demo-aiwei.py --server.address=0.0.0.0 --server.port 7860')

#model = "EmoLLM_aiwei"
model = "EmoLLM_Model"

if model == "EmoLLM_aiwei":
os.system("python download_model.py ajupyter/EmoLLM_aiwei")
os.system('streamlit run web_demo-aiwei.py --server.address=0.0.0.0 --server.port 7860')
elif model == "EmoLLM_Model":
os.system("python download_model.py jujimeizuo/EmoLLM_Model")
os.system('streamlit run web_internlm2.py --server.address=0.0.0.0 --server.port 7860')
else:
print("Please select one model")

0 comments on commit 889d86b

Please sign in to comment.