mattwang44 / LeNet-from-Scratch

Implementation of LeNet5 without any auto-differentiate tools or deep learning frameworks. Accuracy of 98.6% is achieved on MNIST dataset.
25 stars 9 forks source link

Question about normailization #1

Open AlgorithmicIntelligence opened 5 years ago

AlgorithmicIntelligence commented 5 years ago

The paper normalize range from -0.1 to 1.175, in order to make mean equal to 0, variance equal to 1. But I try both on your code and my code, variance is far from 1. Do you have any idea?

AlgorithmicIntelligence commented 5 years ago

Another question, how to get the template weights about RBF?

mattwang44 commented 5 years ago

The paper normalize range from -0.1 to 1.175, in order to make mean equal to 0, variance equal to 1. But I try both on your code and my code, variance is far from 1. Do you have any idea?

how do you calculate variance? The variance of a set containing number range from -0.1 to 1.175 should not be far from 1.

Another question, how to get the template weights about RBF?

I just hardcoded the ASCII set as weight by observing the figure on the top of paper (p.9)

AlgorithmicIntelligence commented 5 years ago

Thank you for your response. I just use np.average(.) and np.std(.) directly. For instance, in your code, np.average(train_image_normalized_pad) = 0.027 np.std(train_image_normalized_pad) = 0.3509 Is it the expectation of the original paper?