davidsonic / Interpretable_CNNs_via_Feedforward_Design

Official Implementation of Interpretable Convolutional Neural Networks via Feedforward Design Arxiv: https://arxiv.org/abs/1810.02786
11 stars 8 forks source link

The orders of mean removal #6

Open andrewcheng2016 opened 1 year ago

andrewcheng2016 commented 1 year ago

In MNIST/saab.py (154-157), you first remove the sample patches' feature means, then the patch means. However, the order is reversed in CIFAR10/saab.py (109-113). Won't it affect the result?

Also, I am curious why in CIFAR10/saab.py (198 & 252), you perform the projection using the sample patches but not the patches that have removed the mean while you perform

_transformed=np.matmul(sample_patchescentered, np.transpose(kernels))

in MNIST/saab.py.