horn-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Edward J. Yoon (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (HORN-23) Add softmax function
Date Mon, 16 May 2016 02:38:12 GMT

    [ https://issues.apache.org/jira/browse/HORN-23?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15284082#comment-15284082
] 

Edward J. Yoon commented on HORN-23:
------------------------------------

Basically output needs to be divided by the sum of exponential of the whole output vector.
So, it's impossible to define clearly within two forward/backward methods of current neuron-centric
programming model. 

There're two options. 1) calculate sum as below
{code}
    if (squashingFunction.getFunctionName().equalsIgnoreCase(
        SoftMax.class.getSimpleName())) {
      // divide by the sum of exponential of the whole vector
      vec = vec.divide(vec.sum());
      // LOG.info("softmaxed output: " + Arrays.toString(vec.toArray()));
    }
{code}

2) add more APIs for handling intermediate output.


> Add softmax function
> --------------------
>
>                 Key: HORN-23
>                 URL: https://issues.apache.org/jira/browse/HORN-23
>             Project: Apache Horn
>          Issue Type: New Feature
>            Reporter: Edward J. Yoon
>
> https://en.wikipedia.org/wiki/Softmax_function



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Mime
View raw message