Fix problem where num_labels was harcoded

num_labels is really a parameter to the function so it shouldn't be
hard-coded as a number, I discovered this when running the
checkNNGradient script. There would be an error being brought up calling
for me to check the dimension of my matrices.