Skip to content

Instantly share code, notes, and snippets.

View mikechen66's full-sized avatar

mikechen66

View GitHub Profile
@mikechen66
mikechen66 / Standard LSTM Snippet
Last active January 9, 2020 11:41
This gist is a snippet of the standard LSTM code. It is hard to get update LSTM snippets in the community. So I provide it for the reference in building a complete project.
# standard_lstm.py
import tensorflow as tf
from tensorflow.contrib import rnn
from tensorflow.contrib import legacy_seq2seq
from tensorflow.python.framework import ops
from tensorflow.python.ops import math_ops
from tensorflow.python.ops.math_ops import sigmoid
from tensorflow.python.ops.math_ops import tanh