title: Dlib - How do I use the loss_mean_squared_multioutput training label type?
body: <p>ML and DLib beginner here, so please excuse me if the question meanders a little. </p>
  
  <p>I've been looking at some of the example projects in the Dlib documentation, and roughly understand the example found here:</p>
  
  <p><a href="http://dlib.net/dnn_introduction_ex.cpp.html" rel="nofollow noreferrer">http://dlib.net/dnn_introduction_ex.cpp.html</a></p>
  
  <p>The example looks straightforward, enough for me to grasp how to compile a working example.</p>
  
  <p>What I would like to do however, is attempt to use a <code>loss_mean_squared_multioutput</code> layer in the place of the <code>loss_multiclass_log</code> found in the example, as I think it will be a better fit for my model.</p>
  
  <p>To give a brief, high level description of the problem I have, it's a regression problem with 5 outputs. On training, I would like to feed in an 'image', and train the network on how valuable any one of those 5 outputs might be, in relation to that input.</p>
  
  <p>So for example, if I feed in (pseudocode):</p>
  
  <pre><code>input = [1, 0, 0, 0, 0, 0, 0, 0]
  </code></pre>
  
  <p>I would like the output to produce something like this</p>
  
  <pre><code>output = [0, 0.1, 0, 0.5, -1]
  </code></pre>
  
  <p>With that in mind, if the labels for <code>loss_mean_squared_multioutput</code> are <code>matrix&lt;float&gt;</code>, is this roughly how I should go about using it?:</p>
  
  <pre><code>loss_multiclass_log&lt;fc&lt;5...
  trainer.train([list of matrix&lt;float&gt;], [list of matrix&lt;float 1, 5&gt; = 0, 0.1, 0, 0.5, -1]);
  </code></pre>
  
  <p>Also, if this all seems totally misguided and nonsensical to you after reading through, by all means, please correct me. I would appreciate the guidance.</p>