import torch
X1 = torch.tensor([[0,0],[1,0],[0,1,],[1,1]] ,dtype = torch.float32)
torch.random.manual_seed(420)
output = torch.nn.Linear(2,1)
zhat = output(X1)
print(zhat)
print(output.weight)
print("*"*50)
print(output.bias)
import torch
X1 = torch.tensor([[0,0],[1,0],[0,1,],[1,1]] ,dtype = torch.float32)
torch.random.manual_seed(420)
output = torch.nn.Linear(2,1)
zhat = output(X1)
print(zhat)
print(output.weight)
print("*"*50)
print(output.bias)