-
Notifications
You must be signed in to change notification settings - Fork 53
Expand file tree
/
Copy pathconfig_text_encoder.json
More file actions
57 lines (57 loc) · 2.13 KB
/
Copy pathconfig_text_encoder.json
File metadata and controls
57 lines (57 loc) · 2.13 KB
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
{
"input_model": {
"type": "PyTorchModel",
"model_path": "sd-legacy/stable-diffusion-v1-5",
"model_loader": "text_encoder_load",
"script_dir": ".",
"model_script": "user_script.py",
"io_config": {
"input_names": [ "input_ids" ],
"output_names": [ "last_hidden_state", "pooler_output" ],
"dynamic_axes": { "input_ids": { "0": "batch", "1": "sequence" } }
},
"dummy_inputs_func": "text_encoder_conversion_inputs"
},
"passes": {
"convert": { "type": "OnnxConversion", "target_opset": 14 },
"optimize": {
"type": "OrtTransformersOptimization",
"model_type": "clip",
"opt_level": 0,
"float16": true,
"use_gpu": true,
"keep_io_types": false,
"optimization_options": {
"enable_gelu": true,
"enable_layer_norm": true,
"enable_attention": true,
"use_multi_head_attention": true,
"enable_skip_layer_norm": false,
"enable_embed_layer_norm": true,
"enable_bias_skip_layer_norm": false,
"enable_bias_gelu": true,
"enable_gelu_approximation": false,
"enable_qordered_matmul": false,
"enable_shape_inference": true,
"enable_gemm_fast_gelu": false,
"enable_nhwc_conv": false,
"enable_group_norm": true,
"enable_bias_splitgelu": false,
"enable_packed_qkv": true,
"enable_packed_kv": true,
"enable_bias_add": false,
"group_norm_channels_last": false
},
"force_fp32_ops": [ "RandomNormalLike" ],
"force_fp16_inputs": { "GroupNorm": [ 0, 1, 2 ] }
},
"dynamic_shape_to_fixed": {
"type": "DynamicToFixedShape",
"dim_param": [ "batch", "sequence" ],
"dim_value": [ 1, 77 ]
}
},
"log_severity_level": 0,
"cache_dir": "vai_cache",
"output_dir": "footprints/text_encoder"
}