Home » PANDA » PandaRoot » Fast Simulations » [FIXED] first try with fast simulation problem (error and break and aborting execution)
[FIXED] first try with fast simulation problem [message #16248] |
Tue, 08 April 2014 11:22 |
Alexandros
Messages: 51 Registered: January 2014 Location: KVI
|
continuous participant |
From: *kvi-cart.rug.nl
|
|
Hi,
I am trying my first fast simulation..I am using the /macro/scrut/simfast.C macro...
I have my own decay file, and when I try to run the simulation it goes fine umtil a point...then it crashes..What i get is this:
Loading VGM libraries ...
Loading g4root library ...
Loading libraries ... finished
Error in <TGeoManager::CloseGeometry>: you MUST call SetTopVolume() first !
Error in <TGeoManager::CloseGeometry>: you MUST call SetTopVolume() first !
-------- EEEE ------- G4Exception-START -------- EEEE -------
*** ExceptionHandler is not defined ***
*** G4Exception : G4Root_F001
issued by : TG4RootDetectorConstruction::TG4RootDetectorConstruction
Cannot create TG4RootDetectorConstruction without closed ROOT geometry !
*** Fatal Exception ***
-------- EEEE -------- G4Exception-END --------- EEEE -------
*** G4Exception: Aborting execution ***
Any help???I am doing something wrong but I don't know what...Any ideas???
Thanks
[Updated on: Fri, 12 September 2014 10:35] by Moderator Report message to a moderator
|
|
|
|
|
|
Re: first try with fast simulation problem [message #16254 is a reply to message #16253] |
Tue, 08 April 2014 13:50 |
Alexandros
Messages: 51 Registered: January 2014 Location: KVI
|
continuous participant |
From: *kvi-cart.rug.nl
|
|
===========================================================
There was a crash (#6 0xb71ec24b in SigHandler(ESignals) () from /home/alexandros/external_apr13/install/lib/root/libCore.so.5.34).
This is the entire stack trace of all threads:
===========================================================
#0 0xb777c424 in __kernel_vsyscall ()
#1 0xb6db4253 in __waitpid_nocancel () at ../sysdeps/unix/syscall-template.S:81
#2 0xb6d3ae60 in do_system (line=0xae8fc28 "/home/alexandros/external_apr13/install/etc/gdb-backtrace.sh 12210 1>&2") at ../sysdeps/posix/system.c:148
#3 0xb71e64db in TUnixSystem::Exec(char const*) () from /home/alexandros/external_apr13/install/lib/root/libCore.so.5.34
#4 0xb71ea08a in TUnixSystem::StackTrace() () from /home/alexandros/external_apr13/install/lib/root/libCore.so.5.34
#5 0xb71ec117 in TUnixSystem::DispatchSignals(ESignals) () from /home/alexandros/external_apr13/install/lib/root/libCore.so.5.34
#6 0xb71ec24b in SigHandler(ESignals) () from /home/alexandros/external_apr13/install/lib/root/libCore.so.5.34
#7 0xb71e5952 in sighandler(int) () from /home/alexandros/external_apr13/install/lib/root/libCore.so.5.34
#8 <signal handler called>
#9 0xb361fa08 in phcork (modcor=0) at /home/alexandros/pandaroot/pgenerators/EvtGenNew/Photos/Photos.3.52/src/ photos-fortran/photos.f:2473
#10 0xb361d858 in phoin (ip=1, boost=.FALSE., nhep0=0) at /home/alexandros/pandaroot/pgenerators/EvtGenNew/Photos/Photos.3.52/src/ photos-fortran/photos.f:254
#11 0xb36186c7 in phomak (ippar=1, nhep0=0) at /home/alexandros/pandaroot/pgenerators/EvtGenNew/Photos/Photos.3.52/src/ photos-fortran/photos.f:726
#12 0xb362103a in phtype (id=1) at /home/alexandros/pandaroot/pgenerators/EvtGenNew/Photos/Photos.3.52/src/ photos-fortran/photos.f:637
#13 0xb3617d55 in photos_make_c (iparr=1) at /home/alexandros/pandaroot/pgenerators/EvtGenNew/Photos/Photos.3.52/src/ photosFortranInterfaces/Photos_make.f:224
#14 0xb38b6d08 in Photospp::PhotosBranch::process (this=0xa632150) at /home/alexandros/pandaroot/pgenerators/EvtGenNew/Photos/Photos.3.52/src/ photosCInterfaces/PhotosBranch.cxx:71
#15 0xb38bdcc6 in Photospp::PhotosEvent::process (this=0xbfd4ed78) at /home/alexandros/pandaroot/pgenerators/EvtGenNew/Photos/Photos.3.52/src/ photosCInterfaces/PhotosEvent.cxx:28
#16 0xb3917c1f in EvtPhotosEngine::doDecay (this=0x93a6e00, theMother=0xae8f3a8) at /home/alexandros/pandaroot/pgenerators/EvtGenNew/EvtGen/R01-03-00/src/Ev tGenExternal/EvtPhotosEngine.cpp:142
#17 0xb3914b20 in EvtPHOTOS::doRadCorr (this=0x9630ee0, p=0xae8f3a8) at /home/alexandros/pandaroot/pgenerators/EvtGenNew/EvtGen/R01-03-00/src/Ev tGenExternal/EvtPHOTOS.cpp:46
#18 0xb2f3963a in EvtRadCorr::doRadCorr (p=0xae8f3a8) at /home/alexandros/pandaroot/pgenerators/EvtGenNew/EvtGen/R01-03-00/src/Ev tGenBase/EvtRadCorr.cpp:60
#19 0xb2f7e18f in EvtDecayIncoherent::makeDecay (this=0xa0513a0, p=0xae8f3a8, recursive=true) at /home/alexandros/pandaroot/pgenerators/EvtGenNew/EvtGen/R01-03-00/src/Ev tGenBase/EvtDecayIncoherent.cpp:50
#20 0xb2f53ef4 in EvtParticle::decay (this=0xae8f3a8) at /home/alexandros/pandaroot/pgenerators/EvtGenNew/EvtGen/R01-03-00/src/Ev tGenBase/EvtParticle.cpp:454
#21 0xb2f35842 in EvtDecayAmp::makeDecay (this=0x9b2e220, p=0xae8f0b8, recursive=true) at /home/alexandros/pandaroot/pgenerators/EvtGenNew/EvtGen/R01-03-00/src/Ev tGenBase/EvtDecayAmp.cpp:213
#22 0xb2f53ef4 in EvtParticle::decay (this=0xae8f0b8) at /home/alexandros/pandaroot/pgenerators/EvtGenNew/EvtGen/R01-03-00/src/Ev tGenBase/EvtParticle.cpp:454
#23 0xb2ed780d in EvtGen::generateDecay (this=0x96325f8, p=0xae8f0b8) at /home/alexandros/pandaroot/pgenerators/EvtGenNew/EvtGen/R01-03-00/src/Ev tGen.cpp:180
#24 0xb467480c in PndEvtGenDirect::ReadEvent (this=0x96036a0, primGen=0x95fc6e0) at /home/alexandros/pandaroot/pgenerators/EvtGenNew/EvtGenDirect/PndEvtGenD irect.cxx:179
#25 0xb3a25bce in FairPrimaryGenerator::GenerateEvent (this=0x95fc6e0, pStack=0xa4d5db8) at /home/alexandros/pandaroot/base/sim/FairPrimaryGenerator.cxx:163
#26 0xb3a1e10e in FairMCApplication::GeneratePrimaries (this=0x9af8a50) at /home/alexandros/pandaroot/base/sim/FairMCApplication.cxx:778
#27 0xad45953f in gukine_ () from /home/alexandros/external_apr13/install/lib/libgeant321.so
#28 0xad440799 in jumpt0_ () from /home/alexandros/external_apr13/install/lib/libgeant321.so
#29 0xad196f48 in g3trig_ () from /home/alexandros/external_apr13/install/lib/libgeant321.so
#30 0xad44a324 in TGeant3::Gtrig() () from /home/alexandros/external_apr13/install/lib/libgeant321.so
#31 0xad449169 in TGeant3::ProcessEvent() () from /home/alexandros/external_apr13/install/lib/libgeant321.so
#32 0xad44999b in TGeant3::ProcessRun(int) () from /home/alexandros/external_apr13/install/lib/libgeant321.so
#33 0xb3a1b900 in FairMCApplication::RunMC (this=0x9af8a50, nofEvents=1000) at /home/alexandros/pandaroot/base/sim/FairMCApplication.cxx:233
#34 0xb3a0cfa7 in FairRunSim::Run (this=0x9566518, NEvents=1000, NotUsed=0) at /home/alexandros/pandaroot/base/steer/FairRunSim.cxx:351
#35 0xb3a62c63 in G__G__BaseDict_618_0_6 (result7=0xbfd51194, funcname=0x9563eb8 "", libp=0xbfd511bc, hash=0) at /home/alexandros/buildPanda/base/G__BaseDict.cxx:8423
#36 0xb66fc593 in Cint::G__ExceptionWrapper(int (*)(G__value*, char const*, G__param*, int), G__value*, char*, G__param*, int) () from /home/alexandros/external_apr13/install/lib/root/libCint.so.5.34
#37 0xb67abcc7 in G__execute_call () from /home/alexandros/external_apr13/install/lib/root/libCint.so.5.34
#38 0xb67ac0a2 in G__call_cppfunc () from /home/alexandros/external_apr13/install/lib/root/libCint.so.5.34
#39 0xb678753b in G__interpret_func () from /home/alexandros/external_apr13/install/lib/root/libCint.so.5.34
#40 0xb67764ba in G__getfunction () from /home/alexandros/external_apr13/install/lib/root/libCint.so.5.34
#41 0xb686d517 in G__getstructmem(int, G__FastAllocString&, char*, int, char*, int*, G__var_array*, int) () from /home/alexandros/external_apr13/install/lib/root/libCint.so.5.34
#42 0xb6863d17 in G__getvariable () from /home/alexandros/external_apr13/install/lib/root/libCint.so.5.34
#43 0xb674ce1c in G__getitem () from /home/alexandros/external_apr13/install/lib/root/libCint.so.5.34
#44 0xb67529fc in G__getexpr () from /home/alexandros/external_apr13/install/lib/root/libCint.so.5.34
#45 0xb67dfcf1 in G__exec_statement () from /home/alexandros/external_apr13/install/lib/root/libCint.so.5.34
#46 0xb67887e1 in G__interpret_func () from /home/alexandros/external_apr13/install/lib/root/libCint.so.5.34
#47 0xb677652c in G__getfunction () from /home/alexandros/external_apr13/install/lib/root/libCint.so.5.34
#48 0xb674d32e in G__getitem () from /home/alexandros/external_apr13/install/lib/root/libCint.so.5.34
#49 0xb67529fc in G__getexpr () from /home/alexandros/external_apr13/install/lib/root/libCint.so.5.34
#50 0xb67dfcf1 in G__exec_statement () from /home/alexandros/external_apr13/install/lib/root/libCint.so.5.34
#51 0xb673799f in G__exec_tempfile_core () from /home/alexandros/external_apr13/install/lib/root/libCint.so.5.34
#52 0xb6739098 in G__exec_tempfile_fp () from /home/alexandros/external_apr13/install/lib/root/libCint.so.5.34
#53 0xb67edbc4 in G__process_cmd () from /home/alexandros/external_apr13/install/lib/root/libCint.so.5.34
#54 0xb71b1815 in TCint::ProcessLine(char const*, TInterpreter::EErrorCode*) () from /home/alexandros/external_apr13/install/lib/root/libCore.so.5.34
#55 0xb7109571 in TApplication::ProcessLine(char const*, bool, int*) () from /home/alexandros/external_apr13/install/lib/root/libCore.so.5.34
#56 0xb6fd9bae in TRint::HandleTermInput() () from /home/alexandros/external_apr13/install/lib/root/libRint.so.5.34
#57 0xb6fd9292 in TTermInputHandler::Notify() () from /home/alexandros/external_apr13/install/lib/root/libRint.so.5.34
#58 0xb6fdb722 in TTermInputHandler::ReadNotify() () from /home/alexandros/external_apr13/install/lib/root/libRint.so.5.34
#59 0xb71eb79b in TUnixSystem::CheckDescriptors() () from /home/alexandros/external_apr13/install/lib/root/libCore.so.5.34
#60 0xb71ec421 in TUnixSystem::DispatchOneEvent(bool) () from /home/alexandros/external_apr13/install/lib/root/libCore.so.5.34
#61 0xb71682d2 in TSystem::InnerLoop() () from /home/alexandros/external_apr13/install/lib/root/libCore.so.5.34
#62 0xb7169170 in TSystem::Run() () from /home/alexandros/external_apr13/install/lib/root/libCore.so.5.34
#63 0xb7107d52 in TApplication::Run(bool) () from /home/alexandros/external_apr13/install/lib/root/libCore.so.5.34
#64 0xb6fdb0c1 in TRint::Run(bool) () from /home/alexandros/external_apr13/install/lib/root/libRint.so.5.34
#65 0x08048cd0 in main ()
===========================================================
The lines below might hint at the cause of the crash.
If they do not help you then please submit a bug report at
http://root.cern.ch/bugs. Please post the ENTIRE stack trace
from above as an attachment in addition to anything else
that might help us fixing this issue.
===========================================================
#9 0xb361fa08 in phcork (modcor=0) at /home/alexandros/pandaroot/pgenerators/EvtGenNew/Photos/Photos.3.52/src/ photos-fortran/photos.f:2473
#10 0xb361d858 in phoin (ip=1, boost=.FALSE., nhep0=0) at /home/alexandros/pandaroot/pgenerators/EvtGenNew/Photos/Photos.3.52/src/ photos-fortran/photos.f:254
#11 0xb36186c7 in phomak (ippar=1, nhep0=0) at /home/alexandros/pandaroot/pgenerators/EvtGenNew/Photos/Photos.3.52/src/ photos-fortran/photos.f:726
#12 0xb362103a in phtype (id=1) at /home/alexandros/pandaroot/pgenerators/EvtGenNew/Photos/Photos.3.52/src/ photos-fortran/photos.f:637
#13 0xb3617d55 in photos_make_c (iparr=1) at /home/alexandros/pandaroot/pgenerators/EvtGenNew/Photos/Photos.3.52/src/ photosFortranInterfaces/Photos_make.f:224
#14 0xb38b6d08 in Photospp::PhotosBranch::process (this=0xa632150) at /home/alexandros/pandaroot/pgenerators/EvtGenNew/Photos/Photos.3.52/src/ photosCInterfaces/PhotosBranch.cxx:71
#15 0xb38bdcc6 in Photospp::PhotosEvent::process (this=0xbfd4ed78) at /home/alexandros/pandaroot/pgenerators/EvtGenNew/Photos/Photos.3.52/src/ photosCInterfaces/PhotosEvent.cxx:28
#16 0xb3917c1f in EvtPhotosEngine::doDecay (this=0x93a6e00, theMother=0xae8f3a8) at /home/alexandros/pandaroot/pgenerators/EvtGenNew/EvtGen/R01-03-00/src/Ev tGenExternal/EvtPhotosEngine.cpp:142
#17 0xb3914b20 in EvtPHOTOS::doRadCorr (this=0x9630ee0, p=0xae8f3a8) at /home/alexandros/pandaroot/pgenerators/EvtGenNew/EvtGen/R01-03-00/src/Ev tGenExternal/EvtPHOTOS.cpp:46
#18 0xb2f3963a in EvtRadCorr::doRadCorr (p=0xae8f3a8) at /home/alexandros/pandaroot/pgenerators/EvtGenNew/EvtGen/R01-03-00/src/Ev tGenBase/EvtRadCorr.cpp:60
#19 0xb2f7e18f in EvtDecayIncoherent::makeDecay (this=0xa0513a0, p=0xae8f3a8, recursive=true) at /home/alexandros/pandaroot/pgenerators/EvtGenNew/EvtGen/R01-03-00/src/Ev tGenBase/EvtDecayIncoherent.cpp:50
#20 0xb2f53ef4 in EvtParticle::decay (this=0xae8f3a8) at /home/alexandros/pandaroot/pgenerators/EvtGenNew/EvtGen/R01-03-00/src/Ev tGenBase/EvtParticle.cpp:454
#21 0xb2f35842 in EvtDecayAmp::makeDecay (this=0x9b2e220, p=0xae8f0b8, recursive=true) at /home/alexandros/pandaroot/pgenerators/EvtGenNew/EvtGen/R01-03-00/src/Ev tGenBase/EvtDecayAmp.cpp:213
#22 0xb2f53ef4 in EvtParticle::decay (this=0xae8f0b8) at /home/alexandros/pandaroot/pgenerators/EvtGenNew/EvtGen/R01-03-00/src/Ev tGenBase/EvtParticle.cpp:454
#23 0xb2ed780d in EvtGen::generateDecay (this=0x96325f8, p=0xae8f0b8) at /home/alexandros/pandaroot/pgenerators/EvtGenNew/EvtGen/R01-03-00/src/Ev tGen.cpp:180
#24 0xb467480c in PndEvtGenDirect::ReadEvent (this=0x96036a0, primGen=0x95fc6e0) at /home/alexandros/pandaroot/pgenerators/EvtGenNew/EvtGenDirect/PndEvtGenD irect.cxx:179
#25 0xb3a25bce in FairPrimaryGenerator::GenerateEvent (this=0x95fc6e0, pStack=0xa4d5db8) at /home/alexandros/pandaroot/base/sim/FairPrimaryGenerator.cxx:163
#26 0xb3a1e10e in FairMCApplication::GeneratePrimaries (this=0x9af8a50) at /home/alexandros/pandaroot/base/sim/FairMCApplication.cxx:778
#27 0xad45953f in gukine_ () from /home/alexandros/external_apr13/install/lib/libgeant321.so
#28 0xad440799 in jumpt0_ () from /home/alexandros/external_apr13/install/lib/libgeant321.so
#29 0xad196f48 in g3trig_ () from /home/alexandros/external_apr13/install/lib/libgeant321.so
#30 0xad44a324 in TGeant3::Gtrig() () from /home/alexandros/external_apr13/install/lib/libgeant321.so
#31 0xad449169 in TGeant3::ProcessEvent() () from /home/alexandros/external_apr13/install/lib/libgeant321.so
#32 0xad44999b in TGeant3::ProcessRun(int) () from /home/alexandros/external_apr13/install/lib/libgeant321.so
#33 0xb3a1b900 in FairMCApplication::RunMC (this=0x9af8a50, nofEvents=1000) at /home/alexandros/pandaroot/base/sim/FairMCApplication.cxx:233
#34 0xb3a0cfa7 in FairRunSim::Run (this=0x9566518, NEvents=1000, NotUsed=0) at /home/alexandros/pandaroot/base/steer/FairRunSim.cxx:351
===========================================================
Root > Function simfast() busy flag cleared
|
|
|
|
|
|
|
|
|
|
|
|
|
Re: first try with fast simulation problem [message #16277 is a reply to message #16276] |
Wed, 09 April 2014 15:47 |
Alexandros
Messages: 51 Registered: January 2014 Location: KVI
|
continuous participant |
From: *kvi-cart.rug.nl
|
|
The .root file is indeed broken..
If I try file->IsZombie() gives 0 so file is there.
If I try then sile->Recover it says:
"Info in <TFile::Recover>: psi4160_fast.root, recovered key TFolder:cbmroot at address 230
Info in <TFile::Recover>: psi4160_fast.root, recovered key TList:BranchList at address 698
Info in <TFile::Recover>: psi4160_fast.root, recovered key FairFileHeader:FileHeader at address 946
Info in <TFile::Recover>: psi4160_fast.root, recovered key TTree:cbmsim at address 5176972"
Without exiting root I try .L my analysis macro and then I call the function I have.
My macro is like I said before:
void psi4160at8Gev1000eventsAnalysis(int nevts=0)
{
// some variables
int i=0,j=0, k=0, l=0;
// the output file examined
TString InFile="psi4160_fast.root";
TString OutFile="psi4160_out.root";
// initialization
FairLogger::GetLogger()->SetLogToFile(kFALSE);
FairRunAna* fRun = new FairRunAna();
fRun->SetWriteRunInfoFile(kFALSE);
fRun->SetInputFile(InFile);
fRun->SetOutputFile(OutFile);
fRun->Init();
// create an output file for all histograms
TFile *out = TFile::Open("psi4160.root","RECREATE");
// create ntuples for psi(4160), D0 and anti-D0
RhoTuple *npsi4160 = new RhoTuple("npsi4160","npsi4160 Analysis");
RhoTuple *nd0 = new RhoTuple("nd0","nD0 Analysis");
RhoTuple *nantid0 = new RhoTuple("nantid0","nanti-D0 Analysis");
// *** Now the analysis stuff *** //
// the data reader object
PndAnalysis* theAnalysis = new PndAnalysis();
if(nevts==0) nevts= theAnalysis->GetEntries();
and then the real analysis part comes...
But now I am taking this as an error:
FairRootManager::OpenOutFile("psi4160_out.root")
Warning in <TFile::Init>: file psi4160_fast.root probably not closed, trying to recover
Info in <TFile::Recover>: psi4160_fast.root, recovered key TFolder:cbmroot at address 230
Info in <TFile::Recover>: psi4160_fast.root, recovered key TList:BranchList at address 698
Info in <TFile::Recover>: psi4160_fast.root, recovered key FairFileHeader:FileHeader at address 946
Info in <TFile::Recover>: psi4160_fast.root, recovered key TTree:cbmsim at address 5176972
Warning in <TFile::Init>: successfully recovered 4 keys
Fatal in <ApplySequence>: The sequence of actions to read PndMCTrack:1 member-wise was not initialized.
aborting
and then a stack of errors which lead to exit root...
I really have no idea (as you will have probably understood by now) of what is wrong!!!
|
|
|
|
Re: first try with fast simulation problem [message #16280 is a reply to message #16278] |
Wed, 09 April 2014 17:26 |
Alexandros
Messages: 51 Registered: January 2014 Location: KVI
|
continuous participant |
From: *kvi-cart.rug.nl
|
|
Ok the simulation works now..
The file I get from my analysis("psi4160.root") with the ntuples is empty...
I checked with the TBrowser and the tuples are there but empty..
This is what I do:
// some variables
int i=0,j=0, k=0, l=0;
// the output file examined
TString InFile="psi4160_fast.root";
TString OutFile="psi4160_out.root";
// initialization
FairLogger::GetLogger()->SetLogToFile(kFALSE);
FairRunAna* fRun = new FairRunAna();
fRun->SetWriteRunInfoFile(kFALSE);
fRun->SetInputFile(InFile);
fRun->SetOutputFile(OutFile);
fRun->Init();
RhoCalculationTools::ForceConstantBz(20.0);
// create an output file for all histograms
TFile *out = TFile::Open("psi4160.root","RECREATE");
// create ntuples for psi(4160), D0 and anti-D0
RhoTuple *npsi4160 = new RhoTuple("npsi4160","npsi4160 Analysis");
RhoTuple *nd0 = new RhoTuple("nd0","nD0 Analysis");
RhoTuple *nantid0 = new RhoTuple("nantid0","nanti-D0 Analysis");
// *** Now the analysis stuff *** //
// the data reader object
PndAnalysis* theAnalysis = new PndAnalysis();
if(nevts==0) nevts= theAnalysis->GetEntries();
// RhoCandLists for the analysis
RhoCandList psi4160, d0, antid0, kplus, kminus, piplus, piminus, all;
// Mass selector for the psi4160, do/anti-d0, K+/K-, pi+/pi- cands
double m0_d0 = TDatabasePDG::Instance()->GetParticle("D0")->Mass(); // Get nominal PDG mass of the D0/anti-D0
RhoMassParticleSelector *d0MassSel=new RhoMassParticleSelector("d0",m0_d0,1.0);
// Pid Selection Algorithms
TString pidSelection = "PidChargedProbability";
// the lorentz vector of the initial psi(4160)
TLorentzVector ini(0, 0, 6.833, 8.000);
// *** the event loop *** //
while (theAnalysis->GetEvent() && i++<nevts)
{
cout<< " evt " << i << endl;
// Select with no Loose PID info; type and mass are set
theAnalysis->FillList(all, "All", pidSelection);
PndEventShape evsh(all, ini, 0.05, 0.1);
theAnalysis->FillList(kplus, "KaonLoosePlus", pidSelection);
theAnalysis->FillList(kminus, "KaonLooseMinus", pidSelection);
theAnalysis->FillList(piplus, "PionLoosePlus", pidSelection);
theAnalysis->FillList(piminus, "PionLooseMinus", pidSelection);
/// first I have the same stuff as following for D0 and antiD0 and then comes the next part
// *** combinatorics for psi4160 -> d0 anti-d0 *** //
psi4160.Combine(d0, antid0);
psi4160.SetType(60443);
for (j=0;j<psi4160.GetLength();++j)
{
// get daughters
RhoCandidate *dd0 = psi4160[j]->Daughter(0);
RhoCandidate *dantid0 = psi4160[j]->Daughter(1);
PndPidCandidate *dd0_rec = (PndPidCandidate*)dd0->GetRecoCandidate();
PndPidCandidate *dantid0_rec = (PndPidCandidate*)dantid0->GetRecoCandidate();
// get truth information
bool mct = theAnalysis->McTruthMatch(psi4160[j]);
RhoCandidate *true_psi4160 = psi4160[j]->GetMcTruth();
// do 4C fit
PndKinFitter fitter(psi4160[j]); // instantiate the kin fitter in psi(2S)
fitter.Add4MomConstraint(ini); // set 4 constraint
fitter.Fit(); // do fit
RhoCandidate *fit4c_psi4160 = psi4160[j]->GetFit(); // get fitted psi4160
double chi2_4c = fitter.GetChi2(); // get chi2 of fit
double prob_4c = fitter.GetProb(); // access probability of fit
// general event info
npsi4160->Column("ev", (Float_t) i, -999.9f);
npsi4160->Column("cand", (Float_t) j, -999.9f);
// basic psi4160 info
npsi4160->Column("psi4160m", (Float_t) psi4160[j]->M(), -999.9f);
npsi4160->Column("psi4160p", (Float_t) psi4160[j]->P(), -999.9f);
npsi4160->Column("psi4160pt", (Float_t) psi4160[j]->P3().Pt(), -999.9f);
npsi4160->Column("psi4160tht", (Float_t) psi4160[j]->P3().Theta()*57.30, -999.9f);
npsi4160->Column("psi41604c", (Float_t) fit4c_psi4160->M(), -999.9f);
So if I try to draw psi4160m for example it gives nothing..
There is a problem with the tuple filling and writing I guess...
When you have time again I would appreciate your help...
|
|
|
|
|
Re: first try with fast simulation problem [message #16393 is a reply to message #16282] |
Tue, 22 April 2014 10:58 |
Alexandros
Messages: 51 Registered: January 2014 Location: KVI
|
continuous participant |
From: *kvi-cart.rug.nl
|
|
I changed my code in the new form:
// *** some variables
int i=0,j=0, k=0, l=0;
//gStyle->SetOptFit(1011);
// *** the output file for FairRunAna
TString OutFile="psi4160_out.root";
// *** initialization
FairLogger::GetLogger()->SetLogToFile(kFALSE);
FairRunAna* fRun = new FairRunAna();
fRun->SetWriteRunInfoFile(kFALSE);
fRun->SetInputFile(InFile);
fRun->SetOutputFile(OutFile); // only dummy; the real output is psi4160.root
fRun->Init();
// *** take constant field; needed for PocaVtx
RhoCalculationTools::ForceConstantBz(20.0);
// *** create an output file for all histograms
TFile *out = TFile::Open("psi4160.root","RECREATE");
// *** create some ntuples
RhoTuple *npsi4160 = new RhoTuple("npsi4160", "psi4160 analysis");
RhoTuple *nd0 = new RhoTuple("nd0", "d0 analysis");
RhoTuple *nantid0 = new RhoTuple("nantid0", "antid0 analysis");
RhoTuple *nmc = new RhoTuple("nmc", "mctruth info");
//
// Now the analysis stuff comes...
//
// *** the data reader object
PndAnalysis* theAnalysis = new PndAnalysis();
if (nevts==0) nevts= theAnalysis->GetEntries();
// *** name of the only PidAlgo TClonesArray in fsim
TString pidalg = "PidChargedProbability";
// *** QA tool for simple dumping of analysis results in RhoRuple
PndRhoTupleQA qa(theAnalysis, pbarmom);
// *** RhoCandLists for the analysis
RhoCandList psi4160, d0, antid0, kplus, kminus, piplus, piminus, all, mclist;
// *** Mass selector for the d0 cands
double m0_d0 = TDatabasePDG::Instance()->GetParticle("D0")->Mass(); // Get nominal PDG mass of the D0/anti-D0
RhoMassParticleSelector *d0MassSel=new RhoMassParticleSelector("d0",m0_d0,1.0);
// *** the lorentz vector of the initial psi(4160)
TLorentzVector ini(0, 0, 8.000, 9.016);
// ***
// the event loop
// ***
while (theAnalysis->GetEvent() && i++<nevts)
and so on, but now it gives me an error saying:
-I- FairRunTimeDB::InitContainer() FairBaseParSet
[ERROR ] init() FairBaseParSet not initialized
-I- FairRunTimeDB::InitContainer() ANAPidSelections
[ERROR ] init() ANAPidSelections not initialized
Error in <FairRuntimeDb::initContainers()>: Error occured during initialization
[INFO ] The number of entries in chain is 10000
*** Break *** segmentation violation
Do you have any idea of what is wrong???
|
|
|
|
Re: first try with fast simulation problem [message #16395 is a reply to message #16394] |
Tue, 22 April 2014 11:15 |
Alexandros
Messages: 51 Registered: January 2014 Location: KVI
|
continuous participant |
From: *kvi-cart.rug.nl
|
|
-I- FairRunTimeDB::InitContainer() FairBaseParSet
[ERROR ] init() FairBaseParSet not initialized
-I- FairRunTimeDB::InitContainer() ANAPidSelections
[ERROR ] init() ANAPidSelections not initialized
Error in <FairRuntimeDb::initContainers()>: Error occured during initialization
[INFO ] The number of entries in chain is 10000
*** Break *** segmentation violation
===========================================================
There was a crash (#6 0xb71a724b in SigHandler(ESignals) () from /home/alexandros/external_apr13/install/lib/root/libCore.so.5.34).
This is the entire stack trace of all threads:
===========================================================
#0 0xb7737424 in __kernel_vsyscall ()
#1 0xb6d6f253 in __waitpid_nocancel () at ../sysdeps/unix/syscall-template.S:81
#2 0xb6cf5e60 in do_system (line=0x95fc930 "/home/alexandros/external_apr13/install/etc/gdb-backtrace.sh 11870 1>&2") at ../sysdeps/posix/system.c:148
#3 0xb71a14db in TUnixSystem::Exec(char const*) () from /home/alexandros/external_apr13/install/lib/root/libCore.so.5.34
#4 0xb71a508a in TUnixSystem::StackTrace() () from /home/alexandros/external_apr13/install/lib/root/libCore.so.5.34
#5 0xb71a7117 in TUnixSystem::DispatchSignals(ESignals) () from /home/alexandros/external_apr13/install/lib/root/libCore.so.5.34
#6 0xb71a724b in SigHandler(ESignals) () from /home/alexandros/external_apr13/install/lib/root/libCore.so.5.34
#7 0xb71a0952 in sighandler(int) () from /home/alexandros/external_apr13/install/lib/root/libCore.so.5.34
#8 0xb71d54b5 in textinput::TerminalConfigUnix::HandleSignal(int) () from /home/alexandros/external_apr13/install/lib/root/libCore.so.5.34
#9 0xb71d5504 in (anonymous namespace)::TerminalConfigUnix__handleSignal(int) () from /home/alexandros/external_apr13/install/lib/root/libCore.so.5.34
#10 <signal handler called>
#11 0xb33b78fd in PndAnalysis::GetMcCandList (this=0x9579450, l=...) at /home/alexandros/pandaroot/PndTools/AnalysisTools/PndAnalysis.cxx:310
#12 0xb33b7502 in PndAnalysis::FillList (this=0x9579450, l=..., listkey=<incomplete type>, pidTcaNames=<incomplete type>) at /home/alexandros/pandaroot/PndTools/AnalysisTools/PndAnalysis.cxx:241
#13 0xb34441d2 in G__G__AnalysisToolsDict_890_0_7 (result7=0xbff8ceb4, funcname=0x95771e0 "", libp=0xbff8cedc, hash=0) at /home/alexandros/buildPanda/PndTools/AnalysisTools/G__AnalysisToolsDict. cxx:5328
#14 0xb66b7593 in Cint::G__ExceptionWrapper(int (*)(G__value*, char const*, G__param*, int), G__value*, char*, G__param*, int) () from /home/alexandros/external_apr13/install/lib/root/libCint.so.5.34
#15 0xb6766cc7 in G__execute_call () from /home/alexandros/external_apr13/install/lib/root/libCint.so.5.34
#16 0xb67670a2 in G__call_cppfunc () from /home/alexandros/external_apr13/install/lib/root/libCint.so.5.34
#17 0xb674253b in G__interpret_func () from /home/alexandros/external_apr13/install/lib/root/libCint.so.5.34
#18 0xb67314ba in G__getfunction () from /home/alexandros/external_apr13/install/lib/root/libCint.so.5.34
#19 0xb6828517 in G__getstructmem(int, G__FastAllocString&, char*, int, char*, int*, G__var_array*, int) () from /home/alexandros/external_apr13/install/lib/root/libCint.so.5.34
#20 0xb681ed17 in G__getvariable () from /home/alexandros/external_apr13/install/lib/root/libCint.so.5.34
#21 0xb6707e1c in G__getitem () from /home/alexandros/external_apr13/install/lib/root/libCint.so.5.34
#22 0xb670d9fc in G__getexpr () from /home/alexandros/external_apr13/install/lib/root/libCint.so.5.34
#23 0xb679acf1 in G__exec_statement () from /home/alexandros/external_apr13/install/lib/root/libCint.so.5.34
#24 0xb67a3cd1 in G__exec_loop(char const*, char*, std::list<G__FastAllocString, std::allocator<G__FastAllocString> > const&) [clone .constprop.42] () from /home/alexandros/external_apr13/install/lib/root/libCint.so.5.34
#25 0xb679b8df in G__exec_statement () from /home/alexandros/external_apr13/install/lib/root/libCint.so.5.34
#26 0xb67437e1 in G__interpret_func () from /home/alexandros/external_apr13/install/lib/root/libCint.so.5.34
#27 0xb673152c in G__getfunction () from /home/alexandros/external_apr13/install/lib/root/libCint.so.5.34
#28 0xb670832e in G__getitem () from /home/alexandros/external_apr13/install/lib/root/libCint.so.5.34
#29 0xb670d9fc in G__getexpr () from /home/alexandros/external_apr13/install/lib/root/libCint.so.5.34
#30 0xb679acf1 in G__exec_statement () from /home/alexandros/external_apr13/install/lib/root/libCint.so.5.34
#31 0xb66f299f in G__exec_tempfile_core () from /home/alexandros/external_apr13/install/lib/root/libCint.so.5.34
#32 0xb66f4098 in G__exec_tempfile_fp () from /home/alexandros/external_apr13/install/lib/root/libCint.so.5.34
#33 0xb67a8bc4 in G__process_cmd () from /home/alexandros/external_apr13/install/lib/root/libCint.so.5.34
#34 0xb716c815 in TCint::ProcessLine(char const*, TInterpreter::EErrorCode*) () from /home/alexandros/external_apr13/install/lib/root/libCore.so.5.34
#35 0xb70c4571 in TApplication::ProcessLine(char const*, bool, int*) () from /home/alexandros/external_apr13/install/lib/root/libCore.so.5.34
#36 0xb6f94bae in TRint::HandleTermInput() () from /home/alexandros/external_apr13/install/lib/root/libRint.so.5.34
#37 0xb6f94292 in TTermInputHandler::Notify() () from /home/alexandros/external_apr13/install/lib/root/libRint.so.5.34
#38 0xb6f96722 in TTermInputHandler::ReadNotify() () from /home/alexandros/external_apr13/install/lib/root/libRint.so.5.34
#39 0xb71a679b in TUnixSystem::CheckDescriptors() () from /home/alexandros/external_apr13/install/lib/root/libCore.so.5.34
#40 0xb71a7421 in TUnixSystem::DispatchOneEvent(bool) () from /home/alexandros/external_apr13/install/lib/root/libCore.so.5.34
#41 0xb71232d2 in TSystem::InnerLoop() () from /home/alexandros/external_apr13/install/lib/root/libCore.so.5.34
#42 0xb7124170 in TSystem::Run() () from /home/alexandros/external_apr13/install/lib/root/libCore.so.5.34
#43 0xb70c2d52 in TApplication::Run(bool) () from /home/alexandros/external_apr13/install/lib/root/libCore.so.5.34
#44 0xb6f960c1 in TRint::Run(bool) () from /home/alexandros/external_apr13/install/lib/root/libRint.so.5.34
#45 0x08048cd0 in main ()
===========================================================
The lines below might hint at the cause of the crash.
If they do not help you then please submit a bug report at
http://root.cern.ch/bugs. Please post the ENTIRE stack trace
from above as an attachment in addition to anything else
that might help us fixing this issue.
===========================================================
#11 0xb33b78fd in PndAnalysis::GetMcCandList (this=0x9579450, l=...) at /home/alexandros/pandaroot/PndTools/AnalysisTools/PndAnalysis.cxx:310
#12 0xb33b7502 in PndAnalysis::FillList (this=0x9579450, l=..., listkey=<incomplete type>, pidTcaNames=<incomplete type>) at /home/alexandros/pandaroot/PndTools/AnalysisTools/PndAnalysis.cxx:241
===========================================================
Root > Function psi4160at8GeV10000eventsAnalysis() busy flag cleared
*** Break *** keyboard interrupt psi4160at8GeV10000eventsAnalysis.C:25:
|
|
|
|
|
|
|
|
|
Goto Forum:
Current Time: Sun Nov 24 06:36:41 CET 2024
Total time taken to generate the page: 0.00886 seconds
|