TMVA dealing tree with vary branch size in PyROOT

So I am trying to construct a training script for a root file that contain a tree with branch that contains different branch size, what i mean here is most of my branch has single float value but some branch has 2 float values or more.


The original root file is from experiment where some branches are done so to minimize file size(ex:- temperature at different location, but save all of them in single branch). This is temporary, will move to proper training data later on.

What would be the best way to handling such structured root files? As so far I managed to get it work by including branches with single float value. However Ideally I would love to consider all the branches I have for the training script.

The training data is just temporary where I plan to have actual simulated data for it but for the moment I would love to get a training script done first.

Maybe @moneta can help here…


Unfortunately we don’t support varying branch sizes for each event. If you are sure the sizes are the same you should be able to use as names “branch[0], branch[1], etc…” but they must exist for each event


Hi Moneta,

Thanks for the reply, never thought about doing it that way. I do know the size of the branches so I tried it and it works. thank you very much