ZhengPeng7
commited on
Commit
•
407e35d
1
Parent(s):
2a41a22
For users to load in one key.
Browse files- BiRefNet_github/models/birefnet.py +1 -1
- config.json +1 -1
BiRefNet_github/models/birefnet.py
CHANGED
@@ -114,7 +114,7 @@ class BiRefNet(
|
|
114 |
def forward(self, x):
|
115 |
scaled_preds, class_preds = self.forward_ori(x)
|
116 |
class_preds_lst = [class_preds]
|
117 |
-
return [scaled_preds, class_preds_lst] if self.training else scaled_preds
|
118 |
|
119 |
|
120 |
class Decoder(nn.Module):
|
|
|
114 |
def forward(self, x):
|
115 |
scaled_preds, class_preds = self.forward_ori(x)
|
116 |
class_preds_lst = [class_preds]
|
117 |
+
return [scaled_preds, class_preds_lst] if self.training and 0 else scaled_preds
|
118 |
|
119 |
|
120 |
class Decoder(nn.Module):
|
config.json
CHANGED
@@ -4,7 +4,7 @@
|
|
4 |
"BiRefNet"
|
5 |
],
|
6 |
"auto_map": {
|
7 |
-
"AutoModelForImageSegmentation": "
|
8 |
},
|
9 |
"custom_pipelines": {
|
10 |
"image-segmentation": {
|
|
|
4 |
"BiRefNet"
|
5 |
],
|
6 |
"auto_map": {
|
7 |
+
"AutoModelForImageSegmentation": "BiRefNet_github.models.birefnet.BiRefNet"
|
8 |
},
|
9 |
"custom_pipelines": {
|
10 |
"image-segmentation": {
|