Model description:
cnn1=Sequential()
cnn1.add(Conv2D(128,(2,300), activation = 'relu',input_shape = (maxLenofSent,300,1)))
cnn1.add(MaxPooling2D(1,3))
cnn1.add(Flatten())
cnn1.add(Dense(100, activation = 'relu'))
cnn2=Sequential()
cnn2.add(Conv2D(128,(2,300), activation = 'relu',input_shape = (maxLenofSent,300,1)))
cnn2.add(MaxPooling2D(1,3))
cnn2.add(Flatten())
cnn2.add(Dense(100, activation = 'relu'))
classifier2=Sequential()
classifier2.add(Merge([cnn1,cnn2], mode='concat'))
classifier2.add(Dense(70,activation='sigmoid'))
classifier2.add(Dropout(0.2))
classifier2.add(Dense(2,activation='tanh'))
sgd = SGD(lr = 0.01, momentum = 0.9, decay=1e-2, nesterov = False)
classifier2.compile(loss = 'categorical_crossentropy', optimizer = sgd, metrics = ['accuracy'])
How to save full model so that it can be used later for testing. Output of two cnn goes to ann and classify.