Home | News | Documentation | Download

Tree files - ROOT/GAMOS/Geant4


#1

Good Morning!

I have doing a Tree file with GAMOS5.1.0 and I have one doubt that I don’t know if have something wtih the root or Gamos/Geant4. So, The doubt is that a Tree File has been produced but sometimes the value in RMS and Mean appears zero, and in some trees the entries appears a different value what I supposed that is because the physics envolved.

In attached I place a root file for example.

https://drive.google.com/file/d/1SE6NAR3DtqQf3W45ntzgDKqeoLYObIhA/view?usp=sharing

Thanks


ROOT Version: 5.34.36
Platform: Ubuntu14.04 Linux
Compiler: Not Provided



#2

Hi David,

I think maybe it is better to ask GAMOS experts and probably provide them reproducer to decide what could be wrong.

Cheers,
Oksana.


#3

Thanks, @oshadura for the answer!
I already asked in the forum of GAMOS, I’m waited the answer!

But I have a doubt in concern to the root file that maybe it’s help me understand better the histogram in root. Well, every histogram have entries, but some of the histograms in this root file appears with less entries than in the data in the histogram itself. What I meant is that it’s seems that in some cases the number of entries do not correspond to the number that is saw in the histogram, like for example, in the root file link add above “BraTreeEx_tree_1000.root” there is a branch named “Step_Particle” and inside a leaf named “data”, that shows this. Could anyone help me understand why this is possible in terms of the root program?

Thanks


#4

From the output of BraTreeEx->Print("Step_Particle*"); you can see that it is a std::vector<std::string> so, try simply: BraTreeEx->Scan("Step_Particle", "Step_Particle.size() != 0");

[...] $ root BraTreeEx_tree_1000.root 
root [0] 
Attaching file BraTreeEx_tree_1000.root as _file0...
root [1] BraTreeEx->Print("Step_Particle*");
******************************************************************************
*Tree    :BraTreeEx : BraTreeEx                                              *
*Entries :   100000 : Total =        68839581 bytes  File  Size =   11283633 *
*        :          : Tree compression factor =   6.10                       *
******************************************************************************
*Br    0 :Step_Particle : vector<string>                                     *
*Entries :   100000 : Total  Size=    1406819 bytes  File Size  =     157234 *
*Baskets :       57 : Basket Size=      32000 bytes  Compression=   8.94     *
*............................................................................*
root [2] BraTreeEx->Scan("Step_Particle", "Step_Particle.size() != 0");
***********************************
*    Row   * Instance * Step_Part *
***********************************
*     1776 *        0 *     gamma *
*    23465 *        0 *     gamma *
*    42371 *        0 *     gamma *
*    77674 *        0 *     gamma *
*    87300 *        0 *     gamma *
*    89600 *        0 *     gamma *
*    92100 *        0 *     gamma *
*    95409 *        0 *     gamma *
***********************************
==> 8 selected entries
root [3] .q

#5

Thanks for the fast response @Wile_E_Coyote.

I have another question: How can I do it in order to see the entries of the branch “Event_AccumulatedEnergyLost” in the tree file “BraTreeEx_tree_1000.root”? This is to understand why the mean and rms of 100000 entries goes to zero.

Thank you!


#6
BraTreeEx->Print("Event_AccumulatedEnergyLost*");
BraTreeEx->Scan("Event_AccumulatedEnergyLost");
BraTreeEx->Scan("Event_AccumulatedEnergyLost", "Event_AccumulatedEnergyLost != 0");

See also:
TTree::Print
TTree::Scan
TTree::Draw