573 |
// |
// |
574 |
nli->CreateCloneTrees(Target); |
nli->CreateCloneTrees(Target); |
575 |
// |
// |
576 |
nli->GetCloneTree("Tracker")->SetAutoSave(900000000000000LL); |
/* nli->GetCloneTree("Tracker")->SetAutoSave(900000000000000LL); |
577 |
nli->GetCloneTree("Trigger")->SetAutoSave(900000000000000LL); |
nli->GetCloneTree("Trigger")->SetAutoSave(900000000000000LL); |
578 |
nli->GetCloneTree("Calorimeter")->SetAutoSave(900000000000000LL); |
nli->GetCloneTree("Calorimeter")->SetAutoSave(900000000000000LL); |
579 |
nli->GetCloneTree("S4")->SetAutoSave(900000000000000LL); |
nli->GetCloneTree("S4")->SetAutoSave(900000000000000LL); |
581 |
nli->GetCloneTree("NeutronD")->SetAutoSave(900000000000000LL); |
nli->GetCloneTree("NeutronD")->SetAutoSave(900000000000000LL); |
582 |
nli->GetCloneTree("OrbitalInfo")->SetAutoSave(900000000000000LL); |
nli->GetCloneTree("OrbitalInfo")->SetAutoSave(900000000000000LL); |
583 |
nli->GetCloneTree("Run")->SetAutoSave(900000000000000LL); |
nli->GetCloneTree("Run")->SetAutoSave(900000000000000LL); |
584 |
nli->GetCloneTree("ToF")->SetAutoSave(900000000000000LL); |
nli->GetCloneTree("ToF")->SetAutoSave(900000000000000LL);*/ |
585 |
// |
// |
586 |
ULong64_t nevents = nli->GetEntries(); |
ULong64_t nevents = nli->GetEntries(); |
587 |
printf(" NEVENTS %llu \n",nevents); |
printf(" NEVENTS %llu \n",nevents); |
597 |
// Target->Write(); |
// Target->Write(); |
598 |
// TTree *slist = (TTree*)Target->Get("SelectionList"); |
// TTree *slist = (TTree*)Target->Get("SelectionList"); |
599 |
// slist->Delete("all"); |
// slist->Delete("all"); |
600 |
|
if ( !nli->GetCloneTree("ProcessingInfo") ){ |
601 |
|
TChain *P = new TChain("ProcessingInfo"); |
602 |
|
// loop over files and create chains |
603 |
|
TIter next(sourcelist); |
604 |
|
TSystemFile *questo = 0; |
605 |
|
while ((questo = (TSystemFile*) next())) { |
606 |
|
TString name = questo->GetName(); |
607 |
|
P->Add(name); |
608 |
|
} |
609 |
|
if ( P->GetEntries() ){ |
610 |
|
TTree *Pclone = P->CloneTree(); |
611 |
|
|
612 |
|
|
613 |
|
|
614 |
|
ProcInfo *procinfo = new ProcInfo(); |
615 |
|
procinfo->runID = 0; |
616 |
|
TTimeStamp *dt = new TTimeStamp(); |
617 |
|
procinfo->date = dt->AsString(); |
618 |
|
delete dt; |
619 |
|
TString isok; |
620 |
|
if ( nli->HasDiscardedFiles() ){ |
621 |
|
isok = " WARNING, files were discarded while merging! "; |
622 |
|
} else { |
623 |
|
isok = " the level2 merging was OK!"; |
624 |
|
} |
625 |
|
procinfo->commandLine += Form("PadmeAmidala run: %i dir: %s wd %s. %s",run,dir.Data(),wd.Data(),isok.Data()); |
626 |
|
procinfo->outputFilename = Form("%s %s ",outdir.Data(),Target->GetName()); |
627 |
|
procinfo->localDir = gSystem->WorkingDirectory(); |
628 |
|
procinfo->uname = gSystem->GetFromPipe("uname -a"); |
629 |
|
procinfo->DB = Form("Host %s DB %s ",dbc->GetHost(),dbc->GetDB()); |
630 |
|
|
631 |
|
Pclone->SetBranchAddress("ProcInfo",&procinfo); |
632 |
|
Pclone->Fill(); |
633 |
|
|
634 |
|
Target->cd(); |
635 |
|
Pclone->Write("ProcessingInfo",TObject::kOverwrite); |
636 |
|
P->Delete(); |
637 |
|
P=0; |
638 |
|
} |
639 |
|
} |
640 |
|
// |
641 |
Target->Close(); |
Target->Close(); |
642 |
|
|
643 |
// // |
// // |