MCPcopy Create free account
hub / github.com/RightNow-AI/autokernel / forward

Method forward

models/gpt2.py:81–84  ·  view source on GitHub ↗
(self, x: torch.Tensor)

Source from the content-addressed store, hash-verified

79 self.mlp = MLP(n_embd, dropout)
80
81 def forward(self, x: torch.Tensor) -> torch.Tensor:
82 x = x + self.attn(self.ln_1(x))
83 x = x + self.mlp(self.ln_2(x))
84 return x
85
86
87class GPT2(nn.Module):

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected