TEventList::Enter(), 2 issues

From: LEE, KERRY T. (JSC-SF) (UHCL) <kerry.t.lee1_at_jsc.nasa.gov>
Date: Thu, 2 Feb 2006 10:38:22 -0600

Dear ROOT team,

I am using ROOT v5.08 on linux CentOS 4 compiled with gcc 3.4.4.

First issue:

I would like to create a very large TEventList with about 200 million entries. When it reaches just under 105 millon entries I get an error. I have plenty of physical memory (2GB + 2GB swap) to perform this task. A session below shows the problem. On the other hand, I have no problem creating an array of type Long64_t with 200 million entries.

FreeType Engine v2.1.9 used to render TrueType fonts. Compiled on 20 December 2005 for linux with thread support.

CINT/ROOT C/C++ Interpreter version 5.16.5, November 30 2005 Type ? for help. Commands must be C++ statements. Enclose multiple statements between { }. root [0] TEventList *E = new TEventList(); root [1] {

end with '}', '@':abort > for(int i=0;i<105000000;i++){
end with '}', '@':abort > E->Enter(i);
end with '}', '@':abort > if(i>104500000)cout<<"\r"<<i<<flush;
end with '}', '@':abort > }
end with '}', '@':abort > }

104857599Syntax Error: * (tmpfile):3:
Error: Illegal pointer operation (tovalue) (tmpfile):3: *** Interpreter error recovered ***

Second issue:

I would like to add random integers to a TEventList, but it seems that only higher values than the previous one entered into the TEventList is allowed.

root [11] TEventList *lll = new TEventList()
root [12] lll->Enter(1)
root [13] lll->GetEntry(0)

(const Long64_t)1
root [14] lll->Enter(5)
root [16] lll->GetEntry(1)
(const Long64_t)5
root [17] lll->Enter(3)
root [18] lll->GetEntry(2)
(const Long64_t)5

As you can see adding the number 3 to the list after adding 5 produces an entry of 5. Is this expected, or is this a bug? If for some reason this is not allowed an error message would be very useful. I can only assume, since there exists a TEventList::Sort() function this is not the desired behavior.

The purpose for doing this is to randomly sample a ROOT tree without having to know anything about it except the total number of entries. I would like to save this TEventList to a file, then read it and the TTree back into an interacive ROOT session.

Kerry Received on Thu Feb 02 2006 - 17:42:21 MET

This archive was generated by hypermail 2.2.0 : Mon Jan 01 2007 - 16:31:57 MET