<p>Let's put it in <code>methods/sparse_autoencoder</code> for now; it can be moved later.  The idea of a global function sounds good, but please consider naming <code>w1()</code> something more descriptive, like <code>Parameters()</code> (since the internal member is named <code>parameters</code>).</p>

<p>Why do you transpose in the input to <code>MaximalInput()</code>?  If that could be avoided, the function could be a little bit faster (possibly).</p>

<p style="font-size:small;-webkit-text-size-adjust:none;color:#666;">&mdash;<br>Reply to this email directly or <a href="https://github.com/mlpack/mlpack/issues/452#issuecomment-151157007">view it on GitHub</a>.<img alt="" height="1" src="https://github.com/notifications/beacon/AJ4bFH5l1mLdn0Nt4JXTDOLCaGv2xB6Bks5o_jDmgaJpZM4GA0ZB.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/issues/452#issuecomment-151157007"></link>
  <meta itemprop="name" content="View Issue"></meta>
</div>
<meta itemprop="description" content="View this Issue on GitHub"></meta>
</div>