ShichengChen commented on a change in pull request #416: singa-onnx
URL: https://github.com/apache/incubator-singa/pull/416#discussion_r264080797
##########
File path: examples/onnx/cnnonnx2singa.py
##########
@@ -105,19 +105,13 @@ def accuracy(pred, target):
model = onnx.load('cnn.onnx')
- rep = sonnx.BackendRep(model,dev)
- #####backend run multiple times
+ rep = sonnx.prepare(model, dev)
print('finish init')
autograd.training = True
# training process
for epoch in range(1):
inputs = tensor.Tensor(device=dev, data=x_train[0:100],
stores_grad=False)
Review comment:
if input order here is the same as input order in to_onnx_model, default
name system works
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
With regards,
Apache Git Services