477 def event(self):
478 """
480 if len(MCPart)>=4:
481 self.eplus_t[0]=Theta_MCTruth(MCPart[2])
482 self.eminus_t[0]=Theta_MCTruth(MCPart[3])
483 if self.eplus_t[0] > self.eminus_t[0]:
484 self.efrd_t[0]=self.eminus_t[0]
485 self.ebkd_t[0]=self.eplus_t[0]
486 else:
487 self.efrd_t[0]=self.eplus_t[0]
488 self.ebkd_t[0]=self.eminus_t[0]
489 count_part = Count_part_inDetector(MCPart)
490 self.n_par_t[0]=count_part[0]
491 self.n_par_t[1]=count_part[1]
492 count_mcpart = Count_mcpart(MCPart)
493 self.n_mcpar_t[0]=count_mcpart[0]
494 self.n_mcpar_t[1]=count_mcpart[1]
495 """
497 self.ntrk_2dfinder_t[0] = len(trk_2d_finder)
499 self.ntrk_2dfitter_t[0] = len(trk_2d_fitter)
501 self.ntrk_3dfitter_t[0] = len(trk_3d_fitter)
503 self.ntrk_NN_t[0] = len(tracks)
504
505
508
509 clusters = Time_Window(clusters_original, eventtime)
510 self.ncluster_t[0] = len(clusters)
511
512 time_clu_list = Time_Cluster(clusters_original, eventtime)
513 for i in range(len(time_clu_list)):
514 if i < 100:
515 self.time_cluster_t[i] = time_clu_list[i]
516
517 clusters_300_cms = Cluster_Threshold(clusters, 0.3, False)
518 clusters_400_cms = Cluster_Threshold(clusters, 0.4, False)
519 clusters_500_cms = Cluster_Threshold(clusters, 0.5, False)
520 clusters_700_cms = Cluster_Threshold(clusters, 0.7, False)
521 clusters_1000_cms = Cluster_Threshold(clusters, 1.0, False)
522 clusters_2000_cms = Cluster_Threshold(clusters, 2.0, False)
523 clusters_2500_cms = Cluster_Threshold(clusters, 2.5, False)
524 self.cpair_t[0] = Back_to_Back(clusters, clusters)
525 self.cpair_t[1] = Back_to_Back(clusters_300_cms, clusters)
526 self.cpair_t[2] = Back_to_Back(clusters_400_cms, clusters)
527 self.cpair_t[3] = Back_to_Back(clusters_500_cms, clusters)
528 self.cpair_t[4] = Back_to_Back(clusters_700_cms, clusters)
529 self.cpair_t[5] = Back_to_Back(clusters_1000_cms, clusters)
530 self.cpair_t[6] = Back_to_Back(clusters_2000_cms, clusters)
531 self.cpair_t[7] = Back_to_Back(clusters_2500_cms, clusters)
532
534 self.ntrk_klm_t[0] = len(klmtrkcol)
536 self.nhit_klm_t[0] = len(klmhitcol)
537
539 self.ntrk_3Dmatch_t[0] = len(matchlist)
540
542 self.npair_tc_t[0] = trginfo.getNbbTrkCluster()
543 self.npair_cc_t[0] = trginfo.getNbbCluster()
544 self.ncluster_1000b_t[0] = trginfo.getNhighcluster2()
545 self.ncluster_2000e_t[0] = trginfo.getNhighcluster4()
546 self.max_deltphi_2dfinder_t[0] = Max_DeltPhi_trk(trk_2d_finder)
547
548 neutral_clusters = NeutralCluster(clusters)
549 self.ncluster_neutral_t[0] = len(neutral_clusters)
550 max_cluster_neu = Max_Cluster(neutral_clusters, 0)
551 max_cluster = Max_Cluster(clusters, 0)
552
553
554 smax_cluster_neu = Max_Cluster(neutral_clusters, 1)
555 smax_cluster = Max_Cluster(clusters, 1)
556
557
558 for i in range(self.ncomp_clu):
559 self.max_cluster_neutral_t[i] = max_cluster_neu[i]
560
561 self.max_cluster_t[i] = max_cluster[i]
562
563 self.smax_cluster_neutral_t[i] = smax_cluster_neu[i]
564
565 self.smax_cluster_t[i] = smax_cluster[i]
566
567
568 self.etot_t[0] = Etot_Cluster(clusters)
569
570
571 bhabhaveto_1 = BhabhaVeto1(matchlist)
572 bha_logic = 0
573 for bha in bhabhaveto_1:
574 if math.fabs(bha[0]) < 50 and math.fabs(bha[0]) > 10 and math.fabs(bha[1]) < 20:
575 if bha[2] > 2.0 and bha[3] > 2.0 and bha[4] > 6.0:
576 if bha[2] > 3.0 or bha[3] > 3.0:
577 if len(trk_2d_finder) == 2:
578 bha_logic = 1
579 self.bhabha_t[0] = bha_logic
580
581 if len(bhabhaveto_1) >= 1:
582 for i in range(self.nbha_var):
583 self.bhabha_var_t[i] = bhabhaveto_1[0][i]
584
585
586 eclbhabhaveto = eclBhabhaVeto(clusters)
587 eclbha_logic = 0
588 for eclbha in eclbhabhaveto:
589 if math.fabs(eclbha[0]) < 50 and math.fabs(eclbha[1]) < 50:
590 if eclbha[2] > 2.0 and eclbha[3] > 2.0 and eclbha[4] > 6.0:
591 if eclbha[2] > 3.0 or eclbha[3] > 3.0:
592 eclbha_logic = 1
593 self.eclbhabha_t[0] = eclbha_logic
594
595
596 sbha_logic = 0
597 if len(trk_2d_finder) == 1:
598 if eclbha_logic == 1:
599 ecol = SBhabhaVeto(matchlist)
600 for i, etr in ecol:
601 if etr[i] > 1.0:
602 sbha_logic = 1
603 self.sbhabha_t[0] = sbha_logic
604
605 self.max_deltphi_cluster_t[0] = Max_DeltPhi_cluster(clusters)
606 if len(eclbhabhaveto) >= 1:
607 for i in range(self.nbha_var):
608 self.eclbhabha_var_t[i] = eclbhabhaveto[0][i]
609 self.tgrl.Fill()
610
A (simplified) python wrapper for StoreArray.
a (simplified) python wrapper for StoreObjPtr.