not-lain commited on
Commit
f3d3ce9
β€’
1 Parent(s): c368dca

🌘wπŸŒ–

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -6,9 +6,9 @@ from transformers import AutoModelForImageSegmentation
6
  import torch
7
  from torchvision import transforms
8
 
9
- # torch.set_float32_matmul_precision(['high', 'highest'][0])
10
 
11
- birefnet = AutoModelForImageSegmentation.from_pretrained('zhengpeng7/BiRefNet', trust_remote_code=True,torch_dtype=torch.float16)
12
  birefnet.to("cuda")
13
  transform_image = transforms.Compose([
14
  transforms.Resize((1024, 1024)),
 
6
  import torch
7
  from torchvision import transforms
8
 
9
+ torch.set_float32_matmul_precision(['high', 'highest'][0])
10
 
11
+ birefnet = AutoModelForImageSegmentation.from_pretrained('zhengpeng7/BiRefNet', trust_remote_code=True)
12
  birefnet.to("cuda")
13
  transform_image = transforms.Compose([
14
  transforms.Resize((1024, 1024)),