Print

Print


We have noticed that some of the events being generated by Gismo these days
have a lot of mc particles, which is possibly why you are running out of
memory reading the event. There seems to be some anomaly where particles get
"stuck", I dont think anyone has understood it yet. The way java works is
that it is only allowed to allocate up to some maximum amount of system
memory, then it gives the OutOfMemory error. You can increase the amount of
memory available to Java by inserting the flag

   -mx64m

on the command line that starts java (right after the word java). In this
example it would allow java to use up to 64MBytes of memory. If you are
using the jas exec to start java and jas you will need to make a copy and
edit it to insert the aboive option.

Tony
----- Original Message -----
From: "Jeff B. Gronberg" <[log in to unmask]>
To: <[log in to unmask]>
Sent: Wednesday, February 16, 2000 5:54 PM
Subject: java.lang.OutOfMemoryError


> Hello,
>
> I've been getting a java.lang.OutOfMemoryError when I
> run on a file I generated.  It seems to occur when an event
> is read in to memory.  The traceback is:
>
> java.lang.OutOfMemoryError
> at java.util.Vector.ensureCapacityHelper(Vector.java)
> at java.util.Vector.addElement(Vector.java)
> at java.io.ObjectInputStream.assignWireOffset(ObjectInputStream.java)
> .
> .
> .
> at
hep.lcd.io.smart.EventInputStream.readObjectSmart(EventInputStream.java)
> .
> .
> .
> at hep.lcd.io.ascii.handler.LCDEventHeader.get(LCDEventHeader.java)
> at
hep.lcd.util.event.AbstractLCDEvent.getMCParticles(AbstractLCDEvent.java)
> at testin.processEvent(testin.java:33)
>
> the code I used for test is:
>
> // This file has been automatically generated by
> // the Java Analysis Studio program page wizard
> // for the event source named
> // higgstest.gismo
> // Thu Jan 20 01:19:17 GMT+00:00 2000
> import java.lang.Math;
> import java.lang.Thread;
> import hep.analysis.*;
> import hep.physics.*;
> import hep.lcd.event.*;
> import hep.lcd.physics.*;
> import java.util.*;
> final public class testin extends EventAnalyzer
> {
> int i=0;
>     public testin()
>     {
> // Enter constructor code here.
>     }
>     public void beforeFirstEvent()
>     {
> // Enter code here or delete method definition.
>     }
>     public void afterLastEvent()
>     {
> // Enter code here or delete method definition.
>     }
>     public void processEvent(EventData d)
>     {
> i++;
> System.out.println("Event number = " + i);
> LCDEvent header = (LCDEvent) d;
> ParticleEnumeration pe = header.getMCParticles().particles();
> // process
>     }
> }
>
> which as you can see doesn't do much.  The file I am looking at is
> /nfs/nfs01/work/gronberg/higgstest.lcd and I am running on a flora
> machine.
>
> Can anyone shed any light?
>
> Thanks, Jeff Gronberg
>