Skip to content

Commit

Permalink
[tutorials] Rename TMVA to Machine Learning category.
Browse files Browse the repository at this point in the history
Inside the current TMVA category of tutorials,
there are not only the tmva tutorials but for example
also RBatchGenerator tutorials. Hence, new Machine
Learning category will be the entry point to all the
related tutorials.
Paths to files were changed across all of the ROOT
repository as well.
  • Loading branch information
martamaja10 committed Dec 4, 2024
1 parent 4042121 commit f79b53c
Show file tree
Hide file tree
Showing 85 changed files with 158 additions and 158 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -300,7 +300,7 @@ def __transformOneGroup(self, firstLine):
self.iterLines.next()
lineIter.next()
tmp_str += "<td><b>" + WelcomeHeader.group(1) + "</b></td></tr>"
tmp_str += "<tr><td><img src='https://rawgit.com/root-project/root/master/tutorials/tmva/tmva_logo.svg' width='100%' /><br />"
tmp_str += "<tr><td><img src='https://rawgit.com/root-project/root/master/tutorials/machine_learning/tmva_logo.svg' width='100%' /><br />"
tmp_str += "<center><b>" + EndWelcome.group(1) + "</b></center></td></tr>"
else:
lmatch = re.match(r"\s*(<\w+>\s*)*\s*:\s*(.*)", nextline)
Expand Down
4 changes: 2 additions & 2 deletions documentation/tmva/UsersGuide/TMVAdef.tex
Original file line number Diff line number Diff line change
Expand Up @@ -245,5 +245,5 @@
\newcommand{\IHessiankmone}{\ensuremath{\Hessian^{-1(k-1)}}\xspace}
% TMVA constants
\newcommand\TmvaTutorialDir{\code{$ROOTSYS/tutorials/tmva/test}~}
\newcommand\TmvaKerasTutorialDir{\code{$ROOTSYS/tutorials/tmva/test/keras}~}
\newcommand\TmvaTutorialDir{\code{$ROOTSYS/tutorials/machine_learning/test}~}
\newcommand\TmvaKerasTutorialDir{\code{$ROOTSYS/tutorials/machine_learning/test/keras}~}
6 changes: 3 additions & 3 deletions documentation/tmva/UsersGuide/UsingTMVAQuickStart.tex
Original file line number Diff line number Diff line change
Expand Up @@ -81,8 +81,8 @@ \subsection{Running the example}
to ROOT's macro search path:
\begin{codeexample}
\begin{tmvacode}
> root -l $ROOTSYS/tutorials/tmva/TMVAClassification.C
> echo "Unix.*.Root.MacroPath: $ROOTSYS/tutorials/tmva" >> ~/.rootrc
> root -l $ROOTSYS/tutorials/machine_learning/TMVAClassification.C
> echo "Unix.*.Root.MacroPath: $ROOTSYS/tutorials/machine_learning" >> ~/.rootrc
> root -l TMVAClassification.C
\end{tmvacode}
\caption[.]{\codeexampleCaptionSize Running the example \code{TMVAClassification.C}.}
Expand All @@ -91,7 +91,7 @@ \subsection{Running the example}
It is also possible to explicitly select the MVA methods to be processed:
\begin{codeexample}
\begin{tmvacode}
> root -l '$ROOTSYS/tutorials/tmva/TMVAClassification.C("Fisher","BDT")'
> root -l '$ROOTSYS/tutorials/machine_learning/TMVAClassification.C("Fisher","BDT")'
\end{tmvacode}
\caption[.]{\codeexampleCaptionSize Running the example \code{TMVAClassification.C} and processing only the Fisher and BDTclassifier. Multiple classifiers are separated by commas. The others macros can be called accordingly.}
\end{codeexample}
Expand Down
4 changes: 2 additions & 2 deletions tmva/doc/README
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ copying of 'evaluation macros' necessary anymore !

All the evaluation macros are now part of the TMVA library libTMVA.so

Example scripts of how to run TMVA are available in $ROOTSYS/tutorials/tmva/
Example scripts of how to run TMVA are available in $ROOTSYS/tutorials/machine_learning/
!!!!!

After 2013 TMVA was completely integrated into ROOT and is now released as part of it.
Expand All @@ -31,7 +31,7 @@ System requirements:
========================================================================================
Getting Started:
----------------
Example scripts of how to run TMVA are availabe in $ROOTSYS/tutorials/tmva/
Example scripts of how to run TMVA are availabe in $ROOTSYS/tutorials/machine_learning/

please simply copy one of those scripts to you 'work' directory

Expand Down
2 changes: 1 addition & 1 deletion tmva/pymva/test/testPyAdaBoostMulticlass.C
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ int testPyAdaBoostMulticlass(){
TString fname = "./tmva_example_multiple_background.root";
if (gSystem->AccessPathName(fname)){ // file does not exist in local directory
std::cout << "Create multiclass test data..." << std::endl;
TString createDataMacro = TString(gROOT->GetTutorialsDir()) + "/tmva/createData.C";
TString createDataMacro = TString(gROOT->GetTutorialsDir()) + "/machine_learning/createData.C";
gROOT->ProcessLine(TString::Format(".L %s",createDataMacro.Data()));
gROOT->ProcessLine("create_MultipleBackground(200)");
std::cout << "Created " << fname << " for tests of the multiclass features" << std::endl;
Expand Down
2 changes: 1 addition & 1 deletion tmva/pymva/test/testPyGTBMulticlass.C
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ int testPyGTBMulticlass(){
TString fname = "./tmva_example_multiple_background.root";
if (gSystem->AccessPathName(fname)){ // file does not exist in local directory
std::cout << "Create multiclass test data..." << std::endl;
TString createDataMacro = TString(gROOT->GetTutorialsDir()) + "/tmva/createData.C";
TString createDataMacro = TString(gROOT->GetTutorialsDir()) + "/machine_learning/createData.C";
gROOT->ProcessLine(TString::Format(".L %s",createDataMacro.Data()));
gROOT->ProcessLine("create_MultipleBackground(200)");
std::cout << "Created " << fname << " for tests of the multiclass features" << std::endl;
Expand Down
2 changes: 1 addition & 1 deletion tmva/pymva/test/testPyKerasMulticlass.C
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ int testPyKerasMulticlass(){
TString fname = "./tmva_example_multiple_background.root";
if (gSystem->AccessPathName(fname)){ // file does not exist in local directory
std::cout << "Create multiclass test data..." << std::endl;
TString createDataMacro = TString(gROOT->GetTutorialsDir()) + "/tmva/createData.C";
TString createDataMacro = TString(gROOT->GetTutorialsDir()) + "/machine_learning/createData.C";
gROOT->ProcessLine(TString::Format(".L %s",createDataMacro.Data()));
gROOT->ProcessLine("create_MultipleBackground(200)");
std::cout << "Created " << fname << " for tests of the multiclass features" << std::endl;
Expand Down
2 changes: 1 addition & 1 deletion tmva/pymva/test/testPyRandomForestMulticlass.C
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ int testPyRandomForestMulticlass(){
TString fname = "./tmva_example_multiple_background.root";
if (gSystem->AccessPathName(fname)){ // file does not exist in local directory
std::cout << "Create multiclass test data..." << std::endl;
TString createDataMacro = TString(gROOT->GetTutorialsDir()) + "/tmva/createData.C";
TString createDataMacro = TString(gROOT->GetTutorialsDir()) + "/machine_learning/createData.C";
gROOT->ProcessLine(TString::Format(".L %s",createDataMacro.Data()));
gROOT->ProcessLine("create_MultipleBackground(200)");
std::cout << "Created " << fname << " for tests of the multiclass features" << std::endl;
Expand Down
2 changes: 1 addition & 1 deletion tmva/pymva/test/testPyTorchMulticlass.C
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ int testPyTorchMulticlass(){
TString fname = "./tmva_example_multiple_background.root";
if (gSystem->AccessPathName(fname)){ // file does not exist in local directory
std::cout << "Create multiclass test data..." << std::endl;
TString createDataMacro = TString(gROOT->GetTutorialsDir()) + "/tmva/createData.C";
TString createDataMacro = TString(gROOT->GetTutorialsDir()) + "/machine_learning/createData.C";
gROOT->ProcessLine(TString::Format(".L %s",createDataMacro.Data()));
gROOT->ProcessLine("create_MultipleBackground(200)");
std::cout << "Created " << fname << " for tests of the multiclass features" << std::endl;
Expand Down
18 changes: 9 additions & 9 deletions tmva/sofie/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -148,13 +148,13 @@ The above operators are supported for tensors of the following types:
## Additional Links

- **Tutorials**
- [TMVA_SOFIE_Inference](https://github.com/root-project/root/blob/master/tutorials/tmva/TMVA_SOFIE_Inference.py)
- [TMVA_SOFIE_Keras](https://github.com/root-project/root/blob/master/tutorials/tmva/TMVA_SOFIE_Keras.C)
- [TMVA_SOFIE_Keras_HiggsModel](https://github.com/root-project/root/blob/master/tutorials/tmva/TMVA_SOFIE_Keras_HiggsModel.C)
- [TMVA_SOFIE_ONNX](https://github.com/root-project/root/blob/master/tutorials/tmva/TMVA_SOFIE_ONNX.C)
- [TMVA_SOFIE_PyTorch](https://github.com/root-project/root/blob/master/tutorials/tmva/TMVA_SOFIE_PyTorch.C)
- [TMVA_SOFIE_RDataFrame](https://github.com/root-project/root/blob/master/tutorials/tmva/TMVA_SOFIE_RDataFrame.C)
- [TMVA_SOFIE_RDataFrame](https://github.com/root-project/root/blob/master/tutorials/tmva/TMVA_SOFIE_RDataFrame.py)
- [TMVA_SOFIE_RDataFrame_JIT](https://github.com/root-project/root/blob/master/tutorials/tmva/TMVA_SOFIE_RDataFrame_JIT.C)
- [TMVA_SOFIE_RSofieReader](https://github.com/root-project/root/blob/master/tutorials/tmva/TMVA_SOFIE_RSofieReader.C)
- [TMVA_SOFIE_Inference](https://github.com/root-project/root/blob/master/tutorials/machine_learning/TMVA_SOFIE_Inference.py)
- [TMVA_SOFIE_Keras](https://github.com/root-project/root/blob/master/tutorials/machine_learning/TMVA_SOFIE_Keras.C)
- [TMVA_SOFIE_Keras_HiggsModel](https://github.com/root-project/root/blob/master/tutorials/machine_learning/TMVA_SOFIE_Keras_HiggsModel.C)
- [TMVA_SOFIE_ONNX](https://github.com/root-project/root/blob/master/tutorials/machine_learning/TMVA_SOFIE_ONNX.C)
- [TMVA_SOFIE_PyTorch](https://github.com/root-project/root/blob/master/tutorials/machine_learning/TMVA_SOFIE_PyTorch.C)
- [TMVA_SOFIE_RDataFrame](https://github.com/root-project/root/blob/master/tutorials/machine_learning/TMVA_SOFIE_RDataFrame.C)
- [TMVA_SOFIE_RDataFrame](https://github.com/root-project/root/blob/master/tutorials/machine_learning/TMVA_SOFIE_RDataFrame.py)
- [TMVA_SOFIE_RDataFrame_JIT](https://github.com/root-project/root/blob/master/tutorials/machine_learning/TMVA_SOFIE_RDataFrame_JIT.C)
- [TMVA_SOFIE_RSofieReader](https://github.com/root-project/root/blob/master/tutorials/machine_learning/TMVA_SOFIE_RSofieReader.C)

4 changes: 2 additions & 2 deletions tmva/tmvagui/src/tmvaglob.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -252,9 +252,9 @@ void TMVA::TMVAGlob::imgconv( TCanvas* c, const TString & fname )
TImage * TMVA::TMVAGlob::findImage(const char * imageName)
{
// looks for the image in tutorialpath
//TString tutorialPath = "$ROOTSYS/tutorials/tmva"; // look for the image in here
//TString tutorialPath = "$ROOTSYS/tutorials/machine_learning"; // look for the image in here
TString tutorialPath = getenv ("ROOTSYS");
tutorialPath+="/tutorials/tmva";
tutorialPath+="/tutorials/machine_learning";
TImage *img = nullptr;
TString fullName = TString::Format("%s/%s", tutorialPath.Data(), imageName);
Bool_t fileFound = ! gSystem->AccessPathName(fullName);
Expand Down
Loading

0 comments on commit f79b53c

Please sign in to comment.