GSI Forum
GSI Helmholtzzentrum für Schwerionenforschung

Home » PANDA » PandaRoot » Analysis » Tutorial feb2012
Tutorial feb2012 [message #13464] Thu, 10 May 2012 11:01 Go to next message
Dmitry Khaneft is currently offline  Dmitry Khaneft
Messages: 75
Registered: January 2009
continuous participant
From: *kph.uni-mainz.de
Dear all,

I try to follow tutorial available at feb12.

I slightly modified it for my needsand try to plot some simple distributions but I can't see an effect of applying different PID criteria.

For example: All, VeryLoose, Loose, Tight, VeryTight give same results.

Here is a part of my code.

// *** TCandLists for the analysis
TCandList eplus, eminus;

...

while (theAnalysis->GetEvent() && i++<nevts){
    if ((i%1000)==0) cout << "Number of events analysed: " << i << endl;

    // *** Select with no PID info ('All'); type and mass are set
    theAnalysis->FillList(eplus, "ElectronTightPlus");
    //theAnalysis->FillList(eplus, "ElectronTightPlus","PidAlgoEmcBayes");
    theAnalysis->FillList(eminus, "ElectronTightPlus");
    //theAnalysis->FillList(eminus, "ElectronTightMinus","PidAlgoEmcBayes");

    // ELECTRONS ***
    for (Int_t j=0;j<eminus.GetLength();++j){
      // Fill momentum of reconstructed particles
      hP->Fill(eminus[j].GetMomentum().Mag());
      // Fill energy of reconstructed particles
      hE->Fill(eminus[j].Energy());
      // Fill momentum vs E/p
      hEP->Fill(eminus[j].GetMomentum().Mag(), eminus[j].Energy()/eminus[j].GetMomentum().Mag());
      // *** CM frame *** //
      // boost from LAB to CM
      lv_charged_cm.SetVect(eminus[j].GetMomentum());
      lv_charged_cm.SetE(TMath::Sqrt(cElectronMass*cElectronMass + eminus[j].GetMomentum().Mag()*eminus[j].GetMomentum().Mag()));
      lv_charged_cm.Boost(-(lv_bar_beam + lv_p_target).BoostVector()); 

      hCosTheta_N_CM->Fill(lv_charged_cm.CosTheta());
    }
    for (Int_t j=0;j<eplus.GetLength();++j){
      // Fill momentum of reconstructed particles
      hP->Fill(eplus[j].GetMomentum().Mag());
      // Fill energy of reconstructed particles
      hE->Fill(eplus[j].Energy());
      // Fill momentum vs E/p
      hEP->Fill(eplus[j].GetMomentum().Mag(), eplus[j].Energy()/eplus[j].GetMomentum().Mag());
      // *** CM frame *** //
      // boost from LAB to CM
      lv_charged_cm.SetVect(eplus[j].GetMomentum());
      lv_charged_cm.SetE(TMath::Sqrt(cElectronMass*cElectronMass + eplus[j].GetMomentum().Mag()*eplus[j].GetMomentum().Mag()));
      lv_charged_cm.Boost(-(lv_bar_beam + lv_p_target).BoostVector()); 

      hCosTheta_P_CM->Fill(lv_charged_cm.CosTheta());
    }
  }


In addition histograms filled with energy and momentum are the same. Using "PidAlgoEmcBayes" also gives no effect.

Is it suppose to be like this or I do something wrong?

P.S. I used trunk 15407 instead of 14709 because later couldn't be compiled.

Cheers,
Dmitry
Re: Tutorial feb2012 [message #13465 is a reply to message #13464] Thu, 10 May 2012 11:42 Go to previous messageGo to next message
StefanoSpataro is currently offline  StefanoSpataro
Messages: 2736
Registered: June 2005
Location: Torino
first-grade participant

From: *to.infn.it
Can you check if the TCA PidAlgoEmcBayes is filled?
Re: Tutorial feb2012 [message #13466 is a reply to message #13465] Thu, 10 May 2012 12:08 Go to previous messageGo to next message
Dmitry Khaneft is currently offline  Dmitry Khaneft
Messages: 75
Registered: January 2009
continuous participant
From: *kph.uni-mainz.de
Stefano Spataro wrote on Thu, 10 May 2012 11:42

Can you check if the TCA PidAlgoEmcBayes is filled?

What is TCA? Sad

pid file has PidAlgoEmcBayes branch filled if that is what you meant.
Re: Tutorial feb2012 [message #13467 is a reply to message #13466] Thu, 10 May 2012 12:14 Go to previous messageGo to next message
StefanoSpataro is currently offline  StefanoSpataro
Messages: 2736
Registered: June 2005
Location: Torino
first-grade participant

From: *to.infn.it
TCA = TClonesArray.
My question is if PidAlgoEmcBayes is filled with zero or if it has "reasonable" values.
Re: Tutorial feb2012 [message #13468 is a reply to message #13467] Thu, 10 May 2012 12:19 Go to previous messageGo to next message
Dmitry Khaneft is currently offline  Dmitry Khaneft
Messages: 75
Registered: January 2009
continuous participant
From: *kph.uni-mainz.de
I would expect more "high" probability entries for electrons because I simulate electrons as initial particles but it is definitely not filled with 0.

I attach an example histogram, I think it looks ok.
Re: Tutorial feb2012 [message #13469 is a reply to message #13468] Thu, 10 May 2012 12:29 Go to previous messageGo to next message
StefanoSpataro is currently offline  StefanoSpataro
Messages: 2736
Registered: June 2005
Location: Torino
first-grade participant

From: *to.infn.it
Mmm,
maybe Ralf or Klaus should take a look.
Re: Tutorial feb2012 [message #13470 is a reply to message #13464] Thu, 10 May 2012 12:53 Go to previous messageGo to next message
Ralf Kliemt is currently offline  Ralf Kliemt
Messages: 507
Registered: May 2007
Location: GSI, Darmstadt
first-grade participant

From: *pool.mediaWays.net
Hi,

From you macro I see:
    theAnalysis->FillList(eplus, "ElectronTightPlus");
    //theAnalysis->FillList(eplus, "ElectronTightPlus","PidAlgoEmcBayes");
    theAnalysis->FillList(eminus, "ElectronTightPlus");
    //theAnalysis->FillList(eminus, "ElectronTightMinus","PidAlgoEmcBayes");

This means you disabled your choice of Algorithm and take the default "PidAlgoIdealCharged". By switching back you should get reasonable results.

Be reminded that you can manually reset to any other PID combination "by hand". Ref. the turorial.


Cheers.
Ralf
Re: Tutorial feb2012 [message #13471 is a reply to message #13470] Thu, 10 May 2012 13:35 Go to previous messageGo to next message
StefanoSpataro is currently offline  StefanoSpataro
Messages: 2736
Registered: June 2005
Location: Torino
first-grade participant

From: *to.infn.it
Hi Ralf,
in the text of the message it is written that uncommenting those lines the results are the same:

Quote:

In addition histograms filled with energy and momentum are the same. Using "PidAlgoEmcBayes" also gives no effect.

Re: Tutorial feb2012 [message #13472 is a reply to message #13470] Thu, 10 May 2012 15:39 Go to previous message
Klaus Götzen is currently offline  Klaus Götzen
Messages: 293
Registered: June 2006
Location: GSI
first-grade participant
From: *adsl.alicedsl.de
Hi,


last time I tried to validate I also had problems with applying PID algos different then default. It seems that the TCAs are filled with reasonable values, but that the PidCombiner (which is supposed to multiply the values of different algos) somehow doesn't work correctly.

Ralf, do you remember, that we were taking a look to that, but without really solving the problem?

This actually means, that we/I need to take another look to the code. Unfortunately I'm sick at home at the moment, so not today...


Best,
Klaus
Previous Topic: negative chi2 in PndKinVtxFitter !
Next Topic: editing pidana.par
Goto Forum:
  


Current Time: Sat Nov 09 10:50:42 CET 2024

Total time taken to generate the page: 0.00924 seconds