learn_do | R Documentation |
Learn Dropout
learn_do(X, y, alpha, hidden_dim, dropout_percent, do_dropout = TRUE)
X |
input data |
y |
output data |
alpha |
proportion of gradient descent |
hidden_dim |
dimension of the hidden layer |
dropout_percent |
percentage to be used for the dropout |
do_dropout |
should dropout be used |
https://qua.st/handcoding-dropout/ https://iamtrask.github.io/2015/07/28/dropout/
# construct data X = matrix(c(0,0,1,0,1,1,1,0,1,1,1,1), nrow=4, byrow=TRUE) y = matrix(c(0,1,1,0),nrow=4) # set hyperparameters alpha = 0.5 hidden_dim = 4 dropout_percent = 0.2 do_dropout = TRUE # run 11 lines function learn_do(X, y, alpha, hidden_dim, dropout_percent, TRUE) # view output synapse_0 synapse_1
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.