def __init__(self, n_inputs, n_neurons, biases=False, init_func="_uniform()", dtype=np.float32): self.weights = Tensor(_uniform(n_inputs, n_neurons, dtype=dtype))
def zeros(*shape, dtype=np.float32): return Tensor(np.zeros(shape, dtype=dtype))
def empty(*shape, dtype=np.float32): return Tensor(np.empty(shape, dtype=dtype))
def sample(*shape, dtype=np.float32): return Tensor(np.random.sample(shape).astype(dtype))
def rand(*shape, dtype=np.float32): return Tensor(np.random.rand(shape).astype(dtype))
def eye(*shape, dtype=np.float32): return Tensor(np.eye(shape).astype(dtype))
def ones(*shape, dtype=np.float32): return Tensor(np.ones(shape, dtype=dtype))