solved bugs at matrix and convolutional NNs