Class SingleHeadAttention
Represents the fused multihead attention layer based on the PyTorch implementation. This layer computes attention outputs given input tensors.
Inherited Members
Namespace: Unity.Sentis.Layers
Assembly: solution.dll
Syntax
[Serializable]
public class SingleHeadAttention : Layer
Constructors
Name | Description |
---|---|
SingleHeadAttention(string, string, string, string, string, string, string, string, string, string, float) | Creates a fused |
Fields
Name | Description |
---|---|
scaling_factor | The scaling factor for scaling the query. |
Methods
Name | Description |
---|---|
Execute(Tensor[], ExecutionContext) | Executes the layer using the operations and variables from the If the layer has more than one output, output tensors are saved to variables. |