Commit 49714e23 authored by Yasith Nawanjana's avatar Yasith Nawanjana

Update main.py

parent 7af92fe3
...@@ -15,16 +15,21 @@ def load_brain_tumor_type_model(): ...@@ -15,16 +15,21 @@ def load_brain_tumor_type_model():
model = Sequential() model = Sequential()
model.add(Conv2D(256, (3, 3), input_shape=(50, 50, 1))) model.add(Conv2D(512, (5, 5), input_shape=(50, 50, 1)))
model.add(Activation('relu')) model.add(Activation('relu'))
model.add(MaxPooling2D(pool_size=(2,2))) model.add(MaxPooling2D(pool_size=(2, 2)))
#The first CNN layer followed by Relu and MaxPooling layers #The first CNN layer followed by Relu and MaxPooling layers
model.add(Conv2D(128, (3, 3))) model.add(Conv2D(256, (3, 3)))
model.add(Activation('relu')) model.add(Activation('relu'))
model.add(MaxPooling2D(pool_size=(2,2))) model.add(MaxPooling2D(pool_size=(2, 2)))
#The second convolution layer followed by Relu and MaxPooling layers #The second convolution layer followed by Relu and MaxPooling layers
model.add(Conv2D(128, (3, 3)))
model.add(Activation('relu'))
model.add(MaxPooling2D(pool_size=(2, 2)))
#The third convolution layer followed by Relu and MaxPooling layers
model.add(Flatten()) model.add(Flatten())
model.add(Dropout(0.5)) model.add(Dropout(0.5))
#Flatten layer to stack the output convolutions from second convolution layer #Flatten layer to stack the output convolutions from second convolution layer
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment