Skip to content

Instantly share code, notes, and snippets.

@pranv
pranv / lstm.py
Last active July 6, 2017 11:48
An Efficient, Batched, Stateful LSTM layer in Numpy
import numpy as np
from utils import orthogonal, tanh, sigmoid, dtanh, dsigmoid
class LSTM(object):
"""Long Short Term Memory Unit
Parameters
----------