Skip to main content

Blog

Learn About Our Meetup

5000+ Members

MEETUPS

LEARN, CONNECT, SHARE

Join our meetup, learn, connect, share, and get to know your Toronto AI community. 

JOB POSTINGS

INDEED POSTINGS

Browse through the latest deep learning, ai, machine learning postings from Indeed for the GTA.

CONTACT

CONNECT WITH US

Are you looking to sponsor space, be a speaker, or volunteer, feel free to give us a shout.

[Discussion] CNN Binary Classifier returning same accuracy in several epochs….

….what do I do?

I have 2000 images each of classes “Mobile” and “Cake”, with a validation split of 0.3. This is the code of the model..

—————————————————————————————-

model = keras.models.Sequential()

model.add(keras.layers.Conv2D(32, (3, 3), activation=’relu’, input_shape=(150, 150, 3)))
model.add(keras.layers.MaxPooling2D((2, 2)))

model.add(keras.layers.Conv2D(64, (3, 3), activation=’relu’))
model.add(keras.layers.MaxPooling2D((2, 2)))

model.add(keras.layers.Conv2D(128, (3, 3), activation=’relu’))
model.add(keras.layers.MaxPooling2D((2, 2)))
model.add(keras.layers.Conv2D(128, (3, 3), activation=’relu’))
model.add(keras.layers.MaxPooling2D((2, 2)))
model.add(keras.layers.Flatten())
model.add(keras.layers.Dropout(0.5))
model.add(keras.layers.Dense(512, activation=’relu’))
model.add(keras.layers.Dense(1, activation=’sigmoid’))
model.compile(loss=’binary_crossentropy’,optimizer=keras.optimizers.RMSprop(lr=((1e-4)/10)),metrics=[‘acc’])
history=model.fit(Xnew,Ynew,1,10,validation_split=0.3)

—————————————————————————————-

Can anyone help me out? The accuracy gets stuck on 0.5280 right from the second epoch. I am a beginner in CNN, and would appreciate some guidance with this. Thanks!

submitted by /u/kirasama16997
[link] [comments]