File size: 2,363 Bytes
c1fd66c |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 |
{
"compression": [
{
"algorithm": "movement_sparsity",
"ignored_scopes": [
"{re}.*MobileBertEmbeddings.*",
"{re}.*Bottleneck.*",
"{re}.*OutputBottleneck.*",
"{re}.*qa_outputs.*"
],
"params": {
"enable_structured_masking": true,
"importance_regularization_factor": 0.065,
"warmup_end_epoch": 10,
"warmup_start_epoch": 3
},
"sparse_structure_by_scopes": [
{
"mode": "block",
"sparse_factors": [
16,
16
],
"target_scopes": "{re}.*MobileBertAttention.*"
},
{
"axis": 0,
"mode": "per_dim",
"target_scopes": "{re}.*MobileBertIntermediate.*"
},
{
"axis": 1,
"mode": "per_dim",
"target_scopes": "{re}.*MobileBertOutput.*"
},
{
"axis": 1,
"mode": "per_dim",
"target_scopes": "{re}.*FFNOutput.*"
}
]
},
{
"algorithm": "quantization",
"export_to_onnx_standard_ops": false,
"ignored_scopes": [
"{re}.*__add___[0-1]",
"{re}.*__truediv__*"
],
"initializer": {
"batchnorm_adaptation": {
"num_bn_adaptation_samples": 16
},
"range": {
"num_init_samples": 128,
"params": {
"max_percentile": 99.99,
"min_percentile": 0.01
},
"type": "percentile"
}
},
"overflow_fix": "disable",
"preset": "mixed",
"scope_overrides": {
"activations": {
"{re}.*matmul_0": {
"mode": "symmetric"
}
}
}
}
],
"input_info": [
{
"keyword": "input_ids",
"sample_size": [
32,
384
],
"type": "long"
},
{
"keyword": "token_type_ids",
"sample_size": [
32,
384
],
"type": "long"
},
{
"keyword": "attention_mask",
"sample_size": [
32,
384
],
"type": "long"
}
],
"log_dir": "/nvme2/yujiepan/workspace/jpqd-test/LOGS/optimum-mobilebert-qa/0127_ttev_ftz8ih_epo18lr2e-06teacher0.95cosDecayRestart",
"optimum_version": "1.6.1",
"save_onnx_model": false,
"transformers_version": "4.25.1"
}
|