What is the number after the tree name?

From: Genie Jhang <geniejhang_at_majimak.com>
Date: Sat, 30 Jul 2011 21:15:31 +0900


Hello.

I think I have some problems.
I'm currently getting simulation data with input data using geant4.9.4.p02 and root 5.30. If the entries are not so many, this problem doesn't appear. Here's the problem.



root [0]
Attaching file rawData.root as _file0... root [1] _file0 -> ls()
TFile**		rawData.root	
 TFile*		rawData.root	
  KEY: TTree	SimulationData;108	Simulation Data is stored
  KEY: TTree	SimulationData;107	Simulation Data is stored
  KEY: TTree	IQMDData;3	Primary Vertices are stored
  KEY: TTree	IQMDData;2	Primary Vertices are stored
root [2]

There're two keys for the same tree!!
What is "the number" after the treename with "l"? And I'm pretty sure that I let the simulation make only two trees; IQMDData, SimulationData, but why two?

Is that my problem? or ROOT? or GEANT4? or code?

Thanks for your guide and help, in advance.

Here's the code for making ROOT file. Simplified to some extent but including all the essential parts.



AnaRoot::AnaRoot()
{

  rootFile = new TFile("rawData.root", "RECREATE");   rootDir = gDirectory;

  // IQMD Data Tree Making
  rootDir -> cd();

  iqmdDataTree = new TTree("IQMDData", "Primary Vertices are stored");     iqmdDataTree -> Branch("eventID", &eventID, "eventID/I");

  // Simulation Data Tree Making
  rootDir -> cd();

  simulationDataTree = new TTree("SimulationData", "Simulation Data is stored");     simulationDataTree -> Branch("eventID", &eventID, "eventID/I"); }

AnaRoot::~AnaRoot()
{

  std::cout << "ROOT file is created!" << std::endl;

  rootFile -> Write();
}

void AnaRoot::BeginOfEvent(Int_t eventNum)
{

  eventID = eventNum;
}

void AnaRoot::FillPrimaryVertex()
{

  iqmdDataTree -> Fill();
}

void AnaRoot::FillTPC()
{

  simulationDataTree -> Fill();
}


Received on Sat Jul 30 2011 - 14:15:45 CEST

This archive was generated by hypermail 2.2.0 : Mon Aug 01 2011 - 23:50:01 CEST