You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Traceback (most recent call last):
File "/mnt/hgfs/vmshare/myssd/to_onnx.py", line 17, in
torch.onnx.export(net, dummy_input, "myssd.onnx")
File "/home/ballzb/.local/lib/python3.6/site-packages/torch/onnx/init.py", line 148, in export
strip_doc_string, dynamic_axes, keep_initializers_as_inputs)
File "/home/ballzb/.local/lib/python3.6/site-packages/torch/onnx/utils.py", line 66, in export
dynamic_axes=dynamic_axes, keep_initializers_as_inputs=keep_initializers_as_inputs)
File "/home/ballzb/.local/lib/python3.6/site-packages/torch/onnx/utils.py", line 416, in _export
fixed_batch_size=fixed_batch_size)
File "/home/ballzb/.local/lib/python3.6/site-packages/torch/onnx/utils.py", line 279, in _model_to_graph
graph, torch_out = _trace_and_get_graph_from_model(model, args, training)
File "/home/ballzb/.local/lib/python3.6/site-packages/torch/onnx/utils.py", line 236, in _trace_and_get_graph_from_model
trace_graph, torch_out, inputs_states = torch.jit._get_trace_graph(model, args, _force_outplace=True, _return_inputs_states=True)
File "/home/ballzb/.local/lib/python3.6/site-packages/torch/jit/init.py", line 277, in _get_trace_graph
outs = ONNXTracedModule(f, _force_outplace, return_inputs, _return_inputs_states)(*args, **kwargs)
File "/home/ballzb/.local/lib/python3.6/site-packages/torch/nn/modules/module.py", line 532, in call
result = self.forward(*input, **kwargs)
File "/home/ballzb/.local/lib/python3.6/site-packages/torch/jit/init.py", line 360, in forward
self._force_outplace,
File "/home/ballzb/.local/lib/python3.6/site-packages/torch/jit/init.py", line 347, in wrapper
outs.append(self.inner(*trace_inputs))
File "/home/ballzb/.local/lib/python3.6/site-packages/torch/nn/modules/module.py", line 530, in call
result = self._slow_forward(*input, **kwargs)
File "/home/ballzb/.local/lib/python3.6/site-packages/torch/nn/modules/module.py", line 516, in slow_forward
result = self.forward(*input, **kwargs)
File "/mnt/hgfs/vmshare/myssd/ssd_mobilenetv2.py", line 128, in forward
self.priors.type(type(x.data)) # default boxes
File "/mnt/hgfs/vmshare/myssd/ssd_mobilenetv2.py", line 172, in my_detect
ids, count = nms(boxes, scores, nms_thresh, top_k)
File "/mnt/hgfs/vmshare/myssd/layers/box_utils.py", line 194, in nms
keep = scores.new(scores.size(0)).zero().long()
TypeError: expected Float (got Long)
The text was updated successfully, but these errors were encountered:
Traceback (most recent call last):
File "/mnt/hgfs/vmshare/myssd/to_onnx.py", line 17, in
torch.onnx.export(net, dummy_input, "myssd.onnx")
File "/home/ballzb/.local/lib/python3.6/site-packages/torch/onnx/init.py", line 148, in export
strip_doc_string, dynamic_axes, keep_initializers_as_inputs)
File "/home/ballzb/.local/lib/python3.6/site-packages/torch/onnx/utils.py", line 66, in export
dynamic_axes=dynamic_axes, keep_initializers_as_inputs=keep_initializers_as_inputs)
File "/home/ballzb/.local/lib/python3.6/site-packages/torch/onnx/utils.py", line 416, in _export
fixed_batch_size=fixed_batch_size)
File "/home/ballzb/.local/lib/python3.6/site-packages/torch/onnx/utils.py", line 279, in _model_to_graph
graph, torch_out = _trace_and_get_graph_from_model(model, args, training)
File "/home/ballzb/.local/lib/python3.6/site-packages/torch/onnx/utils.py", line 236, in _trace_and_get_graph_from_model
trace_graph, torch_out, inputs_states = torch.jit._get_trace_graph(model, args, _force_outplace=True, _return_inputs_states=True)
File "/home/ballzb/.local/lib/python3.6/site-packages/torch/jit/init.py", line 277, in _get_trace_graph
outs = ONNXTracedModule(f, _force_outplace, return_inputs, _return_inputs_states)(*args, **kwargs)
File "/home/ballzb/.local/lib/python3.6/site-packages/torch/nn/modules/module.py", line 532, in call
result = self.forward(*input, **kwargs)
File "/home/ballzb/.local/lib/python3.6/site-packages/torch/jit/init.py", line 360, in forward
self._force_outplace,
File "/home/ballzb/.local/lib/python3.6/site-packages/torch/jit/init.py", line 347, in wrapper
outs.append(self.inner(*trace_inputs))
File "/home/ballzb/.local/lib/python3.6/site-packages/torch/nn/modules/module.py", line 530, in call
result = self._slow_forward(*input, **kwargs)
File "/home/ballzb/.local/lib/python3.6/site-packages/torch/nn/modules/module.py", line 516, in slow_forward
result = self.forward(*input, **kwargs)
File "/mnt/hgfs/vmshare/myssd/ssd_mobilenetv2.py", line 128, in forward
self.priors.type(type(x.data)) # default boxes
File "/mnt/hgfs/vmshare/myssd/ssd_mobilenetv2.py", line 172, in my_detect
ids, count = nms(boxes, scores, nms_thresh, top_k)
File "/mnt/hgfs/vmshare/myssd/layers/box_utils.py", line 194, in nms
keep = scores.new(scores.size(0)).zero().long()
TypeError: expected Float (got Long)
The text was updated successfully, but these errors were encountered: