pytorch2caffe
pytorch2caffe copied to clipboard
bias=False in nn.Linear error
I've traced down this error:
in add_layer
inner_product_param['num_output'] = func.next_functions[0][0].variable.size(0)
AttributeError: 'NoneType' object has no attribute 'variable'
to the use of bias=False for a nn.Linear layer in Pytorch. Note that this parameter for nn.Conv2d works fine. Any idea for a quick fix or do I have to do surgery on my Pytorch pretrained model and add some zero biases?