adpro commited on
Commit
3b1c0bd
·
verified ·
1 Parent(s): 4b32247

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -14,8 +14,8 @@ app = FastAPI()
14
  device = torch.device("cuda" if torch.cuda.is_available() else "cpu")
15
 
16
  # 🟢 Tải model DPT-Hybrid thay cho ZoeDepth để tăng tốc
17
- feature_extractor = DPTFeatureExtractor.from_pretrained("Intel/dpt-small")
18
- model = DPTForDepthEstimation.from_pretrained("Intel/dpt-small").to(device)
19
  model.eval()
20
 
21
  @app.post("/analyze_path/")
 
14
  device = torch.device("cuda" if torch.cuda.is_available() else "cpu")
15
 
16
  # 🟢 Tải model DPT-Hybrid thay cho ZoeDepth để tăng tốc
17
+ feature_extractor = DPTFeatureExtractor.from_pretrained("Intel/dpt-swinv2-tiny-256")
18
+ model = DPTForDepthEstimation.from_pretrained("Intel/dpt-swinv2-tiny-256").to(device)
19
  model.eval()
20
 
21
  @app.post("/analyze_path/")