4 types derived from Layer
Microsoft.ML.TorchSharp (4)
NasBert\Modules\Layers\EncConvLayer.cs (1)
14
internal sealed class EncConvLayer :
Layer
NasBert\Modules\Layers\FeedForwardLayer.cs (1)
14
internal sealed class FeedForwardLayer :
Layer
NasBert\Modules\Layers\IdentityLayer.cs (1)
12
internal sealed class IdentityLayer :
Layer
NasBert\Modules\Layers\SelfAttentionLayer.cs (1)
13
internal sealed class SelfAttentionLayer :
Layer
11 references to Layer
Microsoft.ML.TorchSharp (11)
NasBert\Modules\SearchSpace.cs (1)
44
public static
Layer
GetLayer(
NasBert\Modules\TransformerCell.cs (10)
38
private readonly ModuleList<
Layer
> Operations;
56
Operations = new ModuleList<
Layer
>(operations);
65
return (Operations[arch] as
Layer
)!.forward(x, new Dictionary<string, object>
67
{
Layer
.AttentionMaskKey, selfAttentionMask},
68
{
Layer
.PaddingMaskKey, selfAttentionPaddingMask},
74
foreach (
var
operation in Operations)
76
(operation as
Layer
)!.CloseLayerNormTraining();
105
private readonly
Layer
Operation;
132
{
Layer
.AttentionMaskKey, selfAttentionMask},
133
{
Layer
.PaddingMaskKey, selfAttentionPaddingMask},