I think there are a few issues here. You probably want to do random = torch.tensor(random).double() rather than random = torch.tensor(random).double. However, by default the model is in single precision so the convolution layer will expect a float tensor so you probably want random = torch.tensor(random).float().
Additionally, the in_channels parameter for the second conv layer is incorrect. It needs to match the number of output channels to the first layer so the second layer should probably be nn.Conv2d(in_channels=out_channels, out_channels=out_channels, kernel_size=3),#, padding=1, stride=1, bias=False),.