Skip to content

Instantly share code, notes, and snippets.

@sayakpaul
Created October 30, 2022 14:06
Show Gist options
  • Save sayakpaul/025741a80db123bd42453543fa7e3ea3 to your computer and use it in GitHub Desktop.
Save sayakpaul/025741a80db123bd42453543fa7e3ea3 to your computer and use it in GitHub Desktop.
import tensorflow as tf
from tensorflow.keras import layers
model = tf.keras.Sequential([
layers.Conv2D(32, kernel_size=(3, 3),activation='relu',
layers.MaxPool2D((2, 2)),
layers.Conv2D(64,kernel_size=(3, 3), activation='relu'),
layers.MaxPool2D((2, 2)),
layers.Dropout(0.2),
layers.GlobalAveragePooling2D(),
layers.Dense(128, activation='relu')
layers.Dense(10, activation = "softmax")
])
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment