parkerjj commited on
Commit
01dcd9c
·
1 Parent(s): 768a233

设置环境变量以指定 Hugging Face 缓存路径

Browse files
Files changed (1) hide show
  1. blkeras.py +2 -1
blkeras.py CHANGED
@@ -23,7 +23,8 @@ from RequestModel import PredictRequest
23
  from app import TextRequest
24
  from us_stock import find_stock_codes_or_names
25
  os.environ["TOKENIZERS_PARALLELISM"] = "false"
26
-
 
27
 
28
  # 加载模型
29
  model = None
 
23
  from app import TextRequest
24
  from us_stock import find_stock_codes_or_names
25
  os.environ["TOKENIZERS_PARALLELISM"] = "false"
26
+ # 设置环境变量,指定 Hugging Face 缓存路径
27
+ os.environ["HF_HOME"] = "/tmp/huggingface"
28
 
29
  # 加载模型
30
  model = None