Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -12,7 +12,7 @@ device = torch.device("cuda" if torch.cuda.is_available() else "cpu")
|
|
12 |
|
13 |
birefnet = AutoModelForImageSegmentation.from_pretrained('ZhengPeng7/BiRefNet', trust_remote_code=True)
|
14 |
torch.set_float32_matmul_precision(['high', 'highest'][0])
|
15 |
-
birefnet.to(
|
16 |
birefnet.eval()
|
17 |
birefnet.half()
|
18 |
|
|
|
12 |
|
13 |
birefnet = AutoModelForImageSegmentation.from_pretrained('ZhengPeng7/BiRefNet', trust_remote_code=True)
|
14 |
torch.set_float32_matmul_precision(['high', 'highest'][0])
|
15 |
+
birefnet.to(device)
|
16 |
birefnet.eval()
|
17 |
birefnet.half()
|
18 |
|