- integrated RnnStack

git-svn-id: http://moon:8086/svn/software/trunk/projects/Rbm@826 b431acfa-c32f-4a4a-93f1-934dc6c82436
This commit is contained in:
2022-01-18 08:36:10 +00:00
parent 9b2861e3d8
commit 17770f402c
10 changed files with 130 additions and 34 deletions
+16
View File
@@ -24,6 +24,22 @@ DeepStack::~DeepStack()
{
}
arma::mat DeepStack::trainingBatchFrom(size_t layerId, const arma::mat& batch)
{
arma::mat thisBatch = batch;
Layer *pLayer = getLayer(0);
while (pLayer)
{
if (pLayer->id() == layerId)
{
break;
}
thisBatch = pLayer->toHiddenProbs(thisBatch);
pLayer = pLayer->next;
}
return thisBatch;
}
void DeepStack::train(const arma::mat& batch, Rbm::IListener* pListener)
{
arma::mat thisBatch = batch;