Pytorch set parameters (weight and bias) of layers

I know that model->conv1_1->parameters()[0] represents the weights and model->conv1_1->parameters()[1] represents the bias for conv1_1. But I can’t set weights with:

torch::Tensor conv_wght = torch::zeros({64, 3, 3, 3},torch::TensorOptions().dtype(torch::kFloat32).device(torch::kCUDA, 0));
model->conv1_1->parameters()[0] = conv_wght;

Anyone can give me a clue?