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/11/02 08:24:30 UTC

[GitHub] aravindhv10 commented on issue #13087: softmax in symbol api

aravindhv10 commented on issue #13087: softmax in symbol api
URL: https://github.com/apache/incubator-mxnet/issues/13087#issuecomment-435305296
 
 
   Hello,
   
        I managed to figure out something, please inform me if this is right or wrong:
   to get softmax of each data point (this is a 40 dimensional array) in a batch size of 256, I use softmax(axis=1) so this implemented as:
   
   auto Sm = Operator("softmax")
                               .SetParam("axis", 1)
                               .SetInput("data", Id)
                               .CreateSymbol("Sm");
   
                   auto Net = Operator("LinearRegressionOutput")
                               //.SetParam("ignore_label", -1)
                               .SetParam("grad_scale", 1)
                               //.SetParam("use_ignore", false)
                               //.SetParam("normalization", "null") /*batch,null,valid */
                               .SetInput("data", Sm)
                               .SetInput("label",target_label)
                               .CreateSymbol("Net");

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