Logo ROOT   6.08/07
Reference Guide
TestBackpropagationCpu.cxx
Go to the documentation of this file.
1 // @(#)root/tmva $Id$
2 // Author: Simon Pfreundschuh
3 
4 /*************************************************************************
5  * Copyright (C) 2016, Simon Pfreundschuh *
6  * All rights reserved. *
7  * *
8  * For the licensing terms see $ROOTSYS/LICENSE. *
9  * For the list of contributors see $ROOTSYS/README/CREDITS. *
10  *************************************************************************/
11 
12 ////////////////////////////////////////////////////////////////////
13 // Concrete instantiation of the generic backpropagation test for //
14 // multi-threaded CPU architectures. //
15 ////////////////////////////////////////////////////////////////////
16 
17 #include "TMatrix.h"
19 #include "TestBackpropagation.h"
20 
21 using namespace TMVA::DNN;
22 
23 int main()
24 {
25  using Scalar_t = Double_t;
26  std::cout << "Testing Backpropagation:" << std::endl;
27 
28  double error;
29 
30  error = testBackpropagationWeightsLinear<TCpu<Scalar_t>>(1.0);
31  if (error > 1e-3)
32  return 1;
33 
34  error = testBackpropagationL1Regularization<TCpu<Scalar_t>>(1e-2);
35  if (error > 1e-3)
36  return 1;
37 
38  error = testBackpropagationL2Regularization<TCpu<Scalar_t>>(1.0);
39  if (error > 1e-3)
40  return 1;
41 
42  error = testBackpropagationBiasesLinear<TCpu<Scalar_t>>(1.0);
43  if (error > 1e-3)
44  return 1;
45 
46  return 0;
47 }
Definition: Blas.h:58
int main()
double Double_t
Definition: RtypesCore.h:55
you should not use this method at all Int_t Int_t Double_t Double_t Double_t e
Definition: TRolke.cxx:630