ChanServ changed the topic of #mlpack to: Due to ongoing spam on freenode, we've muted unregistered users. See http://www.mlpack.org/ircspam.txt for more information, or also you could join #mlpack-temp and chat there.
rcurtin has joined #mlpack
robertohueso has joined #mlpack
vivekp has quit [Ping timeout: 264 seconds]
vivekp has joined #mlpack
vivekp has quit [Read error: Connection reset by peer]
vivekp has joined #mlpack
vivekp has quit [Ping timeout: 252 seconds]
vivekp has joined #mlpack
davida has joined #mlpack
< davida>
Could someone please share how to correctly implement Gradient Clipping on an optimizer?
< davida>
... but I get compile errors basically telling me:
< davida>
'Optimize': is not a member of 'mlpack::optimization::GradientClipping<mlpack::optimization::SGD<mlpack::optimization::AdamUpdate,mlpack::optimization::NoDecay>>'
< davida>
I should add that I am using the clippedOptimizer like this:
< zoq>
davida: Let me klnow if that works for you.
< davida>
zoq: Thx. I will give that a go shortly and get back to you.
< davida>
zoq: Yes. That works and I now realise that I have to apply clipping to the update policy and not the optimizer.
< davida>
I am building an RNN with my ClippedGradients. Now I am at the point to train my network with X inputs and Y labels configured in arma::mat variables. My compiler is giving me an error stating that in function Train, the compiler cannot convert from arma::mat to arma::cube .
< davida>
Why would my RNN expect cubes? Is that a default template that needs to be overridden somewhere?
< davida>
The full error reads: 'void mlpack::ann::RNN<mlpack::ann::NegativeLogLikelihood<arma::mat,arma::mat>,mlpack::ann::HeInitialization>::Train<mlpack::optimization::SGD<mlpack::optimization::GradientClipping<mlpack::optimization::AdamUpdate>,mlpack::optimization::NoDecay>>(arma::cube,arma::cube,OptimizerType &)': cannot convert argument 1 from 'arma::mat' to 'arma::cube'
< davida>
Hmmm. OK - reading documentation it mentions need to use cubes with i,j,k representing the i'th dimension of the j'th data point at time slice k.
cjlcarvalho has quit [Quit: Konversation terminated!]
caiocarvalho has quit [Ping timeout: 245 seconds]
< davida>
I do have a question regarding this cube for inputs. If each slice is a step in time and this can vary by datapoint, then the cube needs to have the 'k' dimension to be the size of the longest datapoint. With this in mind, how do you instruct the RNN to stop processing those datapoints that are shorter than the longest datapoint?
caiocarvalho has joined #mlpack
caiocarvalho has quit [Ping timeout: 252 seconds]
vivekp has quit [Read error: Connection reset by peer]
vivekp has joined #mlpack
< davida>
Hi, I am struggling a little with creating an RNN. I have a cube of labels that is X(27, 1500, 25) and my labels match as Y(27,1500,25). The input is a OneHot vector and the output should be another OneHot vector of the same dimension (prediction). I want to have 50 nodes in my RNN. I have built is like this:
< davida>
This is basically trying to follow the example provided in the tutorial on the mlpack website with a few modifications. I am not sure at all if what I am doing here is correct since I cannot find many examples of RNNs with MLPACK.
< davida>
Could someone have a look at my model and see if it makes sense. I am getting an error when I run the code that tells me I have a matrix multiplication error: "addition: incompatible matrix dimensions: 50x32 and 50x5"
< davida>
It seems a strange error to me as I do not have 5 inputs on any layer.
< davida>
I should note here that my batch_size for SGD is 32, hence the 50x32.
< davida>
Also, "nbrNodes" in the model above = 50
< davida>
... some more info from the aboce error is that it is being thrown in Backward() of the optimizer.
< davida>
...
< davida>
I have tracked the error down to the optimizer by implementing a very simple optimizer instead which works but will not converge, hence the reason I need GradientClipping. The simple optimizer I tried was:
< davida>
I really would appreciate some help on this. Thanks.
< davida>
...
< davida>
Some additional input on above error after more debugging. I removed the GradientClipping and the error is still there which means it is within the AdamUpdate portion of the optimizer. Here is the simpified optimizer code:
< zoq>
davida: Unfortunately we had to strip out the dynamic sequence size support for now, but it should be possible to reintegrate the support again. For now, you might like to pad the input/output.