I am implementing myself a Neural Network with feedforward and backpropagation with gradient descent to understand better how things work.
After setting up the entire algorithm, I still have a huge doubt. When I initialise the weights, I do it so that each node of the network has its own weight initially assigned. I am doing this for every sample in the dataset, meaning that for each sample I initialise different weights. Is this correct, or should the initial weights be the same across all samples?
To clarify my question with an example: let's say I have a very simple network with just the input and output layer. The input has 2 nodes. The dataset has 2 observations. What I am doing now is that, for each of the observations, I initialise 2 weights and assign them to the input nodes, so that in the end I have 4 different weights. Should I initialise only 2 weights and assign them to their respective nodes in both the observations, so that both nodes will have the same weights value across all my observations?
What I am doing now:
-observation1
-node1:weight1
-node2:weight2
-observation2
-node1:weight3
-node2:weight4
What I wonder I should be doing instead:
-observation1
-node1:weight1
-node2:weight2
-observation2
-node1:weight1
-node2:weight2