Commit
·
eeea4d4
1
Parent(s):
aff5c65
Upload config
Browse files- config.json +2 -17
- configuration_bert.py +3 -24
config.json
CHANGED
|
@@ -1,18 +1,10 @@
|
|
| 1 |
{
|
| 2 |
-
"affine":
|
| 3 |
-
"alpha": 1,
|
| 4 |
-
"architectures": [
|
| 5 |
-
"BertForSequenceClassification"
|
| 6 |
-
],
|
| 7 |
"attention_probs_dropout_prob": 0.1,
|
| 8 |
"auto_map": {
|
| 9 |
-
"AutoConfig": "configuration_bert.BertConfig"
|
| 10 |
-
"AutoModelForSequenceClassification": "modeling_bert.BertForSequenceClassification"
|
| 11 |
},
|
| 12 |
-
"center": false,
|
| 13 |
"classifier_dropout": null,
|
| 14 |
-
"do_pcr": true,
|
| 15 |
-
"do_pfsa": true,
|
| 16 |
"hidden_act": "gelu",
|
| 17 |
"hidden_dropout_prob": 0.1,
|
| 18 |
"hidden_size": 768,
|
|
@@ -21,17 +13,10 @@
|
|
| 21 |
"layer_norm_eps": 1e-12,
|
| 22 |
"max_position_embeddings": 512,
|
| 23 |
"model_type": "bert",
|
| 24 |
-
"normalize": false,
|
| 25 |
"num_attention_heads": 12,
|
| 26 |
"num_hidden_layers": 12,
|
| 27 |
-
"num_iters": 1,
|
| 28 |
"pad_token_id": 0,
|
| 29 |
"position_embedding_type": "absolute",
|
| 30 |
-
"q": 5,
|
| 31 |
-
"r": 1,
|
| 32 |
-
"return_mean": true,
|
| 33 |
-
"return_std": true,
|
| 34 |
-
"torch_dtype": "float32",
|
| 35 |
"transformers_version": "4.33.3",
|
| 36 |
"type_vocab_size": 2,
|
| 37 |
"use_cache": true,
|
|
|
|
| 1 |
{
|
| 2 |
+
"affine": true,
|
|
|
|
|
|
|
|
|
|
|
|
|
| 3 |
"attention_probs_dropout_prob": 0.1,
|
| 4 |
"auto_map": {
|
| 5 |
+
"AutoConfig": "configuration_bert.BertConfig"
|
|
|
|
| 6 |
},
|
|
|
|
| 7 |
"classifier_dropout": null,
|
|
|
|
|
|
|
| 8 |
"hidden_act": "gelu",
|
| 9 |
"hidden_dropout_prob": 0.1,
|
| 10 |
"hidden_size": 768,
|
|
|
|
| 13 |
"layer_norm_eps": 1e-12,
|
| 14 |
"max_position_embeddings": 512,
|
| 15 |
"model_type": "bert",
|
|
|
|
| 16 |
"num_attention_heads": 12,
|
| 17 |
"num_hidden_layers": 12,
|
|
|
|
| 18 |
"pad_token_id": 0,
|
| 19 |
"position_embedding_type": "absolute",
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 20 |
"transformers_version": "4.33.3",
|
| 21 |
"type_vocab_size": 2,
|
| 22 |
"use_cache": true,
|
configuration_bert.py
CHANGED
|
@@ -22,18 +22,8 @@ class BertConfig(PretrainedConfig):
|
|
| 22 |
pad_token_id=0,
|
| 23 |
position_embedding_type="absolute",
|
| 24 |
use_cache=True,
|
| 25 |
-
classifier_dropout=None,
|
| 26 |
-
affine=
|
| 27 |
-
q=5,
|
| 28 |
-
r=1,
|
| 29 |
-
center=False,
|
| 30 |
-
num_iters=1,
|
| 31 |
-
return_mean=True,
|
| 32 |
-
return_std=True,
|
| 33 |
-
normalize=False,
|
| 34 |
-
do_pcr=True,
|
| 35 |
-
do_pfsa=True,
|
| 36 |
-
alpha=1,
|
| 37 |
**kwargs,
|
| 38 |
):
|
| 39 |
super().__init__(pad_token_id=pad_token_id, **kwargs)
|
|
@@ -53,15 +43,4 @@ class BertConfig(PretrainedConfig):
|
|
| 53 |
self.position_embedding_type = position_embedding_type
|
| 54 |
self.use_cache = use_cache
|
| 55 |
self.classifier_dropout = classifier_dropout
|
| 56 |
-
self.affine = affine
|
| 57 |
-
|
| 58 |
-
self.q = q
|
| 59 |
-
self.r = r
|
| 60 |
-
self.center = center
|
| 61 |
-
self.num_iters = num_iters
|
| 62 |
-
self.return_mean = return_mean
|
| 63 |
-
self.return_std = return_std
|
| 64 |
-
self.normalize = normalize
|
| 65 |
-
self.do_pcr = do_pcr
|
| 66 |
-
self.do_pfsa = do_pfsa
|
| 67 |
-
self.alpha = alpha
|
|
|
|
| 22 |
pad_token_id=0,
|
| 23 |
position_embedding_type="absolute",
|
| 24 |
use_cache=True,
|
| 25 |
+
classifier_dropout=None,
|
| 26 |
+
affine=True,
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 27 |
**kwargs,
|
| 28 |
):
|
| 29 |
super().__init__(pad_token_id=pad_token_id, **kwargs)
|
|
|
|
| 43 |
self.position_embedding_type = position_embedding_type
|
| 44 |
self.use_cache = use_cache
|
| 45 |
self.classifier_dropout = classifier_dropout
|
| 46 |
+
self.affine = affine
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|