-
Notifications
You must be signed in to change notification settings - Fork 0
/
preprocess.cxx
1991 lines (1734 loc) · 80.6 KB
/
preprocess.cxx
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
#include <vector>
#include <iostream>
#include "TString.h"
#include "TTree.h"
#include "TFile.h"
#include "BDT_mipid.h"
#include "BDT_mipquality.h"
#include "BDT_gap.h"
#include "BDT_hol_lol.h"
#include "BDT_cme_anc.h"
#include "BDT_mgo_mgt.h"
#include "BDT_stw_spt.h"
#include "BDT_trimuon.h"
#include "BDT_br1.h"
#include "BDT_stemdir_br2.h"
#include "BDT_br3.h"
#include "BDT_br3_3.h"
#include "BDT_br3_5.h"
#include "BDT_br3_6.h"
#include "BDT_br4_tro.h"
#include "BDT_pio_1.h"
#include "BDT_pio_2.h"
#include "BDT_vis_1.h"
#include "BDT_vis_2.h"
#include "BDT_stw_2.h"
#include "BDT_stw_3.h"
#include "BDT_stw_4.h"
#include "BDT_sig_1.h"
#include "BDT_sig_2.h"
#include "BDT_lol_1.h"
#include "BDT_lol_2.h"
#include "BDT_tro_1.h"
#include "BDT_tro_2.h"
#include "BDT_tro_4.h"
#include "BDT_tro_5.h"
using namespace std;
int main(int argc, char* argv[]){
cout << "BDT preprocessing!" << endl;
if(argc!=4) {cout << "Incorrect input arguments!" << endl; return 1;}
bool _MC_ = atoi(argv[3]);
TString filename = argv[1];
TFile *inputfile = new TFile(filename);
TString type = argv[2];
TTree *T = (TTree*)inputfile->Get(type);
int run, subrun, event;
int nueTag;
int recoFC;
float Evis;
int truth_nue;
int truth_CC;
int truth_inFV;
int truth_cosmic;
float trueEnu;
float weight, lowEweight;
float GENIEweight, LEEweight;
float trueEdep;
float nuvtx_diff;
float showervtx_diff;
T->SetBranchAddress("run",&run);
T->SetBranchAddress("subrun",&subrun);
T->SetBranchAddress("event",&event);
T->SetBranchAddress("nueTag",&nueTag);
T->SetBranchAddress("recoFC",&recoFC);
T->SetBranchAddress("Evis",&Evis);
if(_MC_){
T->SetBranchAddress("truth_nue",&truth_nue);
T->SetBranchAddress("truth_CC",&truth_CC);
T->SetBranchAddress("truth_inFV",&truth_inFV);
T->SetBranchAddress("truth_cosmic",&truth_cosmic);
T->SetBranchAddress("trueEnu",&trueEnu);
T->SetBranchAddress("weight",&weight);
T->SetBranchAddress("lowEweight",&lowEweight);
T->SetBranchAddress("GENIEweight",&GENIEweight);
T->SetBranchAddress("LEEweight",&LEEweight);
T->SetBranchAddress("trueEdep",&trueEdep);
T->SetBranchAddress("nuvtx_diff",&nuvtx_diff);
T->SetBranchAddress("showervtx_diff",&showervtx_diff);
}
/// BDT tagger variables
// mipid
int mip_flag;
double mip_energy;
int mip_n_end_reduction;
int mip_n_first_mip;
int mip_n_first_non_mip;
int mip_n_first_non_mip_1;
int mip_n_first_non_mip_2;
double mip_vec_dQ_dx_0;
double mip_vec_dQ_dx_1;
double mip_vec_dQ_dx_2;
double mip_vec_dQ_dx_3;
double mip_vec_dQ_dx_4;
double mip_vec_dQ_dx_5;
double mip_vec_dQ_dx_6;
double mip_max_dQ_dx_sample;
int mip_n_below_threshold;
int mip_n_below_zero;
int mip_n_lowest;
int mip_n_highest;
double mip_lowest_dQ_dx;
double mip_highest_dQ_dx;
double mip_medium_dQ_dx;
double mip_stem_length;
double mip_length_main;
double mip_length_total;
double mip_angle_beam;
double mip_iso_angle;
int mip_n_vertex;
int mip_n_good_tracks;
double mip_E_indirect_max_energy;
int mip_flag_all_above;
double mip_min_dQ_dx_5;
int mip_n_other_vertex;
int mip_n_stem_size;
int mip_flag_stem_trajectory;
double mip_min_dis;
int mip_filled;
T->SetBranchAddress("mip_flag",&mip_flag);
T->SetBranchAddress("mip_filled",&mip_filled);
T->SetBranchAddress("mip_energy",&mip_energy);
T->SetBranchAddress("mip_n_end_reduction",&mip_n_end_reduction);
T->SetBranchAddress("mip_n_first_mip",&mip_n_first_mip);
T->SetBranchAddress("mip_n_first_non_mip",&mip_n_first_non_mip);
T->SetBranchAddress("mip_n_first_non_mip_1",&mip_n_first_non_mip_1);
T->SetBranchAddress("mip_n_first_non_mip_2",&mip_n_first_non_mip_2);
T->SetBranchAddress("mip_vec_dQ_dx_0",&mip_vec_dQ_dx_0);
T->SetBranchAddress("mip_vec_dQ_dx_1",&mip_vec_dQ_dx_1);
T->SetBranchAddress("mip_vec_dQ_dx_2",&mip_vec_dQ_dx_2);
T->SetBranchAddress("mip_vec_dQ_dx_3",&mip_vec_dQ_dx_3);
T->SetBranchAddress("mip_vec_dQ_dx_4",&mip_vec_dQ_dx_4);
T->SetBranchAddress("mip_vec_dQ_dx_5",&mip_vec_dQ_dx_5);
T->SetBranchAddress("mip_vec_dQ_dx_6",&mip_vec_dQ_dx_6);
T->SetBranchAddress("mip_max_dQ_dx_sample",&mip_max_dQ_dx_sample);
T->SetBranchAddress("mip_n_below_threshold",&mip_n_below_threshold);
T->SetBranchAddress("mip_n_below_zero",&mip_n_below_zero);
T->SetBranchAddress("mip_n_lowest",&mip_n_lowest);
T->SetBranchAddress("mip_n_highest",&mip_n_highest);
T->SetBranchAddress("mip_lowest_dQ_dx",&mip_lowest_dQ_dx);
T->SetBranchAddress("mip_highest_dQ_dx",&mip_highest_dQ_dx);
T->SetBranchAddress("mip_medium_dQ_dx",&mip_medium_dQ_dx);
T->SetBranchAddress("mip_stem_length",&mip_stem_length);
T->SetBranchAddress("mip_length_main",&mip_length_main);
T->SetBranchAddress("mip_length_total",&mip_length_total);
T->SetBranchAddress("mip_angle_beam",&mip_angle_beam);
T->SetBranchAddress("mip_iso_angle",&mip_iso_angle);
T->SetBranchAddress("mip_n_vertex",&mip_n_vertex);
T->SetBranchAddress("mip_n_good_tracks",&mip_n_good_tracks);
T->SetBranchAddress("mip_E_indirect_max_energy",&mip_E_indirect_max_energy);
T->SetBranchAddress("mip_flag_all_above",&mip_flag_all_above);
T->SetBranchAddress("mip_min_dQ_dx_5",&mip_min_dQ_dx_5);
T->SetBranchAddress("mip_n_other_vertex",&mip_n_other_vertex);
T->SetBranchAddress("mip_n_stem_size",&mip_n_stem_size);
T->SetBranchAddress("mip_flag_stem_trajectory",&mip_flag_stem_trajectory);
T->SetBranchAddress("mip_min_dis",&mip_min_dis);
/// gap
int gap_flag;
int gap_filled;
int gap_flag_prolong_u;
int gap_flag_prolong_v;
int gap_flag_prolong_w;
int gap_flag_parallel;
int gap_n_points;
int gap_n_bad;
double gap_energy;
int gap_num_valid_tracks;
int gap_flag_single_shower;
T->SetBranchAddress("gap_flag",&gap_flag);
T->SetBranchAddress("gap_filled",&gap_filled);
T->SetBranchAddress("gap_flag_prolong_u",&gap_flag_prolong_u);
T->SetBranchAddress("gap_flag_prolong_v",&gap_flag_prolong_v);
T->SetBranchAddress("gap_flag_prolong_w",&gap_flag_prolong_w);
T->SetBranchAddress("gap_flag_parallel",&gap_flag_parallel);
T->SetBranchAddress("gap_n_points",&gap_n_points);
T->SetBranchAddress("gap_n_bad",&gap_n_bad);
T->SetBranchAddress("gap_energy",&gap_energy);
T->SetBranchAddress("gap_num_valid_tracks",&gap_num_valid_tracks);
T->SetBranchAddress("gap_flag_single_shower",&gap_flag_single_shower);
// muon energy and shower angle: cme_anc
int cme_flag;
double cme_mu_energy;
double cme_energy;
double cme_mu_length;
double cme_length;
double cme_angle_beam;
int anc_flag;
double anc_angle;
double anc_max_angle;
double anc_max_length;
double anc_acc_forward_length;
double anc_acc_backward_length;
double anc_acc_forward_length1;
double anc_shower_main_length;
double anc_shower_total_length;
int anc_flag_main_outside;
T->SetBranchAddress("cme_flag",&cme_flag);
T->SetBranchAddress("cme_mu_energy",&cme_mu_energy);
T->SetBranchAddress("cme_energy",&cme_energy);
T->SetBranchAddress("cme_mu_length",&cme_mu_length);
T->SetBranchAddress("cme_length",&cme_length);
T->SetBranchAddress("cme_angle_beam",&cme_angle_beam);
T->SetBranchAddress("anc_flag",&anc_flag);
T->SetBranchAddress("anc_angle",&anc_angle);
T->SetBranchAddress("anc_max_angle",&anc_max_angle);
T->SetBranchAddress("anc_max_length",&anc_max_length);
T->SetBranchAddress("anc_acc_forward_length",&anc_acc_forward_length);
T->SetBranchAddress("anc_acc_backward_length",&anc_acc_backward_length);
T->SetBranchAddress("anc_acc_forward_length1",&anc_acc_forward_length1);
T->SetBranchAddress("anc_shower_main_length",&anc_shower_main_length);
T->SetBranchAddress("anc_shower_total_length",&anc_shower_total_length);
T->SetBranchAddress("anc_flag_main_outside",&anc_flag_main_outside);
// multiple gammas taggers
// mgo_mgt
int mgo_flag;
double mgo_energy;
double mgo_max_energy;
double mgo_total_energy;
int mgo_n_showers;
double mgo_max_energy_1;
double mgo_max_energy_2;
double mgo_total_other_energy;
int mgo_n_total_showers;
double mgo_total_other_energy_1;
int mgt_flag;
int mgt_flag_single_shower;
double mgt_max_energy;
double mgt_total_other_energy;
double mgt_max_energy_1;
double mgt_e_indirect_max_energy;
double mgt_e_direct_max_energy;
int mgt_n_direct_showers;
double mgt_e_direct_total_energy;
int mgt_flag_indirect_max_pio;
double mgt_e_indirect_total_energy;
T->SetBranchAddress("mgo_flag",&mgo_flag);
T->SetBranchAddress("mgo_energy",&mgo_energy);
T->SetBranchAddress("mgo_max_energy",&mgo_max_energy);
T->SetBranchAddress("mgo_total_energy",&mgo_total_energy);
T->SetBranchAddress("mgo_n_showers",&mgo_n_showers);
T->SetBranchAddress("mgo_max_energy_1",&mgo_max_energy_1);
T->SetBranchAddress("mgo_max_energy_2",&mgo_max_energy_2);
T->SetBranchAddress("mgo_total_other_energy",&mgo_total_other_energy);
T->SetBranchAddress("mgo_n_total_showers",&mgo_n_total_showers);
T->SetBranchAddress("mgo_total_other_energy_1",&mgo_total_other_energy_1);
T->SetBranchAddress("mgt_flag",&mgt_flag);
T->SetBranchAddress("mgt_flag_single_shower",&mgt_flag_single_shower);
T->SetBranchAddress("mgt_max_energy",&mgt_max_energy);
T->SetBranchAddress("mgt_total_other_energy",&mgt_total_other_energy);
T->SetBranchAddress("mgt_max_energy_1",&mgt_max_energy_1);
T->SetBranchAddress("mgt_e_indirect_max_energy",&mgt_e_indirect_max_energy);
T->SetBranchAddress("mgt_e_direct_max_energy",&mgt_e_direct_max_energy);
T->SetBranchAddress("mgt_n_direct_showers",&mgt_n_direct_showers);
T->SetBranchAddress("mgt_e_direct_total_energy",&mgt_e_direct_total_energy);
T->SetBranchAddress("mgt_flag_indirect_max_pio",&mgt_flag_indirect_max_pio);
T->SetBranchAddress("mgt_e_indirect_total_energy",&mgt_e_indirect_total_energy);
// br1
int br1_flag;
int br1_1_shower_type;
int br1_1_vtx_n_segs;
double br1_1_energy;
int br1_1_n_segs;
int br1_1_flag_sg_topology;
int br1_1_flag_sg_trajectory;
double br1_1_sg_length;
int br1_2_n_connected;
double br1_2_max_length;
int br1_2_n_connected_1;
int br1_2_n_shower_segs;
double br1_2_max_length_ratio;
double br1_2_shower_length;
int br1_3_n_connected_p;
double br1_3_max_length_p;
int br1_3_n_shower_main_segs;
T->SetBranchAddress("br1_flag",&br1_flag);
T->SetBranchAddress("br1_1_shower_type",&br1_1_shower_type);
T->SetBranchAddress("br1_1_vtx_n_segs",&br1_1_vtx_n_segs);
T->SetBranchAddress("br1_1_energy",&br1_1_energy);
T->SetBranchAddress("br1_1_n_segs",&br1_1_n_segs);
T->SetBranchAddress("br1_1_flag_sg_topology",&br1_1_flag_sg_topology);
T->SetBranchAddress("br1_1_flag_sg_trajectory",&br1_1_flag_sg_trajectory);
T->SetBranchAddress("br1_1_sg_length",&br1_1_sg_length);
T->SetBranchAddress("br1_2_n_connected",&br1_2_n_connected);
T->SetBranchAddress("br1_2_max_length",&br1_2_max_length);
T->SetBranchAddress("br1_2_n_connected_1",&br1_2_n_connected_1);
T->SetBranchAddress("br1_2_n_shower_segs",&br1_2_n_shower_segs);
T->SetBranchAddress("br1_2_max_length_ratio",&br1_2_max_length_ratio);
T->SetBranchAddress("br1_2_shower_length",&br1_2_shower_length);
T->SetBranchAddress("br1_3_n_connected_p",&br1_3_n_connected_p);
T->SetBranchAddress("br1_3_max_length_p",&br1_3_max_length_p);
T->SetBranchAddress("br1_3_n_shower_main_segs",&br1_3_n_shower_main_segs);
// stem_dir_br2 merge
int stem_dir_flag;
int stem_dir_flag_single_shower;
double stem_dir_angle;
double stem_dir_energy;
double stem_dir_angle1;
double stem_dir_angle2;
double stem_dir_angle3;
double stem_dir_ratio;
int br2_flag;
int br2_num_valid_tracks;
int br2_n_shower_main_segs;
double br2_max_angle;
double br2_sg_length;
int br2_flag_sg_trajectory;
T->SetBranchAddress("stem_dir_flag",&stem_dir_flag);
T->SetBranchAddress("stem_dir_flag_single_shower",&stem_dir_flag_single_shower);
T->SetBranchAddress("stem_dir_angle",&stem_dir_angle);
T->SetBranchAddress("stem_dir_energy",&stem_dir_energy);
T->SetBranchAddress("stem_dir_angle1",&stem_dir_angle1);
T->SetBranchAddress("stem_dir_angle2",&stem_dir_angle2);
T->SetBranchAddress("stem_dir_angle3",&stem_dir_angle3);
T->SetBranchAddress("stem_dir_ratio",&stem_dir_ratio);
T->SetBranchAddress("br2_flag",&br2_flag);
T->SetBranchAddress("br2_num_valid_tracks",&br2_num_valid_tracks);
T->SetBranchAddress("br2_n_shower_main_segs",&br2_n_shower_main_segs);
T->SetBranchAddress("br2_max_angle",&br2_max_angle);
T->SetBranchAddress("br2_sg_length",&br2_sg_length);
T->SetBranchAddress("br2_flag_sg_trajectory",&br2_flag_sg_trajectory);
// stem length, low energy michel, broken muon
int stem_len_flag;
double stem_len_energy;
double stem_len_length;
int stem_len_flag_avoid_muon_check;
int stem_len_num_daughters;
double stem_len_daughter_length;
int brm_flag;
int brm_n_mu_segs;
double brm_Ep;
double brm_acc_length;
double brm_shower_total_length;
double brm_connected_length;
int brm_n_size;
double brm_acc_direct_length;
int brm_n_shower_main_segs;
int brm_n_mu_main;
int lem_flag;
double lem_shower_main_length;
int lem_n_3seg;
double lem_e_charge;
double lem_e_dQdx;
int lem_shower_num_main_segs;
T->SetBranchAddress("stem_len_flag", &stem_len_flag);
T->SetBranchAddress("stem_len_energy", &stem_len_energy);
T->SetBranchAddress("stem_len_length", &stem_len_length);
T->SetBranchAddress("stem_len_flag_avoid_muon_check", &stem_len_flag_avoid_muon_check);
T->SetBranchAddress("stem_len_num_daughters", &stem_len_num_daughters);
T->SetBranchAddress("stem_len_daughter_length", &stem_len_daughter_length);
T->SetBranchAddress("brm_n_flag",&brm_flag);
T->SetBranchAddress("brm_n_mu_segs",&brm_n_mu_segs);
T->SetBranchAddress("brm_Ep",&brm_Ep);
T->SetBranchAddress("brm_acc_length",&brm_acc_length);
T->SetBranchAddress("brm_shower_total_length",&brm_shower_total_length);
T->SetBranchAddress("brm_connected_length",&brm_connected_length);
T->SetBranchAddress("brm_n_size",&brm_n_size);
T->SetBranchAddress("brm_nacc_direct_length",&brm_acc_direct_length);
T->SetBranchAddress("brm_n_shower_main_segs",&brm_n_shower_main_segs);
T->SetBranchAddress("brm_n_mu_main",&brm_n_mu_main);
T->SetBranchAddress("lem_flag",&lem_flag);
T->SetBranchAddress("lem_shower_main_length",&lem_shower_main_length);
T->SetBranchAddress("lem_n_3seg",&lem_n_3seg);
T->SetBranchAddress("lem_e_charge",&lem_e_charge);
T->SetBranchAddress("lem_e_dQdx",&lem_e_dQdx);
T->SetBranchAddress("lem_shower_num_main_segs",&lem_shower_num_main_segs);
// br4 + tro single input variables
int br4_flag;
double br4_1_shower_main_length;
double br4_1_shower_total_length;
double br4_1_min_dis;
double br4_1_energy;
int br4_1_flag_avoid_muon_check;
int br4_1_n_vtx_segs;
int br4_1_n_main_segs;
double br4_2_ratio_45;
double br4_2_ratio_35;
double br4_2_ratio_25;
double br4_2_ratio_15;
double br4_2_ratio1_45;
double br4_2_ratio1_35;
double br4_2_ratio1_25;
double br4_2_ratio1_15;
double br4_2_iso_angle;
double br4_2_iso_angle1;
double br4_2_angle;
int tro_3_flag;
double tro_3_stem_length;
int tro_3_n_muon_segs;
double tro_3_energy;
T->SetBranchAddress("tro_3_flag",&tro_3_flag);
T->SetBranchAddress("tro_3_stem_length",&tro_3_stem_length);
T->SetBranchAddress("tro_3_n_muon_segs",&tro_3_n_muon_segs);
T->SetBranchAddress("tro_3_energy",&tro_3_energy);
T->SetBranchAddress("br4_flag", &br4_flag);
T->SetBranchAddress("br4_1_shower_main_length", &br4_1_shower_main_length);
T->SetBranchAddress("br4_1_shower_total_length", &br4_1_shower_total_length);
T->SetBranchAddress("br4_1_min_dis", &br4_1_min_dis);
T->SetBranchAddress("br4_1_energy", &br4_1_energy);
T->SetBranchAddress("br4_1_flag_avoid_muon_check", &br4_1_flag_avoid_muon_check);
T->SetBranchAddress("br4_1_n_vtx_segs", &br4_1_n_vtx_segs);
T->SetBranchAddress("br4_1_br4_1_n_main_segs", &br4_1_n_main_segs);
T->SetBranchAddress("br4_2_ratio_45", &br4_2_ratio_45);
T->SetBranchAddress("br4_2_ratio_35", &br4_2_ratio_35);
T->SetBranchAddress("br4_2_ratio_25", &br4_2_ratio_25);
T->SetBranchAddress("br4_2_ratio_15", &br4_2_ratio_15);
T->SetBranchAddress("br4_2_ratio1_45", &br4_2_ratio1_45);
T->SetBranchAddress("br4_2_ratio1_35", &br4_2_ratio1_35);
T->SetBranchAddress("br4_2_ratio1_25", &br4_2_ratio1_25);
T->SetBranchAddress("br4_2_ratio1_15", &br4_2_ratio1_15);
T->SetBranchAddress("br4_2_iso_angle", &br4_2_iso_angle);
T->SetBranchAddress("br4_2_iso_angle1", &br4_2_iso_angle1);
T->SetBranchAddress("br4_2_angle", &br4_2_angle);
//mip quality
int mip_quality_flag;
int mip_quality_filled;
double mip_quality_energy;
int mip_quality_overlap;
int mip_quality_n_showers;
int mip_quality_n_tracks;
int mip_quality_flag_inside_pi0;
int mip_quality_n_pi0_showers;
double mip_quality_shortest_length;
double mip_quality_acc_length;
double mip_quality_shortest_angle;
int mip_quality_flag_proton;
T->SetBranchAddress("mip_quality_flag",&mip_quality_flag);
T->SetBranchAddress("mip_quality_filled",&mip_quality_filled);
T->SetBranchAddress("mip_quality_energy",&mip_quality_energy);
T->SetBranchAddress("mip_quality_overlap",&mip_quality_overlap);
T->SetBranchAddress("mip_quality_n_showers",&mip_quality_n_showers);
T->SetBranchAddress("mip_quality_n_tracks",&mip_quality_n_tracks);
T->SetBranchAddress("mip_quality_flag_inside_pi0",&mip_quality_flag_inside_pi0);
T->SetBranchAddress("mip_quality_n_pi0_showers",&mip_quality_n_pi0_showers);
T->SetBranchAddress("mip_quality_shortest_length",&mip_quality_shortest_length);
T->SetBranchAddress("mip_quality_acc_length",&mip_quality_acc_length);
T->SetBranchAddress("mip_quality_shortest_angle",&mip_quality_shortest_angle);
T->SetBranchAddress("mip_quality_flag_proton",&mip_quality_flag_proton);
// pio tagger1
int pio_flag;
int pio_filled;
int pio_mip_id;
int pio_flag_pio;
int pio_1_flag;
double pio_1_mass;
int pio_1_pio_type;
double pio_1_energy_1;
double pio_1_energy_2;
double pio_1_dis_1;
double pio_1_dis_2;
T->SetBranchAddress("pio_flag",&pio_flag);
T->SetBranchAddress("pio_filled",&pio_filled);
T->SetBranchAddress("pio_mip_id",&pio_mip_id);
T->SetBranchAddress("pio_flag_pio",&pio_flag_pio);
T->SetBranchAddress("pio_1_flag",&pio_1_flag);
T->SetBranchAddress("pio_1_mass",&pio_1_mass);
T->SetBranchAddress("pio_1_pio_type",&pio_1_pio_type);
T->SetBranchAddress("pio_1_energy_1",&pio_1_energy_1);
T->SetBranchAddress("pio_1_energy_2",&pio_1_energy_2);
T->SetBranchAddress("pio_1_dis_1",&pio_1_dis_1);
T->SetBranchAddress("pio_1_dis_2",&pio_1_dis_2);
// pio tagger 2
// share flags with pio tagger 1
std::vector<double> *pio_2_v_dis2 = new std::vector<double>;
std::vector<double> *pio_2_v_angle2 = new std::vector<double>;
std::vector<double> *pio_2_v_acc_length = new std::vector<double>;
std::vector<int> *pio_2_v_flag = new std::vector<int>;
T->SetBranchAddress("pio_2_v_dis2",&pio_2_v_dis2);
T->SetBranchAddress("pio_2_v_angle2",&pio_2_v_angle2);
T->SetBranchAddress("pio_2_v_acc_length",&pio_2_v_acc_length);
T->SetBranchAddress("pio_2_v_flag",&pio_2_v_flag);
// stw + spt for single gamma
int stw_1_flag;
double stw_1_energy;
double stw_1_dis;
double stw_1_dQ_dx;
int stw_1_flag_single_shower;
int stw_1_n_pi0;
int stw_1_num_valid_tracks;
int spt_flag;
int spt_flag_single_shower;
double spt_shower_main_length;
double spt_shower_total_length;
double spt_angle_beam;
double spt_angle_vertical;
double spt_max_dQ_dx;
double spt_angle_beam_1;
double spt_angle_drift;
double spt_angle_drift_1;
int spt_num_valid_tracks;
double spt_n_vtx_segs;
double spt_max_length;
T->SetBranchAddress("stw_1_flag",&stw_1_flag);
T->SetBranchAddress("stw_1_energy",&stw_1_energy);
T->SetBranchAddress("stw_1_dis",&stw_1_dis);
T->SetBranchAddress("stw_1_dQ_dx",&stw_1_dQ_dx);
T->SetBranchAddress("stw_1_flag_single_shower",&stw_1_flag_single_shower);
T->SetBranchAddress("stw_1_n_pi0",&stw_1_n_pi0);
T->SetBranchAddress("stw_1_num_valid_tracks",&stw_1_num_valid_tracks);
T->SetBranchAddress("spt_flag", &spt_flag);
T->SetBranchAddress("spt_flag_single_shower", &spt_flag_single_shower);
T->SetBranchAddress("spt_shower_main_length", &spt_shower_main_length);
T->SetBranchAddress("spt_shower_total_length", &spt_shower_total_length);
T->SetBranchAddress("spt_angle_beam", &spt_angle_beam);
T->SetBranchAddress("spt_angle_vertical", &spt_angle_vertical);
T->SetBranchAddress("spt_max_dQ_dx", &spt_max_dQ_dx);
T->SetBranchAddress("spt_angle_beam_1", &spt_angle_beam_1);
T->SetBranchAddress("spt_angle_drift", &spt_angle_drift);
T->SetBranchAddress("spt_angle_drift_1", &spt_angle_drift_1);
T->SetBranchAddress("spt_num_valid_tracks", &spt_num_valid_tracks);
T->SetBranchAddress("spt_n_vtx_segs", &spt_n_vtx_segs);
T->SetBranchAddress("spt_max_length", &spt_max_length);
// vis tagger 1
int vis_1_flag;
int vis_1_filled;
int vis_1_n_vtx_segs;
double vis_1_energy;
int vis_1_num_good_tracks;
double vis_1_max_angle;
double vis_1_max_shower_angle;
double vis_1_tmp_length1;
double vis_1_tmp_length2;
double vis_1_particle_type;
T->SetBranchAddress("vis_1_flag",&vis_1_flag);
T->SetBranchAddress("vis_1_filled",&vis_1_filled);
T->SetBranchAddress("vis_1_n_vtx_segs",&vis_1_n_vtx_segs);
T->SetBranchAddress("vis_1_energy",&vis_1_energy);
T->SetBranchAddress("vis_1_num_good_tracks",&vis_1_num_good_tracks);
T->SetBranchAddress("vis_1_max_angle",&vis_1_max_angle);
T->SetBranchAddress("vis_1_max_shower_angle",&vis_1_max_shower_angle);
T->SetBranchAddress("vis_1_tmp_length1",&vis_1_tmp_length1);
T->SetBranchAddress("vis_1_tmp_length2",&vis_1_tmp_length2);
T->SetBranchAddress("vis_1_particle_type",&vis_1_particle_type);
// vis tagger 2
int vis_2_flag;
int vis_2_filled;
int vis_2_n_vtx_segs;
double vis_2_min_angle;
int vis_2_min_weak_track;
double vis_2_angle_beam;
double vis_2_min_angle1;
double vis_2_iso_angle1;
double vis_2_min_medium_dQ_dx;
double vis_2_min_length;
double vis_2_sg_length;
double vis_2_max_angle;
int vis_2_max_weak_track;
T->SetBranchAddress("vis_2_flab",&vis_2_flag);
T->SetBranchAddress("vis_2_filled",&vis_2_filled);
T->SetBranchAddress("vis_2_n_vtx_segs",&vis_2_n_vtx_segs);
T->SetBranchAddress("vis_2_min_angle",&vis_2_min_angle);
T->SetBranchAddress("vis_2_min_weak_track",&vis_2_min_weak_track);
T->SetBranchAddress("vis_2_angle_beam",&vis_2_angle_beam);
T->SetBranchAddress("vis_2_min_angle1",&vis_2_min_angle1);
T->SetBranchAddress("vis_2_iso_angle1",&vis_2_iso_angle1);
T->SetBranchAddress("vis_2_min_medium_dQ_dx",&vis_2_min_medium_dQ_dx);
T->SetBranchAddress("vis_2_min_length",&vis_2_min_length);
T->SetBranchAddress("vis_2_sg_length",&vis_2_sg_length);
T->SetBranchAddress("vis_2_max_angle",&vis_2_max_angle);
T->SetBranchAddress("vis_2_max_weak_track",&vis_2_max_weak_track);
// stw tagger 2
std::vector<int> *stw_2_v_flag = new std::vector<int>;
std::vector<double> *stw_2_v_medium_dQ_dx = new std::vector<double>;
std::vector<double> *stw_2_v_energy = new std::vector<double>;
std::vector<double> *stw_2_v_angle = new std::vector<double>;
std::vector<double> *stw_2_v_dir_length = new std::vector<double>;
std::vector<double> *stw_2_v_max_dQ_dx = new std::vector<double>;
T->SetBranchAddress("stw_2_v_flag", &stw_2_v_flag);
T->SetBranchAddress("stw_2_v_medium_dQ_dx", &stw_2_v_medium_dQ_dx);
T->SetBranchAddress("stw_2_v_energy", &stw_2_v_energy);
T->SetBranchAddress("stw_2_v_angle", &stw_2_v_angle);
T->SetBranchAddress("stw_2_v_dir_length", &stw_2_v_dir_length);
T->SetBranchAddress("stw_2_v_max_dQ_dx", &stw_2_v_max_dQ_dx);
// stw tagger 3
std::vector<int> *stw_3_v_flag = new std::vector<int>;
std::vector<double> *stw_3_v_angle = new std::vector<double>;
std::vector<double> *stw_3_v_dir_length = new std::vector<double>;
std::vector<double> *stw_3_v_energy = new std::vector<double>;
std::vector<double> *stw_3_v_medium_dQ_dx = new std::vector<double>;
T->SetBranchAddress("stw_3_v_flag",&stw_3_v_flag);
T->SetBranchAddress("stw_3_v_angle",&stw_3_v_angle);
T->SetBranchAddress("stw_3_v_dir_length",&stw_3_v_dir_length);
T->SetBranchAddress("stw_3_v_energy",&stw_3_v_energy);
T->SetBranchAddress("stw_3_v_medium_dQ_dx",&stw_3_v_medium_dQ_dx);
// stw tagger 4
std::vector<int> *stw_4_v_flag = new std::vector<int>;
std::vector<double> *stw_4_v_angle = new std::vector<double>;
std::vector<double> *stw_4_v_dis = new std::vector<double>;
std::vector<double> *stw_4_v_energy = new std::vector<double>;
T->SetBranchAddress("stw_4_v_flag",&stw_4_v_flag);
T->SetBranchAddress("stw_4_v_angle",&stw_4_v_angle);
T->SetBranchAddress("stw_4_v_dis",&stw_4_v_dis);
T->SetBranchAddress("stw_4_v_energy",&stw_4_v_energy);
// sig tagger 1
std::vector<int> *sig_1_v_flag= new std::vector<int>;
std::vector<double> *sig_1_v_angle = new std::vector<double>;
std::vector<int> *sig_1_v_flag_single_shower= new std::vector<int>;
std::vector<double> *sig_1_v_energy= new std::vector<double>;
std::vector<double> *sig_1_v_energy_1= new std::vector<double>;
T->SetBranchAddress("sig_1_v_flag",&sig_1_v_flag);
T->SetBranchAddress("sig_1_v_angle",&sig_1_v_angle);
T->SetBranchAddress("sig_1_v_flag_single_shower",&sig_1_v_flag_single_shower);
T->SetBranchAddress("sig_1_v_energy",&sig_1_v_energy);
T->SetBranchAddress("sig_1_v_energy_1",&sig_1_v_energy_1);
// sig tagger 2
std::vector<int> *sig_2_v_flag= new std::vector<int>;
std::vector<double> *sig_2_v_energy= new std::vector<double>;
std::vector<double> *sig_2_v_shower_angle= new std::vector<double>;
std::vector<int> *sig_2_v_flag_single_shower= new std::vector<int>;
std::vector<double> *sig_2_v_medium_dQ_dx= new std::vector<double>;
std::vector<double> *sig_2_v_start_dQ_dx= new std::vector<double>;
T->SetBranchAddress("sig_2_v_flag",&sig_2_v_flag);
T->SetBranchAddress("sig_2_v_energy",&sig_2_v_energy);
T->SetBranchAddress("sig_2_v_shower_angle",&sig_2_v_shower_angle);
T->SetBranchAddress("sig_2_v_flag_single_shower",&sig_2_v_flag_single_shower);
T->SetBranchAddress("sig_2_v_medium_dQ_dx",&sig_2_v_medium_dQ_dx);
T->SetBranchAddress("sig_2_v_start_dQ_dx",&sig_2_v_start_dQ_dx);
// br3 scalar
int br3_1_flag;
double br3_1_energy;
int br3_1_n_shower_segments;
int br3_1_sg_flag_trajectory;
double br3_1_sg_direct_length;
double br3_1_sg_length;
double br3_1_total_main_length;
double br3_1_total_length;
double br3_1_iso_angle;
int br3_1_sg_flag_topology;
int br3_2_flag;
int br3_2_n_ele;
int br3_2_n_other;
int br3_2_other_fid;
int br3_4_flag;
double br3_4_acc_length;
double br3_4_total_length;
int br3_7_flag;
double br3_7_min_angle;
int br3_8_flag;
double br3_8_max_dQ_dx;
int br3_8_n_main_segs;
T->SetBranchAddress("br3_1_flag",&br3_1_flag);
T->SetBranchAddress("br3_1_energy",&br3_1_energy);
T->SetBranchAddress("br3_1_n_shower_segments",&br3_1_n_shower_segments);
T->SetBranchAddress("br3_1_sg_flag_trajectory",&br3_1_sg_flag_trajectory);
T->SetBranchAddress("br3_1_sg_direct_length",&br3_1_sg_direct_length);
T->SetBranchAddress("br3_1_sg_length",&br3_1_sg_length);
T->SetBranchAddress("br3_1_total_main_length",&br3_1_total_main_length);
T->SetBranchAddress("br3_1_total_length",&br3_1_total_length);
T->SetBranchAddress("br3_1_iso_angle",&br3_1_iso_angle);
T->SetBranchAddress("br3_1_sg_flag_topology",&br3_1_sg_flag_topology);
T->SetBranchAddress("br3_2_flag",&br3_2_flag);
T->SetBranchAddress("br3_2_n_ele",&br3_2_n_ele);
T->SetBranchAddress("br3_2_n_other",&br3_2_n_other);
T->SetBranchAddress("br3_2_other_fid",&br3_2_other_fid);
T->SetBranchAddress("br3_4_flag", &br3_4_flag);
T->SetBranchAddress("br3_4_acc_length", &br3_4_acc_length);
T->SetBranchAddress("br3_4_total_length", &br3_4_total_length);
T->SetBranchAddress("br3_7_flag",&br3_7_flag);
T->SetBranchAddress("br3_7_min_angle",&br3_7_min_angle);
T->SetBranchAddress("br3_8_flag",&br3_8_flag);
T->SetBranchAddress("br3_8_max_dQ_dx",&br3_8_max_dQ_dx);
T->SetBranchAddress("br3_8_n_main_segs",&br3_8_n_main_segs);
// br3 tagger 3
std::vector<int> *br3_3_v_flag = new std::vector<int>;
std::vector<double> *br3_3_v_energy = new std::vector<double>;
std::vector<double> *br3_3_v_angle = new std::vector<double>;
std::vector<double> *br3_3_v_dir_length = new std::vector<double>;
std::vector<double> *br3_3_v_length = new std::vector<double>;
T->SetBranchAddress("br3_3_v_flag",&br3_3_v_flag);
T->SetBranchAddress("br3_3_v_energy",&br3_3_v_energy);
T->SetBranchAddress("br3_3_v_angle",&br3_3_v_angle);
T->SetBranchAddress("br3_3_v_dir_length",&br3_3_v_dir_length);
T->SetBranchAddress("br3_3_v_length",&br3_3_v_length);
// br3 tagger 5
std::vector<int> *br3_5_v_flag = new std::vector<int>;
std::vector<double> *br3_5_v_dir_length = new std::vector<double>;
std::vector<double> *br3_5_v_total_length = new std::vector<double>;
std::vector<int> *br3_5_v_flag_avoid_muon_check = new std::vector<int>;
std::vector<int> *br3_5_v_n_seg = new std::vector<int>;
std::vector<double> *br3_5_v_angle = new std::vector<double>;
std::vector<double> *br3_5_v_sg_length = new std::vector<double>;
std::vector<double> *br3_5_v_energy = new std::vector<double>;
std::vector<int> *br3_5_v_n_main_segs = new std::vector<int>;
std::vector<int> *br3_5_v_n_segs = new std::vector<int>;
std::vector<double> *br3_5_v_shower_main_length = new std::vector<double>;
std::vector<double> *br3_5_v_shower_total_length = new std::vector<double>;
T->SetBranchAddress("br3_5_v_flag", &br3_5_v_flag);
T->SetBranchAddress("br3_5_v_dir_length", &br3_5_v_dir_length);
T->SetBranchAddress("br3_5_v_total_length", &br3_5_v_total_length);
T->SetBranchAddress("br3_5_v_flag_avoid_muon_check", &br3_5_v_flag_avoid_muon_check);
T->SetBranchAddress("br3_5_v_n_seg", &br3_5_v_n_seg);
T->SetBranchAddress("br3_5_v_angle", &br3_5_v_angle);
T->SetBranchAddress("br3_5_v_sg_length", &br3_5_v_sg_length);
T->SetBranchAddress("br3_5_v_energy", &br3_5_v_energy);
T->SetBranchAddress("br3_5_v_n_main_segs", &br3_5_v_n_main_segs);
T->SetBranchAddress("br3_5_v_n_segs", &br3_5_v_n_segs);
T->SetBranchAddress("br3_5_v_shower_main_length", &br3_5_v_shower_main_length);
T->SetBranchAddress("br3_5_v_shower_total_length", &br3_5_v_shower_total_length);
//br3 tagger 6
std::vector<int> *br3_6_v_flag = new std::vector<int>;
std::vector<double> *br3_6_v_angle = new std::vector<double>;
std::vector<double> *br3_6_v_angle1 = new std::vector<double>;
std::vector<int> *br3_6_v_flag_shower_trajectory = new std::vector<int>;
std::vector<double> *br3_6_v_direct_length = new std::vector<double>;
std::vector<double> *br3_6_v_length = new std::vector<double>;
std::vector<int> *br3_6_v_n_other_vtx_segs = new std::vector<int>;
std::vector<double> *br3_6_v_energy = new std::vector<double>;
T->SetBranchAddress("br3_6_v_flag",&br3_6_v_flag);
T->SetBranchAddress("br3_6_v_angle",&br3_6_v_angle);
T->SetBranchAddress("br3_6_v_angle1",&br3_6_v_angle1);
T->SetBranchAddress("br3_6_v_flag_shower_trajectory",&br3_6_v_flag_shower_trajectory);
T->SetBranchAddress("br3_6_v_direct_length",&br3_6_v_direct_length);
T->SetBranchAddress("br3_6_v_length",&br3_6_v_length);
T->SetBranchAddress("br3_6_v_n_other_vtx_segs",&br3_6_v_n_other_vtx_segs);
T->SetBranchAddress("br3_6_v_energy",&br3_6_v_energy);
// hol + lol merge
int hol_1_n_valid_tracks;
double hol_1_min_angle;
double hol_1_energy;
int hol_1_flag_all_shower;
double hol_1_min_length;
int hol_1_flag;
double hol_2_min_angle;
double hol_2_medium_dQ_dx;
int hol_2_ncount;
int hol_2_flag;
double lol_3_angle_beam;
int lol_3_n_valid_tracks;
double lol_3_min_angle;
int lol_3_vtx_n_segs;
double lol_3_shower_main_length;
int lol_3_n_out;
int lol_3_n_sum;
int lol_3_flag;
T->SetBranchAddress("hol_1_flag", &hol_1_flag);
T->SetBranchAddress("hol_1_n_valid_tracks", &hol_1_n_valid_tracks);
T->SetBranchAddress("hol_1_min_angle", &hol_1_min_angle);
T->SetBranchAddress("hol_1_energy", &hol_1_energy);
T->SetBranchAddress("hol_1_all_shower", &hol_1_flag_all_shower);
T->SetBranchAddress("hol_1_min_length", &hol_1_min_length);
T->SetBranchAddress("hol_2_flag", &hol_2_flag);
T->SetBranchAddress("hol_2_min_angle", &hol_2_min_angle);
T->SetBranchAddress("hol_2_medium_dQ_dx", &hol_2_medium_dQ_dx);
T->SetBranchAddress("hol_2_ncount", &hol_2_ncount);
T->SetBranchAddress("lol_3_flag",&lol_3_flag);
T->SetBranchAddress("lol_3_angle_beam",&lol_3_angle_beam);
T->SetBranchAddress("lol_3_n_valid_tracks",&lol_3_n_valid_tracks);
T->SetBranchAddress("lol_3_min_angle",&lol_3_min_angle);
T->SetBranchAddress("lol_3_vtx_n_segs",&lol_3_vtx_n_segs);
T->SetBranchAddress("lol_3_shower_main_length",&lol_3_shower_main_length);
T->SetBranchAddress("lol_3_n_out",&lol_3_n_out);
T->SetBranchAddress("lol_3_n_sum",&lol_3_n_sum);
// lol tagger 1
std::vector<int> *lol_1_v_flag= new std::vector<int>;
std::vector<double> *lol_1_v_energy = new std::vector<double>;
std::vector<int> *lol_1_v_vtx_n_segs= new std::vector<int>;
std::vector<int> *lol_1_v_nseg= new std::vector<int>;
std::vector<double> *lol_1_v_angle= new std::vector<double>;
T->SetBranchAddress("lol_1_v_energy",&lol_1_v_energy);
T->SetBranchAddress("lol_1_v_vtx_n_segs",&lol_1_v_vtx_n_segs);
T->SetBranchAddress("lol_1_v_nseg",&lol_1_v_nseg);
T->SetBranchAddress("lol_1_v_angle",&lol_1_v_angle);
T->SetBranchAddress("lol_1_v_flag",&lol_1_v_flag);
// lol tagger 2
std::vector<double> *lol_2_v_length= new std::vector<double>;
std::vector<double> *lol_2_v_angle= new std::vector<double>;
std::vector<int> *lol_2_v_type= new std::vector<int>;
std::vector<int> *lol_2_v_vtx_n_segs= new std::vector<int>;
std::vector<double> *lol_2_v_energy= new std::vector<double>;
std::vector<double> *lol_2_v_shower_main_length= new std::vector<double>;
std::vector<int> *lol_2_v_flag_dir_weak= new std::vector<int>;
std::vector<int> *lol_2_v_flag = new std::vector<int>;
T->SetBranchAddress("lol_2_v_flag",&lol_2_v_flag);
T->SetBranchAddress("lol_2_v_length",&lol_2_v_length);
T->SetBranchAddress("lol_2_v_angle",&lol_2_v_angle);
T->SetBranchAddress("lol_2_v_type",&lol_2_v_type);
T->SetBranchAddress("lol_2_v_vtx_n_segs",&lol_2_v_vtx_n_segs);
T->SetBranchAddress("lol_2_v_energy",&lol_2_v_energy);
T->SetBranchAddress("lol_2_v_shower_main_length",&lol_2_v_shower_main_length);
T->SetBranchAddress("lol_2_v_flag_dir_weak",&lol_2_v_flag_dir_weak);
// tro tagger 1
std::vector<int> *tro_1_v_particle_type= new std::vector<int>;
std::vector<int> *tro_1_v_flag_dir_weak= new std::vector<int>;
std::vector<double> *tro_1_v_min_dis = new std::vector<double>;
std::vector<double> *tro_1_v_sg1_length = new std::vector<double>;
std::vector<double> *tro_1_v_shower_main_length = new std::vector<double>;
std::vector<int> *tro_1_v_max_n_vtx_segs= new std::vector<int>;
std::vector<double> *tro_1_v_tmp_length = new std::vector<double>;
std::vector<double> *tro_1_v_medium_dQ_dx = new std::vector<double>;
std::vector<double> *tro_1_v_dQ_dx_cut = new std::vector<double>;
std::vector<int> *tro_1_v_flag_shower_topology= new std::vector<int>;
std::vector<int> *tro_1_v_flag= new std::vector<int>;
T->SetBranchAddress("tro_1_v_flag",&tro_1_v_flag);
T->SetBranchAddress("tro_1_v_particle_type",&tro_1_v_particle_type);
T->SetBranchAddress("tro_1_v_flag_dir_weak",&tro_1_v_flag_dir_weak);
T->SetBranchAddress("tro_1_v_min_dis",&tro_1_v_min_dis);
T->SetBranchAddress("tro_1_v_sg1_length",&tro_1_v_sg1_length);
T->SetBranchAddress("tro_1_v_shower_main_length",&tro_1_v_shower_main_length);
T->SetBranchAddress("tro_1_v_max_n_vtx_segs",&tro_1_v_max_n_vtx_segs);
T->SetBranchAddress("tro_1_v_tmp_length",&tro_1_v_tmp_length);
T->SetBranchAddress("tro_1_v_medium_dQ_dx",&tro_1_v_medium_dQ_dx);
T->SetBranchAddress("tro_1_v_dQ_dx_cut",&tro_1_v_dQ_dx_cut);
T->SetBranchAddress("tro_1_v_flag_shower_topology",&tro_1_v_flag_shower_topology);
// tro tagger 2
std::vector<int> *tro_2_v_flag= new std::vector<int>;
std::vector<double> *tro_2_v_energy = new std::vector<double>;
std::vector<double> *tro_2_v_stem_length = new std::vector<double>;
std::vector<double> *tro_2_v_iso_angle = new std::vector<double>;
std::vector<double> *tro_2_v_max_length = new std::vector<double>;
std::vector<double> *tro_2_v_angle = new std::vector<double>;
T->SetBranchAddress("tro_2_v_flag",&tro_2_v_flag);
T->SetBranchAddress("tro_2_v_energy",&tro_2_v_energy);
T->SetBranchAddress("tro_2_v_stem_length",&tro_2_v_stem_length);
T->SetBranchAddress("tro_2_v_iso_angle",&tro_2_v_iso_angle);
T->SetBranchAddress("tro_2_v_max_length",&tro_2_v_max_length);
T->SetBranchAddress("tro_2_v_angle",&tro_2_v_angle);
// tro tagger 4
std::vector<int> *tro_4_v_flag= new std::vector<int>;
std::vector<double> *tro_4_v_dir2_mag = new std::vector<double>;
std::vector<double> *tro_4_v_angle = new std::vector<double>;
std::vector<double> *tro_4_v_angle1 = new std::vector<double>;
std::vector<double> *tro_4_v_angle2 = new std::vector<double>;
std::vector<double> *tro_4_v_length = new std::vector<double>;
std::vector<double> *tro_4_v_length1 = new std::vector<double>;
std::vector<double> *tro_4_v_medium_dQ_dx = new std::vector<double>;
std::vector<double> *tro_4_v_end_dQ_dx = new std::vector<double>;
std::vector<double> *tro_4_v_energy = new std::vector<double>;
std::vector<double> *tro_4_v_shower_main_length = new std::vector<double>;
std::vector<int> *tro_4_v_flag_shower_trajectory= new std::vector<int>;
T->SetBranchAddress("tro_4_v_flag",&tro_4_v_flag);
T->SetBranchAddress("tro_4_v_dir2_mag",&tro_4_v_dir2_mag);
T->SetBranchAddress("tro_4_v_angle",&tro_4_v_angle);
T->SetBranchAddress("tro_4_v_angle1",&tro_4_v_angle1);
T->SetBranchAddress("tro_4_v_angle2",&tro_4_v_angle2);
T->SetBranchAddress("tro_4_v_length",&tro_4_v_length);
T->SetBranchAddress("tro_4_v_length1",&tro_4_v_length1);
T->SetBranchAddress("tro_4_v_medium_dQ_dx",&tro_4_v_medium_dQ_dx);
T->SetBranchAddress("tro_4_v_end_dQ_dx",&tro_4_v_end_dQ_dx);
T->SetBranchAddress("tro_4_v_energy",&tro_4_v_energy);
T->SetBranchAddress("tro_4_v_shower_main_length",&tro_4_v_shower_main_length);
T->SetBranchAddress("tro_4_v_flag_shower_trajectory",&tro_4_v_flag_shower_trajectory);
// tro tagger 5
std::vector<int> *tro_5_v_flag = new std::vector<int>;
std::vector<double> *tro_5_v_max_angle = new std::vector<double>;
std::vector<double> *tro_5_v_min_angle = new std::vector<double>;
std::vector<double> *tro_5_v_max_length = new std::vector<double>;
std::vector<double> *tro_5_v_iso_angle = new std::vector<double>;
std::vector<int> *tro_5_v_n_vtx_segs= new std::vector<int>;
std::vector<int> *tro_5_v_min_count= new std::vector<int>;
std::vector<int> *tro_5_v_max_count= new std::vector<int>;
std::vector<double> *tro_5_v_energy = new std::vector<double>;
T->SetBranchAddress("tro_5_v_flag",&tro_5_v_flag);
T->SetBranchAddress("tro_5_v_max_angle",&tro_5_v_max_angle);
T->SetBranchAddress("tro_5_v_min_angle",&tro_5_v_min_angle);
T->SetBranchAddress("tro_5_v_max_length",&tro_5_v_max_length);
T->SetBranchAddress("tro_5_v_iso_angle",&tro_5_v_iso_angle);
T->SetBranchAddress("tro_5_v_n_vtx_segs",&tro_5_v_n_vtx_segs);
T->SetBranchAddress("tro_5_v_min_count",&tro_5_v_min_count);
T->SetBranchAddress("tro_5_v_max_count",&tro_5_v_max_count);
T->SetBranchAddress("tro_5_v_energy",&tro_5_v_energy);
/// BDT initilization
//BDT_mipid class_mipid("dataset/mipid_type3_BDT800_5.weights.xml");
BDT_mipid class_mipid("dataset/mipid_BDT.weights.xml");
BDT_gap class_gap("dataset/gap_BDT.weights.xml");
BDT_cme_anc class_cme_anc("dataset/cme_anc_BDT.weights.xml");
BDT_mgo_mgt class_mgo_mgt("dataset/mgo_mgt_BDT.weights.xml");
BDT_br1 class_br1("dataset/br1_BDT.weights.xml");
BDT_br3 class_br3("dataset/br3_BDT.weights.xml");
BDT_br3_3 class_br3_3("dataset/br3_3_BDT.weights.xml");
BDT_br3_5 class_br3_5("dataset/br3_5_BDT.weights.xml");
BDT_br3_6 class_br3_6("dataset/br3_6_BDT.weights.xml");
BDT_hol_lol class_hol_lol("dataset/hol_lol_BDT.weights.xml");
BDT_stemdir_br2 class_stemdir_br2("dataset/stem_dir_br2_BDT.weights.xml");
BDT_trimuon class_trimuon("dataset/stl_lem_brm_BDT.weights.xml");
BDT_br4_tro class_br4_tro("dataset/br4_tro_BDT.weights.xml");
BDT_mipquality class_mipquality("dataset/mipquality_BDT.weights.xml");
BDT_pio_1 class_pio_1("dataset/pio_1_BDT.weights.xml");
BDT_pio_2 class_pio_2("dataset/pio_2_BDT.weights.xml");
BDT_stw_spt class_stw_spt("dataset/stw_spt_BDT.weights.xml");
BDT_vis_1 class_vis_1("dataset/vis_1_BDT.weights.xml");
BDT_vis_2 class_vis_2("dataset/vis_2_BDT.weights.xml");
BDT_stw_2 class_stw_2("dataset/stw_2_BDT.weights.xml");
BDT_stw_3 class_stw_3("dataset/stw_3_BDT.weights.xml");
BDT_stw_4 class_stw_4("dataset/stw_4_BDT.weights.xml");
BDT_sig_1 class_sig_1("dataset/sig_1_BDT.weights.xml");
BDT_sig_2 class_sig_2("dataset/sig_2_BDT.weights.xml");
BDT_lol_1 class_lol_1("dataset/lol_1_BDT.weights.xml");
BDT_lol_2 class_lol_2("dataset/lol_2_BDT.weights.xml");