From ff49937eef024916ac4560ce0134d94006e9e2e5 Mon Sep 17 00:00:00 2001 From: Alex Auvolat Date: Fri, 24 Jul 2015 11:30:27 -0400 Subject: RNN & Bidir RNN refactoring (& fixes, maybe) --- config/bidirectional_1.py | 9 +++------ config/bidirectional_tgtcls_1.py | 10 ++++------ 2 files changed, 7 insertions(+), 12 deletions(-) (limited to 'config') diff --git a/config/bidirectional_1.py b/config/bidirectional_1.py index 35039d2..6970ece 100644 --- a/config/bidirectional_1.py +++ b/config/bidirectional_1.py @@ -10,7 +10,7 @@ dim_embeddings = [ ('week_of_year', 52, 10), ('day_of_week', 7, 10), ('qhour_of_day', 24 * 4, 10), - ('taxi_id', 448, 10), + ('taxi_id', data.taxi_id_size, 10), ] hidden_state_dim = 100 @@ -18,11 +18,8 @@ hidden_state_dim = 100 dim_hidden = [500, 500] embed_weights_init = IsotropicGaussian(0.01) -fork_weights_init = IsotropicGaussian(0.1) -fork_biases_init = Constant(0.01) -rec_weights_init = IsotropicGaussian(0.1) -mlp_weights_init = IsotropicGaussian(0.1) -mlp_biases_init = Constant(0.01) +weights_init = IsotropicGaussian(0.1) +biases_init = Constant(0.01) batch_size = 20 batch_sort_size = 20 diff --git a/config/bidirectional_tgtcls_1.py b/config/bidirectional_tgtcls_1.py index 88328e4..673c1e4 100644 --- a/config/bidirectional_tgtcls_1.py +++ b/config/bidirectional_tgtcls_1.py @@ -15,7 +15,7 @@ dim_embeddings = [ ('week_of_year', 52, 10), ('day_of_week', 7, 10), ('qhour_of_day', 24 * 4, 10), - ('taxi_id', 448, 10), + ('taxi_id', data.taxi_id_size, 10), ] hidden_state_dim = 100 @@ -23,13 +23,11 @@ hidden_state_dim = 100 dim_hidden = [500, 500] embed_weights_init = IsotropicGaussian(0.01) -fork_weights_init = IsotropicGaussian(0.1) -fork_biases_init = Constant(0.01) -rec_weights_init = IsotropicGaussian(0.1) -mlp_weights_init = IsotropicGaussian(0.1) -mlp_biases_init = Constant(0.01) +weights_init = IsotropicGaussian(0.1) +biases_init = Constant(0.01) batch_size = 20 batch_sort_size = 20 max_splits = 100 + -- cgit v1.2.3