<p>In <a href="https://github.com/mlpack/mlpack/pull/686#discussion_r70260062">src/mlpack/methods/ne/tasks.hpp</a>:</p>
<pre style='color:#555'>&gt; +      double theta_dot = mlpack::math::Random(-1.5, 1.5);
&gt; +
&gt; +      for (ssize_t step=0; step&lt;num_step; ++step) {
&gt; +        // Convert input into range [0, 1]
&gt; +        std::vector&lt;double&gt; inputs = {(x + 2.4) / 4.8,
&gt; +                                      (x_dot + 0.75) / 1.5,  // ??
&gt; +                                      (theta + theta_limit) / 0.41,
&gt; +                                      (theta_dot + 1.0) / 2.0,
&gt; +                                      1};  // TODO: use arma::mat for input.
&gt; +        genome.Activate(inputs);
&gt; +        std::vector&lt;double&gt; output;
&gt; +        genome.Output(output);
&gt; +
&gt; +        double action = output[0];
&gt; +        if (output[0] &lt; 0.5) {
&gt; +          action = -1;
</pre>
<p>My the neat-python test uses:</p>

<p><code><br>
    if net_output &gt; 0.5:<br>
        force = FORCE_MAG<br>
    else:<br>
        force = -FORCE_MAG<br>
</code></p>

<p style="font-size:small;-webkit-text-size-adjust:none;color:#666;">&mdash;<br />You are receiving this because you are subscribed to this thread.<br />Reply to this email directly, <a href="https://github.com/mlpack/mlpack/pull/686/files/1fe7d730fd88cbaf7019e8936face4c6ddcb0577..ff45785b8669f82beb38ef5392f48bcdf5c83f6a#r70260062">view it on GitHub</a>, or <a href="https://github.com/notifications/unsubscribe/AJ4bFHHC8mX9g-xhoagTiE1GqEE6AcO9ks5qUkmsgaJpZM4IwJa6">mute the thread</a>.<img alt="" height="1" src="https://github.com/notifications/beacon/AJ4bFOIR4WhkxBDAfss8C8B51ErnzsXYks5qUkmsgaJpZM4IwJa6.gif" width="1" /></p>
<div itemscope itemtype="http://schema.org/EmailMessage">
<div itemprop="action" itemscope itemtype="http://schema.org/ViewAction">
  <link itemprop="url" href="https://github.com/mlpack/mlpack/pull/686/files/1fe7d730fd88cbaf7019e8936face4c6ddcb0577..ff45785b8669f82beb38ef5392f48bcdf5c83f6a#r70260062"></link>
  <meta itemprop="name" content="View Pull Request"></meta>
</div>
<meta itemprop="description" content="View this Pull Request on GitHub"></meta>
</div>