{"action":"created","issue":{"url":"https://api.github.com/repos/Element-Research/rnn/issues/284","repository_url":"https://api.github.com/repos/Element-Research/rnn","labels_url":"https://api.github.com/repos/Element-Research/rnn/issues/284/labels{/name}","comments_url":"https://api.github.com/repos/Element-Research/rnn/issues/284/comments","events_url":"https://api.github.com/repos/Element-Research/rnn/issues/284/events","html_url":"https://github.com/Element-Research/rnn/issues/284","id":162684254,"number":284,"title":"Adapt simple-recurrence-network to regression","user":{"login":"MLBenjii","id":20187578,"avatar_url":"https://avatars.githubusercontent.com/u/20187578?v=3","gravatar_id":"","url":"https://api.github.com/users/MLBenjii","html_url":"https://github.com/MLBenjii","followers_url":"https://api.github.com/users/MLBenjii/followers","following_url":"https://api.github.com/users/MLBenjii/following{/other_user}","gists_url":"https://api.github.com/users/MLBenjii/gists{/gist_id}","starred_url":"https://api.github.com/users/MLBenjii/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/MLBenjii/subscriptions","organizations_url":"https://api.github.com/users/MLBenjii/orgs","repos_url":"https://api.github.com/users/MLBenjii/repos","events_url":"https://api.github.com/users/MLBenjii/events{/privacy}","received_events_url":"https://api.github.com/users/MLBenjii/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":1,"created_at":"2016-06-28T13:21:07Z","updated_at":"2016-07-01T04:28:36Z","closed_at":null,"body":"Hello,\r\n\r\nI am new to Torch / NN, and so I am trying to create a simple regression model based on the simple-recurrence-network example as a learning exercise.\r\n\r\nI thought this would be as simple as:\r\n- changing the lookup table to a linear layer\r\n- set nIndex to 1 (overload nIndex as input size)\r\n- remove LogSoftMax at output\r\n- use MSECriterion in place of the ClassNLLCriterion\r\n\r\nHowever, when I run this model, I get an error from the first Linear module referenced by the ParallelTable:\r\n\r\nLinear.lua:57: size mismatch, [7 x 1], [8]\r\n\r\nMy hidden layer is size 7, and batch size is 8. This should be doing a matrix-vector mult of [7x1] matrix by [1] vector, but instead the batch is being passed through (by the sequencer?).\r\n\r\nI assume I am missing something very basic here.... any help appreciated!\r\n\r\nSetup of model is as follows:\r\nlocal rm = nn.Sequential() \r\n   :add(nn.ParallelTable()\r\n      :add(nn.Linear(nIndex, hiddenSize)) \r\n      :add(nn.Linear(hiddenSize, hiddenSize))) \r\n   :add(nn.CAddTable()) -- merge\r\n   :add(nn.Sigmoid()) -- transfer\r\n\r\nlocal rnn = nn.Sequential()\r\n   :add(nn.Recurrence(rm, hiddenSize, 0)) \r\n   :add(nn.Linear(hiddenSize, nIndex))\r\n\r\nrnn = nn.Sequencer(rnn)"},"comment":{"url":"https://api.github.com/repos/Element-Research/rnn/issues/comments/229851342","html_url":"https://github.com/Element-Research/rnn/issues/284#issuecomment-229851342","issue_url":"https://api.github.com/repos/Element-Research/rnn/issues/284","id":229851342,"user":{"login":"rracinskij","id":13356312,"avatar_url":"https://avatars.githubusercontent.com/u/13356312?v=3","gravatar_id":"","url":"https://api.github.com/users/rracinskij","html_url":"https://github.com/rracinskij","followers_url":"https://api.github.com/users/rracinskij/followers","following_url":"https://api.github.com/users/rracinskij/following{/other_user}","gists_url":"https://api.github.com/users/rracinskij/gists{/gist_id}","starred_url":"https://api.github.com/users/rracinskij/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rracinskij/subscriptions","organizations_url":"https://api.github.com/users/rracinskij/orgs","repos_url":"https://api.github.com/users/rracinskij/repos","events_url":"https://api.github.com/users/rracinskij/events{/privacy}","received_events_url":"https://api.github.com/users/rracinskij/received_events","type":"User","site_admin":false},"created_at":"2016-07-01T04:28:36Z","updated_at":"2016-07-01T04:28:36Z","body":"Hi @MLBenjii ,\r\ncan't replicate your error. What is your input? Why do you use ParallelTable?"}}
{"actor":{"display_login":"rracinskij"}}