title: How do you apply Simple Gradient Descent algorithm from any library in a real application?
body: <p>I've looked at the proposed questions that may have my answer, and I don't think this is a duplicate. If it is, it's because I need something even more basic so I speak the language. I'm willing to take downvotes/lose rep to figure this out, if someone can point me at the right material. I may even be in the wrong forum.</p>
  
  <p>I'm an experienced programmer, but a <strong>non-mathematician</strong>. I am so lost that I don't even know how to phrase this question.</p>
  
  <p>I'm trying to implement a machine learning component in an application, and I can see the rough outline of what I need to do, but the library manuals are all written in greek. I've got that "alpha" is the learning rate, and "theta" is a matrix of floating point numbers (aka neural network).</p>
  
  <p>I've been reviewing Andrew Ng's stanford lectures, and they have helped me to understand that the final application of the algorithm will entail a Visitor to apply the neural network matrix (Theta) to "stuff". The math is the same whether you're trying to extrapolate new feature sets or producing an output. Yay!</p>
  
  <p>I can see how to componentize a learning engine class once it is implemented (why hasn't someone else done it?), But I don't understand how to implement the stuff inside the componentized envelope. Part of the problem is that the libraries and examples (Apache Commons Math, TensorFlow, etc.) all assume that you are a mathematician first, so they speak the language of mathematicians rather than programmers.</p>
  
  <p>Can someone explain without using words like theta, derivative, LUDecomposition, Eigen, or a stream of alphabet soup, exactly how to use the libraries once you have the inputs laid out nicely?</p>
  
  <pre><code>// The final code should look something like this, I think
  public void train () {
  
      // do something involving alphabet soup and theta here
      // might be "Stochastic Gradient Descent?" 
  
      // new model = stochasticGradientDescent(model)
      // hypothesis = applyModel (newModel)
      // difference = (hypothesis - actual)**2
  
  }
  </code></pre>