Hi, every one：
I’m defining a new layer inheriting from  Conv module. And when the data flows forward, there is error as ：
“RuntimeError: expected a Variable argument, but got NoneType".
The reason is that the bias==None,
if bias:
     self.bias = Parameter(torch.Tensor(out_channels))
     self.mask_bias = torch.ones(out_channels).cuda()
else:
     self.register_parameter('bias', None）

but the type of the forward function’s input  should be Variable. However, I find that the type of bias in the
function could be None? So how can I deal with it？