Jack6680 commented on issue #19808:
URL: 
https://github.com/apache/incubator-mxnet/issues/19808#issuecomment-848668068


   Good afternoon!
   I also managed to convert resnest50 to onnx with this script
   ```
   from gluoncv import model_zoo
   import numpy as np
   import mxnet as mx
   model_name = 'resnest50'
   resnet50 = model_zoo.get_model(model_name, pretrained=True)
   print(model_name+' downloaded')
   resnet50.hybridize()
   print(model_name+' hybridized')
   input_shape=(1,3,224,224)
   data_array = np.random.uniform(0, 255, size=input_shape).astype("float32")
   mx_data = mx.nd.array(data_array)
   resnet50(mx_data)
   resnet50.export(model_name)
   print(model_name+' exported')
   from mxnet.contrib import onnx as onnx_mxnet
   onnx_file='./tp.onnx'
   params = './'+model_name+'-0000.params'
   sym='./'+model_name+'-symbol.json'
   onnx_mxnet.export_model(sym, params, [input_shape], np.float32, onnx_file)
   print('onnx export done')
   ```
   But I can't convert back from onnx to mxnet. Example
   ```
   import mxnet as mx
   import mxnet.contrib.onnx as onnx_mxnet
   sym, arg, aux = onnx_mxnet.import_model('./tp.onnx')
   
   ```
   ---------------------------------------------------------------------------
   `
   NotImplementedError: Operator ScatterND not implemented.`
   
   


-- 
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]



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to