NightPrince commited on
Commit
593f048
·
verified ·
1 Parent(s): 5a367a5

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +4 -2
app.py CHANGED
@@ -6,10 +6,12 @@ from transformers import pipeline
6
  from huggingface_hub import model_info
7
  import os # must be before setting environment variables
8
 
9
- import os
10
  os.environ["TRANSFORMERS_CACHE"] = "/app/cache"
11
  os.environ["HF_HOME"] = "/app/hf_home"
12
- os.environ["HUGGINGFACE_HUB_CACHE"] = "/app/cache/huggingface"
 
 
 
13
 
14
  MODEL_NAME = "tarteel-ai/whisper-base-ar-quran" #this always needs to stay in line 8 :D sorry for the hackiness
15
  lang = "ar"
 
6
  from huggingface_hub import model_info
7
  import os # must be before setting environment variables
8
 
 
9
  os.environ["TRANSFORMERS_CACHE"] = "/app/cache"
10
  os.environ["HF_HOME"] = "/app/hf_home"
11
+ os.environ["HUGGINGFACE_HUB_CACHE"] = "/app/hf_home"
12
+
13
+ os.makedirs("/app/cache", exist_ok=True)
14
+ os.makedirs("/app/hf_home", exist_ok=True)
15
 
16
  MODEL_NAME = "tarteel-ai/whisper-base-ar-quran" #this always needs to stay in line 8 :D sorry for the hackiness
17
  lang = "ar"