xbpeng / DeepTerrainRL

terrain-adaptive locomotion skills using deep reinforcement learning
GNU Lesser General Public License v3.0
432 stars 129 forks source link

Two networks in cNeuralNet class? #31

Closed YurongYou closed 7 years ago

YurongYou commented 7 years ago

Hi, I found that there are two networks in the cNeuralNet class, one is mNet, the other is the network in the mSolver, and it seems that the two networks synchronize frequently while training. Could you please explain briefly what's the functionality of them respectively? Thanks!

xbpeng commented 7 years ago

This is because caffe uses different structures for the networks for training and testing. mNet is mainly what is used during runtime to evaluate the policy. The network in mSolver is the one used to update the weights. Because of the way caffe allocates resources for the net, mNet can only evaluate one input at a time, while the one in mSolver can evaluate batches. Hope that clears it up a bit.