class ModelOne(nn.Module):
  def __init__(self):
    super().__init__()
    self.weights = nn.Parameter(torch.randn(300, 10))
    self.bias = nn.Parameter(torch.zeros(10))
  def forward(self, x):
    return x @ self.weights + self.bias

class ModelTwo(nn.Module):
  def __init__(self):
    super().__init__()
    self.linear = nn.Linear(300, 10)
    
  def forward(self, x):
    return self.linear(x)

if so, then why does
mo = ModelOne()
[len(param) for param in mo.parameters()]

give
[300, 10]
while
mt = ModelTwo()
[len(param) for param in mt.parameters()]

give
[10, 10]