# GetSeparation error in evaluation stage of training

**URL:** <https://root-forum.cern.ch/t/getseparation-error-in-evaluation-stage-of-training/43884>\
**Category:** TMVA\
**Created:** [March 9, 2021, 3:02am UTC](https://root-forum.cern.ch/t/getseparation-error-in-evaluation-stage-of-training/43884 "2021-03-09T03:02:31Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![gglawley](https://root-forum.cern.ch/letter_avatar_proxy/v4/letter/g/41988e/32.png) [@gglawley](https://root-forum.cern.ch/u/gglawley)\
**Post date:** [March 9, 2021, 3:02am UTC](https://root-forum.cern.ch/t/getseparation-error-in-evaluation-stage-of-training/43884/1 "2021-03-09T03:02:31Z")

</div>

Hello,  
I’m training a BDT on some large nTuples and I have a stubborn error in the EvaluateAllMethods stage. It reads:  
`<GetSeparation> signal and background histograms have different or invalid dimensions`  
and I suspect it has something to do with the calculated RMS of a certain variable going to `-nan` in the table of variables (line 433 in the included log nohup.txt). This value seems to be reasonable in the other tables that TFHandler\_BDT generates.  
The separation on this variable isn’t great, but I would like to include it in the analysis if possible. Any idea what might be causing this error?

Thanks,  
Gannon

Files:  
Command log: [nohup.txt](https://root-forum.cern.ch/uploads/short-url/oDd1SofHh9fyp1DL0WPLNHKkEO9.txt) (56.6 KB)  
Macro: [performAnalysis.py](https://root-forum.cern.ch/uploads/short-url/9KQHeTCPQfxq34bBhCJV83HgKIw.py) (4.9 KB)  
(Let me know if you want to see the dependencies for the macro or the ntuples themselves. They’re fairly large so I’m not sure how to share them here.)

---

<div class="post-metadata">

**Author:** ![moneta](https://root-forum.cern.ch/user_avatar/root-forum.cern.ch/moneta/32/19423_2.png) [@moneta](https://root-forum.cern.ch/u/moneta)\
**Post date:** [March 12, 2021, 2:08pm UTC](https://root-forum.cern.ch/t/getseparation-error-in-evaluation-stage-of-training/43884/4 "2021-03-12T14:08:13Z")

</div>

Hi,  
I think this is caused by some BDT output values being a NaN for some events, so a check in Tools.cxx:152 fails and ends up in a FATAL.  
I think the issue should be solved if one understand why you are getting NaN values. Are you sure all inputs are OK and not NaN.  
I would need access to your input files to understand more about the problem

Lorenzo

---

<div class="post-metadata">

**Author:** ![gglawley](https://root-forum.cern.ch/letter_avatar_proxy/v4/letter/g/41988e/32.png) [@gglawley](https://root-forum.cern.ch/u/gglawley)\
**Post date:** [March 15, 2021, 4:24pm UTC](https://root-forum.cern.ch/t/getseparation-error-in-evaluation-stage-of-training/43884/5 "2021-03-15T16:24:49Z")

</div>

Hi Lorenzo,  
I’ve checked all the events and none of the inputs are NaN. I’m going to try running the BDT on the input tree in segments to see if I can find which event(s) lead to a NaN BDT output. If you want to take a look at the input files, I can share them. What’s the easiest way to transfer them?  
Gannon

---

<div class="post-metadata">

**Author:** ![moneta](https://root-forum.cern.ch/user_avatar/root-forum.cern.ch/moneta/32/19423_2.png) [@moneta](https://root-forum.cern.ch/u/moneta)\
**Post date:** [March 15, 2021, 4:47pm UTC](https://root-forum.cern.ch/t/getseparation-error-in-evaluation-stage-of-training/43884/6 "2021-03-15T16:47:21Z")

</div>

Hi,  
You can share via cernbox for example. Please also share your C++ code running the BDT.

Cheers

Lorenzo

---

<div class="post-metadata">

**Author:** ![gglawley](https://root-forum.cern.ch/letter_avatar_proxy/v4/letter/g/41988e/32.png) [@gglawley](https://root-forum.cern.ch/u/gglawley)\
**Post date:** [March 15, 2021, 10:54pm UTC](https://root-forum.cern.ch/t/getseparation-error-in-evaluation-stage-of-training/43884/7 "2021-03-15T22:54:31Z")

</div>

Hi,  
[Here’s a link](https://cernbox.cern.ch/index.php/s/VNCDPb4CEtQYNjw) to the files I was analyzing (WW as signal, ttbar as background.) I am using a set of python files instead of C++ to run the BDT, which I included. The `performAnalysis.py` file in `run` is what i actually run, while `src` contains middleware used to load the data files, declare variables etc.  
Thanks,  
Gannon
