vict0rsch/deep_learning

what if i change the y dimension to 2, should i just change the output_dim of the last layer

sherlockhoatszx opened this issue · 7 comments

Hi,your original post code is to use 49 dimension X to predict the 50th.how about I want to use 48 dimension to predict 49th and 50th. under such condition : does that mean i just change the output_dime of the last output layer :

model.add(Dense(
output_dim=2))
model.add(Activation("linear"))
Is that right?
Sorry for bothering you again..

actually I use 49 1-dimensional inputs. There is a difference between the timesteps and the dimensions as mentionned in the recurrent.md file I pointed to. so what you suggest with your code is predicting one timestep of a 2-dim vector vs what your words suggest as predicting 2 timesteps of 1-dim vectors. What you can do is for instance [x0...x47] -> RNN -> x_pred_48 and then [x1...x47, x_pred_48] -> RNN -> x_pred_49

i could understand this step [x0...x47] -> RNN -> x_pred_48 .but how could I feed X_pred_48 in the dataset , do you mean i train the model 2 times sequentially? Do you mean I stack LSTM layers on top of the original one

if I change the output_dim of the last layer to 2, That doesn't mean i predict 2 tilmestep ,but it means,something like 2 classes ? did i got it right?

That's for the understanding of what you could do by hand. indeed that's
not how you're gonna train, so what you can do is use a timedistributed
dense layer in the end. Since the regular dense layer only outputs one
'timestep' you have to have a different structure in the end. Once again
refering to the recurrent.md file, if you look at the images, it's not the
same thing to have your output being 1 blue box of dim 2 and 2 blue boxes
of dim 3. Do you see my point?

2016-11-07 16:17 GMT+00:00 sherlockhoatszx notifications@github.com:

i could understand this step [x0...x47] -> RNN -> x_pred_48 .but how could
I feed X_pred_48 in the dataset , do you mean i train the model 2 times
sequentially?


You are receiving this because you commented.
Reply to this email directly, view it on GitHub
#11 (comment),
or mute the thread
https://github.com/notifications/unsubscribe-auth/AI2njvHs7q1p_9_Rs3LfBOh0_qCODp_Oks5q708NgaJpZM4KrX-0
.

how about seq2seq if i predict more than 1 time unit

yes!

2016-11-07 16:27 GMT+00:00 sherlockhoatszx notifications@github.com:

how about seq2seq if i predict more than 1 time unit


You are receiving this because you commented.
Reply to this email directly, view it on GitHub
#11 (comment),
or mute the thread
https://github.com/notifications/unsubscribe-auth/AI2njjLvhh-imTp-qiwoeVl-HjaWlFKVks5q71F4gaJpZM4KrX-0
.

okey! many thanks . truly appreciate!