You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@mxnet.apache.org by GitBox <gi...@apache.org> on 2018/05/21 02:40:18 UTC

[GitHub] brillwang opened a new issue #11008: Support Sparse OP in C predict API

brillwang opened a new issue #11008: Support Sparse OP in C predict API
URL: https://github.com/apache/incubator-mxnet/issues/11008
 
 
   For now (version 1.2.0), The C predict api cannot support sparse op and storage type.
   `csr_data = mx.symbol.Variable("data", stype='csr')
   label = mx.symbol.Variable("softmax_label")
   embed_weight = mx.symbol.Variable('embed_0_weight', stype='row_sparse', shape=(3000020, 64))    
   mult = mx.sym.sparse.dot(csr_data, embed_weight)
   fc1 = mx.symbol.FullyConnected(data=mult, num_hidden=128)
   act1 = mx.symbol.tanh(data=fc1)
   fc7 = mx.symbol.FullyConnected(data=act1, num_hidden=2)
   out = mx.symbol.SoftmaxOutput(data=fc7, label=label, name='softmax')`
   If we create a model like this, c predict api cannot work well, it will trans all input and model to dense.
   MXPredCreate and MXPredSetInput is not enough for this senario.
   
   @eric-haibin-lin 
   

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services