Fix vocab_size=32000
Browse files- pico_decoder.py +1 -5
pico_decoder.py
CHANGED
|
@@ -173,7 +173,7 @@ class PicoDecoder(nn.Module):
|
|
| 173 |
|
| 174 |
class PicoDecoderHFConfig(PretrainedConfig):
|
| 175 |
model_type = "pico_decoder"
|
| 176 |
-
def __init__(self,
|
| 177 |
n_layers=14, d_model=768, vocab_size=32768,
|
| 178 |
attention_n_heads=12, attention_n_kv_heads=1,
|
| 179 |
max_seq_len=512, batch_size=64, position_emb_theta=10000.0,
|
|
@@ -216,10 +216,6 @@ class PicoDecoderHF(PreTrainedModel):
|
|
| 216 |
_no_split_modules = ["PicoDecoderBlock"]
|
| 217 |
_tied_weights_keys = []
|
| 218 |
|
| 219 |
-
@property
|
| 220 |
-
def all_tied_weights_keys(self):
|
| 221 |
-
return {}
|
| 222 |
-
|
| 223 |
def __init__(self, config: PicoDecoderHFConfig):
|
| 224 |
super().__init__(config)
|
| 225 |
self.embedding_proj = nn.Embedding(config.vocab_size, config.d_model)
|
|
|
|
| 173 |
|
| 174 |
class PicoDecoderHFConfig(PretrainedConfig):
|
| 175 |
model_type = "pico_decoder"
|
| 176 |
+
def __init__(self,
|
| 177 |
n_layers=14, d_model=768, vocab_size=32768,
|
| 178 |
attention_n_heads=12, attention_n_kv_heads=1,
|
| 179 |
max_seq_len=512, batch_size=64, position_emb_theta=10000.0,
|
|
|
|
| 216 |
_no_split_modules = ["PicoDecoderBlock"]
|
| 217 |
_tied_weights_keys = []
|
| 218 |
|
|
|
|
|
|
|
|
|
|
|
|
|
| 219 |
def __init__(self, config: PicoDecoderHFConfig):
|
| 220 |
super().__init__(config)
|
| 221 |
self.embedding_proj = nn.Embedding(config.vocab_size, config.d_model)
|