Skip to content

Instantly share code, notes, and snippets.

@chricke

chricke/build_nn.py

Created Mar 26, 2019
Embed
What would you like to do?
Build Neural Net
def build_nn(cell, rnn_size, input_data, vocab_size, embed_dim):
embeddings = get_embed(input_data, vocab_size, embed_dim)
inputs, final_state = build_rnn(cell, embeddings)
logits = tf.contrib.layers.fully_connected(inputs=inputs, num_outputs=vocab_size, activation_fn=None)
return logits, final_state
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.