Xenova's picture
Xenova HF Staff
sync 2e7068faf55e
e82d8e1 verified
Raw
History Blame
12.2 kB
{
"op": "ai.onnx.CausalConvWithState",
"cases": [
{
"name": "scalar_zero_state",
"attrs": { "activation": "none" },
"inputs": {
"inputT": {
"shape": [1, 2, 3],
"dtype": "float32",
"data": { "kind": "fillFloat32", "sinStep": 0.17, "cosStep": 0.29, "scale": 0.25 }
},
"weightT": {
"shape": [2, 1, 3],
"dtype": "float32",
"data": { "kind": "fillFloat32", "sinStep": 0.23, "cosStep": 0.11, "scale": 0.2 }
}
},
"outputs": {
"outputT": { "shape": [1, 2, 3], "dtype": "float32" },
"presentStateT": { "shape": [1, 2, 2], "dtype": "float32" }
}
},
{
"name": "scalar_bias_no_state",
"attrs": { "activation": "none" },
"inputs": {
"inputT": {
"shape": [1, 2, 5],
"dtype": "float32",
"data": { "kind": "fillFloat32", "sinStep": 0.19, "cosStep": 0.31, "scale": 0.25 }
},
"weightT": {
"shape": [2, 1, 5],
"dtype": "float32",
"data": { "kind": "fillFloat32", "sinStep": 0.13, "cosStep": 0.27, "scale": 0.2 }
},
"biasT": {
"shape": [2],
"dtype": "float32",
"data": { "kind": "fillFloat32", "sinStep": 0.37, "cosStep": 0.07, "scale": 0.1 }
}
},
"outputs": {
"outputT": { "shape": [1, 2, 5], "dtype": "float32" },
"presentStateT": { "shape": [1, 2, 4], "dtype": "float32" }
}
},
{
"name": "scalar_state_no_bias_swish",
"attrs": { "activation": "swish" },
"inputs": {
"inputT": {
"shape": [1, 2, 1],
"dtype": "float32",
"data": { "kind": "fillFloat32", "sinStep": 0.11, "cosStep": 0.33, "scale": 0.25 }
},
"weightT": {
"shape": [2, 1, 4],
"dtype": "float32",
"data": { "kind": "fillFloat32", "sinStep": 0.29, "cosStep": 0.17, "scale": 0.2 }
},
"pastStateT": {
"shape": [1, 2, 3],
"dtype": "float32",
"data": { "kind": "fillFloat32", "sinStep": 0.07, "cosStep": 0.21, "scale": 0.25 }
}
},
"outputs": {
"outputT": { "shape": [1, 2, 1], "dtype": "float32" },
"presentStateT": { "shape": [1, 2, 3], "dtype": "float32" }
}
},
{
"name": "scalar_f16_state_bias_silu_cast_boundary",
"attrs": { "activation": "silu" },
"inputs": {
"inputT": {
"shape": [1, 1, 3],
"dtype": "float16",
"data": { "kind": "values", "values": [1.001, -0.731, 0.287] }
},
"weightT": {
"shape": [1, 1, 3],
"dtype": "float16",
"data": { "kind": "values", "values": [0.619, -1.127, 0.443] }
},
"biasT": { "shape": [1], "dtype": "float16", "data": { "kind": "values", "values": [0.037] } },
"pastStateT": {
"shape": [1, 1, 2],
"dtype": "float16",
"data": { "kind": "values", "values": [-0.219, 0.887] }
}
},
"outputs": {
"outputT": { "shape": [1, 1, 3], "dtype": "float16" },
"presentStateT": { "shape": [1, 1, 2], "dtype": "float16" }
}
},
{
"name": "kernel_size_one",
"inputs": {
"inputT": {
"shape": [2, 2, 3],
"dtype": "float32",
"data": { "kind": "fillFloat32", "sinStep": 0.13, "cosStep": 0.19, "scale": 0.25 }
},
"weightT": {
"shape": [2, 1, 1],
"dtype": "float32",
"data": { "kind": "fillFloat32", "sinStep": 0.31, "cosStep": 0.09, "scale": 0.2 }
}
},
"outputs": {
"outputT": { "shape": [2, 2, 3], "dtype": "float32" },
"presentStateT": { "shape": [2, 2, 0], "dtype": "float32" }
}
},
{
"name": "input_shorter_than_state_zero_padding",
"inputs": {
"inputT": { "shape": [1, 1, 2], "dtype": "float32", "data": { "kind": "values", "values": [2.0, 3.0] } },
"weightT": {
"shape": [1, 1, 5],
"dtype": "float32",
"data": { "kind": "values", "values": [1.0, 1.0, 1.0, 1.0, 1.0] }
}
},
"outputs": {
"outputT": { "shape": [1, 1, 2], "dtype": "float32" },
"presentStateT": { "shape": [1, 1, 4], "dtype": "float32" }
}
},
{
"name": "zero_length_reemits_past_state",
"inputs": {
"inputT": { "shape": [1, 1, 0], "dtype": "float32", "data": { "kind": "values", "values": [] } },
"weightT": { "shape": [1, 1, 3], "dtype": "float32", "data": { "kind": "values", "values": [1.0, 1.0, 1.0] } },
"pastStateT": { "shape": [1, 1, 2], "dtype": "float32", "data": { "kind": "values", "values": [4.0, 5.0] } }
},
"outputs": {
"outputT": { "shape": [1, 1, 0], "dtype": "float32" },
"presentStateT": { "shape": [1, 1, 2], "dtype": "float32" }
}
},
{
"name": "vec4_zero_state_f16_silu",
"attrs": { "activation": "silu" },
"inputs": {
"inputT": {
"shape": [2, 3, 8],
"dtype": "float16",
"data": { "kind": "fillFloat32", "sinStep": 0.17, "cosStep": 0.23, "scale": 0.25 }
},
"weightT": {
"shape": [3, 1, 4],
"dtype": "float16",
"data": { "kind": "fillFloat32", "sinStep": 0.27, "cosStep": 0.11, "scale": 0.2 }
}
},
"outputs": {
"outputT": { "shape": [2, 3, 8], "dtype": "float16" },
"presentStateT": { "shape": [2, 3, 3], "dtype": "float16" }
}
},
{
"name": "vec4_bias_no_state_swish",
"attrs": { "activation": "swish" },
"inputs": {
"inputT": {
"shape": [1, 2, 8],
"dtype": "float32",
"data": { "kind": "fillFloat32", "sinStep": 0.21, "cosStep": 0.13, "scale": 0.25 }
},
"weightT": {
"shape": [2, 1, 3],
"dtype": "float32",
"data": { "kind": "fillFloat32", "sinStep": 0.09, "cosStep": 0.31, "scale": 0.2 }
},
"biasT": {
"shape": [2],
"dtype": "float32",
"data": { "kind": "fillFloat32", "sinStep": 0.33, "cosStep": 0.07, "scale": 0.1 }
}
},
"outputs": {
"outputT": { "shape": [1, 2, 8], "dtype": "float32" },
"presentStateT": { "shape": [1, 2, 2], "dtype": "float32" }
}
},
{
"name": "vec4_state_no_bias",
"inputs": {
"inputT": {
"shape": [1, 2, 4],
"dtype": "float32",
"data": { "kind": "fillFloat32", "sinStep": 0.15, "cosStep": 0.25, "scale": 0.25 }
},
"weightT": {
"shape": [2, 1, 2],
"dtype": "float32",
"data": { "kind": "fillFloat32", "sinStep": 0.35, "cosStep": 0.05, "scale": 0.2 }
},
"pastStateT": {
"shape": [1, 2, 1],
"dtype": "float32",
"data": { "kind": "fillFloat32", "sinStep": 0.11, "cosStep": 0.29, "scale": 0.25 }
}
},
"outputs": {
"outputT": { "shape": [1, 2, 4], "dtype": "float32" },
"presentStateT": { "shape": [1, 2, 1], "dtype": "float32" }
}
},
{
"name": "vec4_state_bias_silu",
"attrs": { "activation": "silu" },
"inputs": {
"inputT": {
"shape": [1, 2, 8],
"dtype": "float32",
"data": { "kind": "fillFloat32", "sinStep": 0.17, "cosStep": 0.27, "scale": 0.25 }
},
"weightT": {
"shape": [2, 1, 4],
"dtype": "float32",
"data": { "kind": "fillFloat32", "sinStep": 0.25, "cosStep": 0.13, "scale": 0.2 }
},
"biasT": {
"shape": [2],
"dtype": "float32",
"data": { "kind": "fillFloat32", "sinStep": 0.39, "cosStep": 0.05, "scale": 0.1 }
},
"pastStateT": {
"shape": [1, 2, 3],
"dtype": "float32",
"data": { "kind": "fillFloat32", "sinStep": 0.07, "cosStep": 0.33, "scale": 0.25 }
}
},
"outputs": {
"outputT": { "shape": [1, 2, 8], "dtype": "float32" },
"presentStateT": { "shape": [1, 2, 3], "dtype": "float32" }
}
},
{
"name": "tiled_zero_state",
"inputs": {
"inputT": {
"shape": [1, 1, 256],
"dtype": "float32",
"data": { "kind": "fillFloat32", "sinStep": 0.03, "cosStep": 0.05, "scale": 0.25 }
},
"weightT": {
"shape": [1, 1, 32],
"dtype": "float32",
"data": { "kind": "fillFloat32", "sinStep": 0.07, "cosStep": 0.09, "scale": 0.1 }
}
},
"outputs": {
"outputT": { "shape": [1, 1, 256], "dtype": "float32" },
"presentStateT": { "shape": [1, 1, 31], "dtype": "float32" }
}
},
{
"name": "tiled_bias_no_state_silu",
"attrs": { "activation": "silu" },
"inputs": {
"inputT": {
"shape": [1, 1, 256],
"dtype": "float32",
"data": { "kind": "fillFloat32", "sinStep": 0.04, "cosStep": 0.06, "scale": 0.25 }
},
"weightT": {
"shape": [1, 1, 32],
"dtype": "float32",
"data": { "kind": "fillFloat32", "sinStep": 0.08, "cosStep": 0.1, "scale": 0.1 }
},
"biasT": { "shape": [1], "dtype": "float32", "data": { "kind": "constant", "value": 0.05 } }
},
"outputs": {
"outputT": { "shape": [1, 1, 256], "dtype": "float32" },
"presentStateT": { "shape": [1, 1, 31], "dtype": "float32" }
}
},
{
"name": "tiled_state_no_bias",
"inputs": {
"inputT": {
"shape": [1, 1, 256],
"dtype": "float32",
"data": { "kind": "fillFloat32", "sinStep": 0.05, "cosStep": 0.07, "scale": 0.25 }
},
"weightT": {
"shape": [1, 1, 32],
"dtype": "float32",
"data": { "kind": "fillFloat32", "sinStep": 0.09, "cosStep": 0.11, "scale": 0.1 }
},
"pastStateT": {
"shape": [1, 1, 31],
"dtype": "float32",
"data": { "kind": "fillFloat32", "sinStep": 0.13, "cosStep": 0.17, "scale": 0.25 }
}
},
"outputs": {
"outputT": { "shape": [1, 1, 256], "dtype": "float32" },
"presentStateT": { "shape": [1, 1, 31], "dtype": "float32" }
}
},
{
"name": "tiled_state_bias_f16_swish",
"attrs": { "activation": "swish" },
"inputs": {
"inputT": {
"shape": [1, 1, 256],
"dtype": "float16",
"data": { "kind": "fillFloat32", "sinStep": 0.06, "cosStep": 0.08, "scale": 0.25 }
},
"weightT": {
"shape": [1, 1, 32],
"dtype": "float16",
"data": { "kind": "fillFloat32", "sinStep": 0.1, "cosStep": 0.12, "scale": 0.1 }
},
"biasT": { "shape": [1], "dtype": "float16", "data": { "kind": "constant", "value": -0.05 } },
"pastStateT": {
"shape": [1, 1, 31],
"dtype": "float16",
"data": { "kind": "fillFloat32", "sinStep": 0.14, "cosStep": 0.18, "scale": 0.25 }
}
},
"outputs": {
"outputT": { "shape": [1, 1, 256], "dtype": "float16" },
"presentStateT": { "shape": [1, 1, 31], "dtype": "float16" }
}
},
{
"name": "tiled_zero_state_unaligned_k35_weight_tile_pad",
"inputs": {
"inputT": {
"shape": [1, 1, 256],
"dtype": "float32",
"data": { "kind": "fillFloat32", "sinStep": 0.03, "cosStep": 0.05, "scale": 0.25 }
},
"weightT": {
"shape": [1, 1, 35],
"dtype": "float32",
"data": { "kind": "fillFloat32", "sinStep": 0.07, "cosStep": 0.09, "scale": 0.1 }
}
},
"outputs": {
"outputT": { "shape": [1, 1, 256], "dtype": "float32" },
"presentStateT": { "shape": [1, 1, 34], "dtype": "float32" }
},
"provenance": {
"notes": "Kernel length 3 mod 4. The shared tiled kernel consumes four taps per iteration, so this shape reaches it only through the zero-padded weight tile; ai.onnx carries its own copy of that gate, so it needs its own lock."
}
}
]
}