title: Proper way to implement biases in Neural Networks
body: <p>I can make a neural network, I just need a clarification on bias implementation. Which way is better: Implement the Bias matrices <code>B1, B2, .. Bn</code> for each layer in their own, seperate matrix from the weight matrix, <strong>or</strong>, include the biases in the weight matrix by adding a <code>1</code> to the previous layer output (input for this layer). In images, I am asking whether this implementation:</p>
  
  <p><a href="https://i.stack.imgur.com/xwlAI.png" rel="noreferrer"><img src="https://i.stack.imgur.com/xwlAI.png" alt="enter image description here"></a></p>
  
  <p>Or this implementation: </p>
  
  <p><a href="https://i.stack.imgur.com/rmYf1.jpg" rel="noreferrer"><img src="https://i.stack.imgur.com/rmYf1.jpg" alt="enter image description here"></a></p>
  
  <p>Is the best. Thank you</p>