File tree Expand file tree Collapse file tree 1 file changed +8
-4
lines changed Expand file tree Collapse file tree 1 file changed +8
-4
lines changed Original file line number Diff line number Diff line change 1010
1111using namespace TMVA ::Experimental ;
1212
13- void TMVA_SOFIE_ONNX (){
13+ void TMVA_SOFIE_ONNX (std ::string inputFile = "" ){
14+ if (inputFile .empty () )
15+ inputFile = std ::string (gROOT -> GetTutorialsDir ()) + "/tmva/Linear_16.onnx" ;
16+
1417 //Creating parser object to parse ONNX files
15- SOFIE ::RModelParser_ONNX Parser ;
16- SOFIE ::RModel model = Parser .Parse (std :: string ( gROOT -> GetTutorialsDir ()) + "/tmva/Linear_16.onnx" );
18+ SOFIE ::RModelParser_ONNX parser ;
19+ SOFIE ::RModel model = parser .Parse (inputFile , true );
1720
1821 //Generating inference code
1922 model .Generate ();
20- model .OutputGenerated ("Linear_16.hxx" );
23+ // write the code in a file (by default Linear_16.hxx and Linear_16.dat
24+ model .OutputGenerated ();
2125
2226 //Printing required input tensors
2327 model .PrintRequiredInputTensors ();
You can’t perform that action at this time.
0 commit comments