# Setting a global TMVA debug flag

**URL:** <https://root-forum.cern.ch/t/setting-a-global-tmva-debug-flag/31576>\
**Category:** TMVA\
**Created:** [November 13, 2018, 4:56pm UTC](https://root-forum.cern.ch/t/setting-a-global-tmva-debug-flag/31576 "2018-11-13T16:56:34Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![pversch](https://root-forum.cern.ch/letter_avatar_proxy/v4/letter/p/b9bd4f/32.png) [@pversch](https://root-forum.cern.ch/u/pversch)\
**Post date:** [November 13, 2018, 4:56pm UTC](https://root-forum.cern.ch/t/setting-a-global-tmva-debug-flag/31576/1 "2018-11-13T16:56:35Z")

</div>

Hi,

In the TMVA code I keep finding print messages of the following form:

Log() \<\< kDEBUG \<\< “This is a debug message” \<\< Endl;

How can I enable these print messages? I tried adding the string option VerbosityLevel=Debug to certain TMVA methods but not all of them know this option and I want to apply this flag to all the TMVA class instantiations.

Kind regards,

Pim

---

<div class="post-metadata">

**Author:** ![kialbert](https://root-forum.cern.ch/user_avatar/root-forum.cern.ch/kialbert/32/16537_2.png) [@kialbert](https://root-forum.cern.ch/u/kialbert)\
**Post date:** [November 13, 2018, 5:28pm UTC](https://root-forum.cern.ch/t/setting-a-global-tmva-debug-flag/31576/2 "2018-11-13T17:28:29Z")

</div>

Hi, there are 3 places where you can add the verbosity level option:

```auto
1) auto factory = Factory{dataloader, "", "VerboseLevel=Debug"};
2) dataloader->PrepareTrainingAndTestTree("", "", "VerboseLevel=Debug");
3) factory.BookMethod(..., ..., "VerbosityLevel=Debug")

```

Please do note the change in option name for `BookMethod`. Also, it is my impression that sometime the verbosity option does not play nice with the `"V"` option. If you don’t see the expected debug output, try changing `"V:VerbosityLevel=Debug"` to just `"VerbosityLevel=Debug"`.

Cheers,  
Kim

---

<div class="post-metadata">

**Author:** ![pversch](https://root-forum.cern.ch/letter_avatar_proxy/v4/letter/p/b9bd4f/32.png) [@pversch](https://root-forum.cern.ch/u/pversch)\
**Post date:** [November 13, 2018, 10:45pm UTC](https://root-forum.cern.ch/t/setting-a-global-tmva-debug-flag/31576/3 "2018-11-13T22:45:19Z")

</div>

Thank you ver much. The removal of the V option was indeed necessary.

Pim
