ZhengPeng7 xiaoxiao112233 commited on
Commit
b7d7f31
·
verified ·
1 Parent(s): 6a62b7d

Compatible with the latest version of transformers (#18)

Browse files

- Compatible with the latest version of transformers (51c9ad2140729fe0076ad50f601669316d69d4b0)


Co-authored-by: xiaoxiao112233 <[email protected]>

Files changed (1) hide show
  1. birefnet.py +3 -0
birefnet.py CHANGED
@@ -7,6 +7,9 @@ from transformers import PretrainedConfig
7
 
8
  class Config(PretrainedConfig):
9
  def __init__(self) -> None:
 
 
 
10
  # PATH settings
11
  self.sys_home_dir = os.path.expanduser('~') # Make up your file system as: SYS_HOME_DIR/codes/dis/BiRefNet, SYS_HOME_DIR/datasets/dis/xx, SYS_HOME_DIR/weights/xx
12
 
 
7
 
8
  class Config(PretrainedConfig):
9
  def __init__(self) -> None:
10
+ # Compatible with the latest version of transformers
11
+ super().__init__()
12
+
13
  # PATH settings
14
  self.sys_home_dir = os.path.expanduser('~') # Make up your file system as: SYS_HOME_DIR/codes/dis/BiRefNet, SYS_HOME_DIR/datasets/dis/xx, SYS_HOME_DIR/weights/xx
15