예제 #1
0
파일: test_rnn.py 프로젝트: makarl/breze
def test_fd_srnn_predict():
    X = np.random.standard_normal((10, 5, 2)).astype(theano.config.floatX)
    rnn = SupervisedFastDropoutRnn(2, [10],
                                   3,
                                   hidden_transfer='rectifier',
                                   max_iter=10)
    print rnn.exprs
    rnn.predict(X)
예제 #2
0
파일: test_rnn.py 프로젝트: osdf/breze
def test_fd_srnn_predict():
    X = np.random.standard_normal((10, 5, 2)).astype(theano.config.floatX)
    X, = theano_floatx(X)
    rnn = SupervisedFastDropoutRnn(2, [10], 3, hidden_transfers=['rectifier'], max_iter=10)
    rnn.predict(X)

    rnn = SupervisedFastDropoutRnn(
        2, [10, 20], 3, hidden_transfers=['rectifier', 'tanh'],
        skip_to_out=True, max_iter=10)
    rnn.predict(X)
예제 #3
0
파일: test_rnn.py 프로젝트: gabobert/breze
def test_fd_srnn_predict():
    X = np.random.standard_normal((10, 5, 2)).astype(theano.config.floatX)
    X, = theano_floatx(X)
    rnn = SupervisedFastDropoutRnn(2, [10], 3, hidden_transfers=['rectifier'], max_iter=10)
    rnn.predict(X)

    rnn = SupervisedFastDropoutRnn(
        2, [10, 20], 3, hidden_transfers=['rectifier', 'tanh'],
        skip_to_out=True, max_iter=10)
    rnn.predict(X)
예제 #4
0
파일: test_rnn.py 프로젝트: Wiebke/breze
def test_fdrnn_pickle():
    X = np.random.standard_normal((10, 5, 2)).astype(theano.config.floatX)
    Z = np.random.standard_normal((10, 5, 3)).astype(theano.config.floatX)
    W = np.random.standard_normal((10, 5, 3)).astype(theano.config.floatX)
    X, Z, W = theano_floatx(X, Z, W)

    rnn = SupervisedFastDropoutRnn(2, [10], 3, hidden_transfers=['rectifier'],
                                   max_iter=2)
    rnn.fit(X, Z)
    rnn.predict(X)

    pickle.dumps(rnn)
예제 #5
0
def test_fdrnn_pickle():
    X = np.random.standard_normal((10, 5, 2)).astype(theano.config.floatX)
    Z = np.random.standard_normal((10, 5, 3)).astype(theano.config.floatX)
    W = np.random.standard_normal((10, 5, 3)).astype(theano.config.floatX)
    X, Z, W = theano_floatx(X, Z, W)

    rnn = SupervisedFastDropoutRnn(2, [10],
                                   3,
                                   hidden_transfers=['rectifier'],
                                   max_iter=2)
    rnn.fit(X, Z)
    rnn.predict(X)

    pickle.dumps(rnn)
예제 #6
0
파일: test_rnn.py 프로젝트: ddofer/breze
def test_fd_srnn_predict():
    X = np.random.standard_normal((10, 5, 2)).astype(theano.config.floatX)
    rnn = SupervisedFastDropoutRnn(2, [10], 3, hidden_transfer='rectifier', max_iter=10)
    print rnn.exprs
    rnn.predict(X)