CryptoNets icon indicating copy to clipboard operation
CryptoNets copied to clipboard

Cryptonet MNIST training script

Open essa2307 opened this issue 5 years ago • 1 comments

Hello, I am trying to train the model from the original cryptonet paper and I am facing issues in even making the model in keras. For example: For the first 3 layers: model = Sequential() model.add(Conv2D(filters=5, kernel_size=(5, 5),strides=(2,2),input_shape=(28,28,1), padding = 'same')) model.add(Activation(square)) model.add(AveragePooling2D(pool_size=(2,2)))

And the output shape:


Layer (type) Output Shape Param #

conv2d_8 (Conv2D) (None, 14, 14, 5) 130


activation_13 (Activation) (None, 14, 14, 5) 0


average_pooling2d_7 (Average (None, 7, 7, 5) 0


Which does not match the paper. Also could you please tell me the optimizer you used? Because I am always getting 'nan' loss when I have a square activation layer involved

essa2307 avatar Mar 11 '20 20:03 essa2307

We used an internal tool for training the MNIST model. We do have, in the wiki pages explanations on how train a model on the CIFAR10 data

ranigb avatar Apr 04 '20 20:04 ranigb