Description Usage Arguments Value Examples
Clones (= makes a deep copy) of a RestrictedBolzmannMachine or DeepBeliefNet. This is necessary because the weights are stored in an environment which is shared, so any modification you make to the new object will be propagated to the original one, and reciprocally. After cloning, the two objects are totally independent.
1 2 3 4 5 6 7 |
x |
the |
a clone of x
with weights stored in a new environment
1 2 3 4 5 6 7 8 9 10 | rbm <- RestrictedBolzmannMachine(Layer(784, "continuous"), Layer(1000, "binary"))
rbm2 <- rbm # Shallow copy
rbm3 <- clone(rbm) # Deep copy
rbm$W[] <- 1
rbm$W[1:10, 1:10] # Should be all 1s
rbm2$W[1:10, 1:10] # May be all 1s
rbm3$W[1:10, 1:10] # Should be all 0s
dbn <- DeepBeliefNet(Layers(c(784, 1000, 500, 250, 30), input="continuous", output="gaussian"))
dbn2 <- clone(dbn)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.