Created
March 2, 2019 08:16
-
-
Save farizrahman4u/bc06eb9471bd42153dba0dfa4c65098d 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
from keras.layers import * | |
from keras.models import * | |
from utils import max_len, max_words | |
def get_model(): | |
model = Sequential() | |
model.add(Embedding(max_words, 128)) | |
model.add(GRU(128)) | |
model.add(Dense(1, activation='sigmoid')) | |
model.compile(loss='binary_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