Skip to content
Snippets Groups Projects
Commit 18735760 authored by Van Dung NGUYEN's avatar Van Dung NGUYEN
Browse files

delete before adding new layer

parent 56693b2b
No related branches found
No related tags found
No related merge requests found
......@@ -220,6 +220,7 @@ void ArtificialNN::addLayer(int index, const DenseLayer& layer)
else
{
// we add pointer to existing object instead of creating a new one
if (_allLayers[index] != NULL) delete _allLayers[index];
_allLayers[index] = layer.clone();
Msg::Info("add layer: %d",index);
_allLayers[index]->print_infos();
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment