hahnyuan / nn_tools

Neural Network Tools: Converter and Analyzer. For caffe, pytorch, draknet and so on.
MIT License
355 stars 63 forks source link

_avg_pool2d() 参数个数错误 #26

Open alixiu opened 3 years ago

alixiu commented 3 years ago

`Traceback (most recent call last):

File "../nasnet-pytorch/pytorch_load.py", line 283, in pytorch_to_caffe.trans_net(model, dummy_input, name) File "/home/xiu/caffe-models-collection/nn_tools/pytorch_to_caffe.py", line 862, in trans_net out = net.forward(input_var) File "/home/xiu/caffe-models-collection/nasnet-pytorch/nasnet/nasnet.py", line 105, in forward x = self.features(x) File "/home/xiu/caffe-models-collection/nasnet-pytorch/nasnet/nasnet.py", line 77, in features x_stem_0 = self.cell_stem_0(x_conv0) File "/home/xiu/anaconda3/lib/python3.7/site-packages/torch/nn/modules/module.py", line 541, in call result = self.forward(*input, kwargs) File "/home/xiu/caffe-models-collection/nasnet-pytorch/nasnet/layers.py", line 92, in forward return ReductionCellBranchCombine(self, x1, x) File "/home/xiu/caffe-models-collection/nasnet-pytorch/nasnet/layers.py", line 51, in ReductionCellBranchCombine x_comb_iter_2_left = cell.comb_iter_2_left(x_left) File "/home/xiu/anaconda3/lib/python3.7/site-packages/torch/nn/modules/module.py", line 541, in call result = self.forward(*input, *kwargs) File "/home/xiu/anaconda3/lib/python3.7/site-packages/torch/nn/modules/pooling.py", line 554, in forward self.padding, self.ceil_mode, self.count_include_pad, self.divisor_override) File "/home/xiu/caffe-models-collection/nn_tools/pytorch_to_caffe.py", line 123, in call out=self.obj(self.raw,args,kwargs) TypeError: _avg_pool2d() takes from 3 to 7 positional arguments but 8 were given`

请问这个错误是什么原因造成的