title: Minimize a matrix loss
body: <p>I have a matrix optimization problem similar to a neural network where, when &quot;training&quot;, I only receive the matrix, the actual output value, and the predicted output value.</p>
  <p>For example, at the end of each iteration I receive:</p>
  <pre><code>Matrix = [[12,34,56], [12,34,56]] 
  Output = [1,2,3]
  Actual = [3,2,1]
  </code></pre>
  <p>How can I optimize this in a better way than randomized guesses?</p>
  <p>I've thought of methods like gradient descent and neural nets but they don't seem to quite fit.</p>
  <p>Note: I am using python.</p>