diff --git a/dlib/dnn/core.h b/dlib/dnn/core.h index 1c0feca8e..92fa249bf 100644 --- a/dlib/dnn/core.h +++ b/dlib/dnn/core.h @@ -1056,7 +1056,7 @@ namespace dlib ) { temp_tensor.clear(); - subnetwork.clear(); + subnetwork.clean(); } friend void serialize(const add_loss_layer& item, std::ostream& out)