Logo ROOT   6.08/07
Reference Guide
Functions | Variables
testPyKerasClassification.C File Reference
#include <iostream>
#include "TString.h"
#include "TFile.h"
#include "TTree.h"
#include "TSystem.h"
#include "TMVA/Factory.h"
#include "TMVA/Reader.h"
#include "TMVA/DataLoader.h"
#include "TMVA/PyMethodBase.h"
Include dependency graph for testPyKerasClassification.C:

Functions

int main ()
 
int testPyKerasClassification ()
 

Variables

TString pythonSrc
 

Function Documentation

◆ main()

int main ( )

Definition at line 128 of file testPyKerasClassification.C.

◆ testPyKerasClassification()

int testPyKerasClassification ( )

Definition at line 24 of file testPyKerasClassification.C.

Variable Documentation

◆ pythonSrc

TString pythonSrc
Initial value:
= "\
from keras.models import Sequential\n\
from keras.layers.core import Dense, Activation\n\
from keras import initializations\n\
from keras.optimizers import SGD\n\
\n\
model = Sequential()\n\
model.add(Dense(64, init=\"normal\", activation=\"relu\", input_dim=4))\n\
model.add(Dense(2, init=\"normal\", activation=\"softmax\"))\n\
model.compile(loss=\"categorical_crossentropy\", optimizer=SGD(lr=0.01), metrics=[\"accuracy\",])\n\
model.save(\"kerasModelClassification.h5\")\n"

Definition at line 12 of file testPyKerasClassification.C.