Created
February 9, 2018 07:43
-
-
Save himangSharatun/3db4de1139597ce14bfc019bc85f507a to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# define baseline model | |
def baseline_model(): | |
# create model | |
model = Sequential() | |
model.add(Dense(5000, input_shape=(len(bow[0]),), activation='relu')) | |
model.add(Dropout(0.2)) | |
model.add(Dense(len(dummy_y[0]), activation='softmax')) | |
# Compile model | |
model.summary() | |
model.compile(loss='categorical_crossentropy', optimizer='adam', metrics=['accuracy']) | |
return model |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment