struct Net : torch::nn::Module {
	Net(int32_t numIn, int32_t numOut, int32_t numHid) {
		weightsA = register_parameter("input", torch::rand({numIn, numHid}))*0.013;
		weightsB = register_parameter("output", torch::rand({numHid, numOut}))*0.013;
	}
	torch::Tensor forward(torch::Tensor input) {
		torch::Tensor hidden_layer, output_layer;
		hidden_layer = (torch::mm(input, weightsA));
		output_layer = (torch::mm(hidden_layer, weightsB));
		return output_layer;
	}
	torch::Tensor weightsA, weightsB;
};

I have a simple module with parameters, is there an easy way to add a bias node in the hidden layer (preferably without doing some computationally expensive operation like memcopy)
Note: you can provide python code if you are uncomfortable with c++ i should be able to translate it