Update utils.py
Browse files
utils.py
CHANGED
|
@@ -116,7 +116,7 @@ def prepare_tokenizer(tokenizer_name: str, padding_side="right"):
|
|
| 116 |
|
| 117 |
|
| 118 |
def get_decoder_model(
|
| 119 |
-
model_name_or_path: str, attn_implementation: str, bidirectional: bool, base_cfg
|
| 120 |
):
|
| 121 |
"""
|
| 122 |
base_cfg is the pretrained config of the underlying model
|
|
@@ -135,6 +135,7 @@ def get_decoder_model(
|
|
| 135 |
config=base_cfg,
|
| 136 |
torch_dtype=torch.bfloat16,
|
| 137 |
attn_implementation=attn_implementation,
|
|
|
|
| 138 |
)
|
| 139 |
|
| 140 |
|
|
|
|
| 116 |
|
| 117 |
|
| 118 |
def get_decoder_model(
|
| 119 |
+
model_name_or_path: str, attn_implementation: str, bidirectional: bool, base_cfg, token=None
|
| 120 |
):
|
| 121 |
"""
|
| 122 |
base_cfg is the pretrained config of the underlying model
|
|
|
|
| 135 |
config=base_cfg,
|
| 136 |
torch_dtype=torch.bfloat16,
|
| 137 |
attn_implementation=attn_implementation,
|
| 138 |
+
token=token,
|
| 139 |
)
|
| 140 |
|
| 141 |
|