dbmoradi60 commited on
Commit
6de0edc
·
verified ·
1 Parent(s): 6bd30a2

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -4
app.py CHANGED
@@ -28,11 +28,9 @@ if os.path.exists(cache_dir):
28
  else:
29
  os.remove(item_path) if os.path.exists(item_path) else None
30
 
31
- # Create cache and model directories with proper permissions
32
  os.makedirs(cache_dir, exist_ok=True)
33
- os.chmod(cache_dir, 0o777)
34
  os.makedirs(MODEL_DIR, exist_ok=True)
35
- os.chmod(MODEL_DIR, 0o777)
36
 
37
  # Download model files explicitly
38
  print("Downloading model files...")
@@ -121,4 +119,4 @@ torch.cuda.empty_cache()
121
 
122
  if __name__ == "__main__":
123
  import uvicorn
124
- uvicorn.run(app, host="0.0.0.0", port=8000)
 
28
  else:
29
  os.remove(item_path) if os.path.exists(item_path) else None
30
 
31
+ # Create cache and model directories (no chmod needed)
32
  os.makedirs(cache_dir, exist_ok=True)
 
33
  os.makedirs(MODEL_DIR, exist_ok=True)
 
34
 
35
  # Download model files explicitly
36
  print("Downloading model files...")
 
119
 
120
  if __name__ == "__main__":
121
  import uvicorn
122
+ uvicorn.run(app, host="0.0.0.0", port=8005)